charite.christo.strap
Class V3dUtils
java.lang.Object
charite.christo.strap.V3dUtils
- All Implemented Interfaces:
- ChRunnable, PaintHook, ProcessEv, TooltipProvider
public class V3dUtils
- extends java.lang.Object
- implements ChRunnable, ProcessEv, TooltipProvider, PaintHook
HELP
Menu-bar:
If the user clicks inside the 3D-view, the
default Strap menu-bar disappears and the menu-bar of the 3D-view is shown
instead.
This menu-bar is independent of the type of 3D-view and will be referred to as the generic menu-bar.
Some 3D-programs have their own menu bar.
In this case, the user can swap between the native and the generic menu-bar.
By clicking the scroll-bar or the sequence of a protein that is not displayed three-dimensionally,
the default Strap menu-bar is shown again.
Undock menu items:
Menu items like "spheres on" or "sticks on" in the style menu might be frequently used.
For convenience, menu items can be dragged to the desktop with the mouse and are easier accessible.
Undock the viewer pane:
3D-viewers that are located inside the STRAP-application frame can be moved outside (undocking).
For this purpose the title header needs to be dragged.
Always floating on top of other windows
All Strap windows can be set "Always floating on top of all other windows". Type ctrl-T.
Picking Atoms in the 3D-View:
When atoms are clicked in the 3D-view, Strap will display a
toolbar with buttons that act upon the clicked amino acid.
These buttons allow to move the alignment cursor to the clicked residues and to add/remove the clicked
amino acid to a residue selection.
By picking an atom, one amino acid is selected.
By picking atoms with certain modifier keys, more than one amino acid can be selected.
This corresponds to selecting several files in a file browser by Ctrl-left-click or Shift-left-click.
The modifier keys depend on the 3D-viewer.
3D-Viewer | Continuous selection | Discontinuous selection |
OpenAstex | Ctrl+Shift-Click | Ctrl-Click |
JMol | Shift-Click | Ctrl-Click |
Selecting a protein.
Moving the alignment cursor selects the respective protein in the 3D view and also selects
the respective position. The previous atom selection is overridden.
There are two options for changing the protein without loosing the previous selection of that protein.
Either the protein list can be used which is opened with the menu item "Select protein" or
the alignment row header of the protein can be clicked.
The previous atom selection of this protein will be activated.
Selecting amino acids in the alignment panel:
Using the mouse or using arrow-left/ arrow-right keys together with shift, a number of amino acids can be selected
in STRAP. This selection is passed to the 3D viewer.
Alternatively, a residue selection can be dragged with the mouse into the 3D-view.
Adding proteins:
Proteins can be added by WIKI:Drag_and_drop.
See STRING:ChConstants#MOVIE_Drag_to_another_STRAP
Displaying Sequence Features:
Sequence Features can highlighted in the 3D-view using WIKI:Drag_and_drop.
See STRING:ChConstants#MOVIE_Sequence_Features_in_3D
3D-Superposition:
3D-Superposition allows to compare two or more protein backbones.
Two options are available:
- All peptide chains in the view: One medium structure will be used as a reference.
All other proteins are overlayed upon this reference peptide chain.
- All multiprotein complexes in the view:
Different chains of the same PDB entry form a complex and their relative position is sustained.
For superimposing two multiprotein complexes, the best structurally matching pair of chains is determined.
I.E. for superimposing two trimeric G-proteins, the beta propeller structures may be selected.
The superposition is computed for this pair of peptide chains and the transformation is applied to the entire
complexes.
Complexes might also be defined by the user or by a script - see context menu of proteins.
Fields inherited from interface charite.christo.ChRunnable |
APPEND, COLUMN_TITLE, DOWNLOAD_FINISHED, GET_PANEL, ICON, INTERPRET_LINE, IS_DRAG4XY, ITEM_TEXT, MODIFY_RENDERER_COMPONENT, PROGRESS, REPAINT_CURSOR, SAY_DOWNLOADING, SET_ICON_IMAGE, SET_TREE_VALUE, SHOW_IN_FRAME, TAB_TEXT, TIP_TEXT |
Method Summary |
static void |
colorAllAminos(java.awt.Color c,
ProteinViewer pv)
|
static void |
enableDisable()
|
static Selection3D[] |
getSelection3D(ProteinViewer pv)
|
static javax.swing.JComponent |
getToolpane()
|
static ProteinViewer |
open3dViewer(long options,
Protein[] pp,
java.lang.Object clazzOrViewer)
|
static void |
openColorDialog()
|
boolean |
paintHook(javax.swing.JComponent c,
java.awt.Graphics g,
boolean after)
|
static javax.swing.JComponent |
pnlSurfaceObjects()
|
void |
processEv(java.awt.AWTEvent ev)
|
java.lang.String |
provideTip(java.lang.Object objOrEv)
|
static void |
residueSelectionsTo3D_I(long option,
ResidueSelection[] ss,
ProteinViewer[] vv)
|
static boolean |
residueSelectionsTo3D(long options,
ResidueSelection[] ss,
ProteinViewer[] vv)
|
java.lang.Object |
run(java.lang.String id,
java.lang.Object arg)
|
static boolean |
sendCommand(long options,
java.lang.CharSequence command0,
ProteinViewer pv)
|
static boolean |
setFocusedP(boolean menuBar,
Protein p)
|
static java.lang.Thread |
thread_open3dViewer(long options,
Protein[] pp,
java.lang.Object clazzOrViewer,
ProteinViewer[] ret)
|
static void |
transform3D(Matrix3D m3d,
ProteinViewer pv)
|
static void |
viewerToFront(long options,
ProteinViewer pv)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OPEN_VERBOSE
public static final int OPEN_VERBOSE
- See Also:
- Constant Field Values
OPEN_ASK
public static final int OPEN_ASK
- See Also:
- Constant Field Values
OPEN_SEND_ALL_ANNOTATIONS
public static final int OPEN_SEND_ALL_ANNOTATIONS
- See Also:
- Constant Field Values
OPEN_NOT_ADD_PANEL
public static final int OPEN_NOT_ADD_PANEL
- See Also:
- Constant Field Values
OPEN_NARROW_OTHERS
public static final int OPEN_NARROW_OTHERS
- See Also:
- Constant Field Values
OPEN_ADD_TAB
public static final int OPEN_ADD_TAB
- See Also:
- Constant Field Values
OPEN_INIT_SCRIPT
public static final int OPEN_INIT_SCRIPT
- See Also:
- Constant Field Values
OPEN_EACH_PROTEIN_OWN_COLOR
public static final int OPEN_EACH_PROTEIN_OWN_COLOR
- See Also:
- Constant Field Values
PV_FOCUSED
public static final int PV_FOCUSED
- See Also:
- Constant Field Values
PV_MENUBAR
public static final int PV_MENUBAR
- See Also:
- Constant Field Values
PV_FOCUSED_NOT_MB
public static final int PV_FOCUSED_NOT_MB
- See Also:
- Constant Field Values
RSto3D_COMMANDS
public static final long RSto3D_COMMANDS
- See Also:
- Constant Field Values
RSto3D_COLOR
public static final long RSto3D_COLOR
- See Also:
- Constant Field Values
RSto3D_AS_ONE_SINGLE
public static final long RSto3D_AS_ONE_SINGLE
- See Also:
- Constant Field Values
RSto3D_SAME_PROTEIN
public static final long RSto3D_SAME_PROTEIN
- See Also:
- Constant Field Values
RSto3D_ASK_NAME
public static final long RSto3D_ASK_NAME
- See Also:
- Constant Field Values
RSto3D_REPORT_ERROR
public static final long RSto3D_REPORT_ERROR
- See Also:
- Constant Field Values
RSto3D_NOT_SAME_WIRE
public static final long RSto3D_NOT_SAME_WIRE
- See Also:
- Constant Field Values
RSto3D_NO_WIRE
public static final long RSto3D_NO_WIRE
- See Also:
- Constant Field Values
RSto3D_GENERIC_NAME
public static final long RSto3D_GENERIC_NAME
- See Also:
- Constant Field Values
RSto3D_SPECIFIC_ATOMS
public static final long RSto3D_SPECIFIC_ATOMS
- See Also:
- Constant Field Values
RSto3D_SET_FOCUSED_PV
public static final long RSto3D_SET_FOCUSED_PV
- See Also:
- Constant Field Values
V3dUtils
public V3dUtils()
thread_open3dViewer
public static java.lang.Thread thread_open3dViewer(long options,
Protein[] pp,
java.lang.Object clazzOrViewer,
ProteinViewer[] ret)
open3dViewer
public static ProteinViewer open3dViewer(long options,
Protein[] pp,
java.lang.Object clazzOrViewer)
run
public java.lang.Object run(java.lang.String id,
java.lang.Object arg)
- Specified by:
run
in interface ChRunnable
setFocusedP
public static boolean setFocusedP(boolean menuBar,
Protein p)
paintHook
public boolean paintHook(javax.swing.JComponent c,
java.awt.Graphics g,
boolean after)
- Specified by:
paintHook
in interface PaintHook
after
- This method is called once before and once after super.paintComponent.
- Returns:
- means do not call super.paintComponent
getToolpane
public static javax.swing.JComponent getToolpane()
enableDisable
public static void enableDisable()
processEv
public void processEv(java.awt.AWTEvent ev)
- Specified by:
processEv
in interface ProcessEv
- See Also:
EvAdapter
getSelection3D
public static Selection3D[] getSelection3D(ProteinViewer pv)
residueSelectionsTo3D
public static boolean residueSelectionsTo3D(long options,
ResidueSelection[] ss,
ProteinViewer[] vv)
residueSelectionsTo3D_I
public static void residueSelectionsTo3D_I(long option,
ResidueSelection[] ss,
ProteinViewer[] vv)
viewerToFront
public static void viewerToFront(long options,
ProteinViewer pv)
colorAllAminos
public static void colorAllAminos(java.awt.Color c,
ProteinViewer pv)
sendCommand
public static boolean sendCommand(long options,
java.lang.CharSequence command0,
ProteinViewer pv)
openColorDialog
public static void openColorDialog()
pnlSurfaceObjects
public static javax.swing.JComponent pnlSurfaceObjects()
transform3D
public static void transform3D(Matrix3D m3d,
ProteinViewer pv)
provideTip
public java.lang.String provideTip(java.lang.Object objOrEv)
- Specified by:
provideTip
in interface TooltipProvider
'The most important classes are StrapAlign, Protein and StrapEvent.'