|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectchemaxon.marvin.space.GraphicComponent
chemaxon.marvin.space.MoleculeComponent
public class MoleculeComponent
MoleculeComponent is the basic visualizer of simple molecules in MarvinSpace.
Displays atoms and bonds in classic drawing modes: wire, ball, stick, ball&stick,
ball&wire, spacefill.
Atoms of the molecule can be individually selected.
Ligands of a complex structure can be visualized by MoleculeComponent,
but in this case the MoleculeComponent is not directly added to
the GraphicScene but is handled by the MacroMoleculeComponent
as a MoleculeVisualizer.
Example of typical usage:
ArrayList moleculeList = graphicScene.getEventHandler().readMolecule("molecule1.mol");
MoleculeComponent mc = moleculeList.get(0);
| Field Summary | |
|---|---|
protected int |
ballPrecision
|
protected double |
ballRadius
|
protected static int |
BOND_DRAW_TYPE_BOND
|
protected static int |
BOND_DRAW_TYPE_STICK
|
protected static int |
BOND_DRAW_TYPE_WIRE
|
protected static boolean |
BOND_FACING
|
protected int |
bondDistance
|
protected boolean |
bondFacing
|
protected double |
bondRadius
|
protected int |
bondSlicePrecision
|
protected int |
bondWidth
|
protected java.awt.Color |
color
|
protected int |
colorType
|
protected static int |
COMPONENT_TYPE_ATOM
|
protected static int |
COMPONENT_TYPE_BOND
|
protected static int |
COMPONENT_TYPE_MOLECULE
|
protected static double |
DEFAULT_BALL_RADIUS
|
protected static int |
DEFAULT_BOND_DISTANCE
|
protected static double |
DEFAULT_BOND_RADIUS
|
protected static int |
DEFAULT_BOND_WIDTH
|
protected static java.awt.Color |
DEFAULT_COLOR
|
protected static int |
DEFAULT_H_BALL_PRECISION
|
protected static int |
DEFAULT_H_BOND_SLICE_PRECISION
|
protected static int |
DEFAULT_H_JOINT_PRECISION
|
protected static int |
DEFAULT_H_SPACEFILL_PRECISION
|
protected static int |
DEFAULT_H_STICK_SLICE_PRECISION
|
protected static int |
DEFAULT_L_BALL_PRECISION
|
protected static int |
DEFAULT_L_BOND_SLICE_PRECISION
|
protected static int |
DEFAULT_L_JOINT_PRECISION
|
protected static int |
DEFAULT_L_SPACEFILL_PRECISION
|
protected static int |
DEFAULT_L_STICK_SLICE_PRECISION
|
protected static double |
DEFAULT_LINE_WIDTH
|
protected static int |
DEFAULT_M_BALL_PRECISION
|
protected static int |
DEFAULT_M_BOND_SLICE_PRECISION
|
protected static int |
DEFAULT_M_JOINT_PRECISION
|
protected static int |
DEFAULT_M_SPACEFILL_PRECISION
|
protected static int |
DEFAULT_M_STICK_SLICE_PRECISION
|
protected static double |
DEFAULT_STICK_RADIUS
|
protected static boolean |
DISPLAY_BOND_ORDER
|
protected boolean |
displayBondOrder
|
protected static int |
DRAW_TYPE_BALL
|
protected static int |
DRAW_TYPE_BALL_AND_STICK
|
protected static int |
DRAW_TYPE_BALL_AND_WIRE
|
protected static int |
DRAW_TYPE_SPACEFILL
|
protected static int |
DRAW_TYPE_STICK
|
protected static int |
DRAW_TYPE_WIRE
|
protected boolean |
drawHydrogens
|
protected int |
drawType
|
protected static java.util.HashMap |
drawTypes
|
static int[] |
elementList
|
protected chemaxon.struc.MacroMolecule.HeteroComponent |
hc
|
protected int |
jointPrecision
|
protected double |
lineWidth
|
static int |
LONE_PAIR_TYPE
|
protected MacroMoleculeComponent |
mmc
|
protected Molecule |
mol
|
protected static boolean |
SCALED_BALLS
|
protected boolean |
scaledBalls
|
protected boolean[] |
selectedAtoms
|
protected boolean |
selectionBeforeInit
|
protected static boolean |
SMOOTH_STICKS
|
protected boolean |
smoothStickColoring
|
protected int |
spacefillPrecision
|
protected double |
stickRadius
|
protected int |
stickSlicePrecision
|
| Fields inherited from class chemaxon.marvin.space.GraphicComponent |
|---|
active, associatedComponents, boundingBox, COMPONENT_TYPE_ENTIRE, drawProperties, gl, glu, graphicCell, irm, modifiesOrigin, motionMode, mousex, mousey, name, pickedItem, RENDERING_QUALITY_HIGH, RENDERING_QUALITY_LOW, RENDERING_QUALITY_MEDIUM, renderingQuality, rm, uoid, visible |
| Constructor Summary | |
|---|---|
protected |
MoleculeComponent()
Creates a new instance of MoleculeComponent. |
|
MoleculeComponent(chemaxon.struc.MacroMolecule.HeteroComponent hc,
MacroMoleculeComponent mmc)
Creates a new instance of MoleculeComponent from the given
HeteroComponent and MacroMoleculeComponent;
this class can be used as a visualizer of a ligand. |
|
MoleculeComponent(Molecule mol)
Creates a new instance of MoleculeComponent from the given molecule. |
| Method Summary | |
|---|---|
void |
draw()
Called by GraphicCell from the Jogl rendering thread and draws the molecule. |
void |
drawAtomSelection(int mode)
To make selection faster we don't draw the atoms themself into the selection buffer, but we draw simple polygons instead. |
protected void |
drawSelection(int mode)
Draws the component in the given mode (usually in selection mode), the rendering mode is for checking. |
void |
drawTransparentPart()
Draws the molecule if the drawing type was wire. |
void |
exclusiveSelection()
Sets the previously picked but unprocessed element to be selected, and sets every other parts not to be selected. |
void |
extendSelection()
Sets the previously picked but unprocessed element to be selected, and leaves other parts as they are. |
void |
fadeSelected()
The selected atoms will be faded. |
void |
fadeUnselected()
The unselected atoms will be faded. |
int |
getAtomCount(boolean enumerateHydrogens)
Returns the number of atoms in the molecule with arbitrarily enumerating hydrogens. |
chemaxon.struc.MoleculeIterators.AtomIteratorInterface |
getAtomIterator(boolean enumerateHydrogens)
Returns the iterator of the atoms of the molecule. |
chemaxon.struc.MoleculeIterators.AtomPropertyInterface |
getAtomProperty()
See MoleculeIterators.AtomPropertyInterface for details. |
boolean[] |
getAtomSelections()
|
int |
getBondCount(boolean enumerateHydrogens)
Returns the number of bonds in the molecule with arbitrarily enumerating hydrogens. |
chemaxon.struc.MoleculeIterators.BondIteratorInterface |
getBondIterator(boolean enumerateHydrogens)
Returns the iterator of the atoms of the molecule. |
BoundingBox |
getBoundingBox()
Returns the BoundingBox that is the smallest container box of the component. |
java.awt.Color |
getColor()
Returns the constant color of the component. |
int |
getColorType()
Returns the color type of the visualizer. |
ComponentElement |
getComponentElement()
Returns the previously picked but unprocessed ComponentElement or the whole
component as a ComponentElement, if no picking happened. |
void |
getCoordinates(ComponentElement element,
float[] c)
Sets the coordinates of the given element in the given preallocated array. |
java.lang.String |
getDescription(ComponentElement element)
Returs the short description of the given part of the component. |
GraphicComponent |
getGraphicComponent()
|
chemaxon.marvin.space.UOID |
getId()
Returns the id of the component. |
ComponentElement[] |
getLabelInformation(java.lang.String labeltype)
|
ComponentElement[] |
getLabelInformation(java.lang.String labeltype,
boolean onlyOnHeavyAtoms)
Labels will be created associated to this MoleculeComponent if the labeltype is "atom", "extraatomlabel" or "molecule". |
MacroMoleculeComponent |
getMacroMoleculeComponent()
Returns the macromolecule visualizer if this MoleculeComponent visualizes
a ligand in a complex. |
Molecule |
getMolecule()
Returns the Molecule of the MoleculeComponent. |
MolAtom |
getSelectedAtom(int i)
|
int |
getVisibleAtomCount()
Returns the number of atoms currently visible. |
boolean |
hasSelectedElements()
Returns true if the component has any selected part. |
boolean |
hasTransparentPart()
Returns true if antialiased lines are drawn, that is in DRAW_TYPE_WIRE or
DRAW_TYPE_BALL_AND_WIRE mode. |
void |
hideSelected()
The selected atoms will be hidden. |
void |
hideUnselected()
The unselected atoms will be hidden. |
void |
initDraw()
Initializes gl related drawing variables, for example display lists. |
void |
invertSelection()
Sets the the given part of the component to be selected if it was not set and vice versa. |
boolean |
isAtomFaded(int i)
Tells whether the atom is faded or not. |
boolean |
isAtomVisible(int i)
Returns if the atom is visible or hidden. |
boolean |
isControllable(java.lang.String type)
Returns whether controling by the given type of controller is allowed to the component. |
boolean |
isGraphicComponent()
|
boolean |
isHighlighted()
This functionality is currently unavailable. |
boolean |
isLigand()
|
boolean |
isMacromoleculePart()
Tells whether this MoleculeComponent is a visualizer of a ligand in a complex
or an independent small molecule. |
boolean |
isSelected()
Returns true if the whole component is selected. |
boolean |
isSelected(ComponentElement item)
Returns true if the given item is selected. |
boolean |
isSelectedAtom(int atomIndex)
Returns true if the atom with the given index is selected. |
boolean |
isVisible()
Returns true if this component is allowed to be drawn. |
boolean |
isVisible(ComponentElement item)
Returns true if the given item is visible. |
void |
onRemove()
|
void |
onRemoveGraphicComponent()
|
protected void |
pickObject(int offset,
double[] maxZ,
float[] modelview)
Sets GraphicComponent.pickedItem to be the picked part of the component. |
void |
rotate(float[] v,
float[] center)
Rotates the molecule with parameter center as an origin. |
void |
select()
Sets the whole component to be selected. |
void |
selectAllAtoms()
Sets all atoms to be selected. |
void |
selectAtom(int i)
Sets the atom with the given index to be selected. |
void |
selectComponentElementsInside(BoundingBox bb)
Atoms lying in the given box will be selected. |
int |
selectedAtomCount()
Returns the number of atoms being selected. |
protected void |
setBoundingBox()
Computes the bounding box of the visible atoms of the molecule, and adds 2 angstroms to each side. |
void |
setColor(java.awt.Color color)
Sets the constant color of the component. |
void |
setColor(float r,
float g,
float b)
Sets the constant color of the component. |
void |
setDrawProperty(java.lang.String propertyName,
java.lang.String propertyValue)
Sets a draw property. |
void |
setGL(javax.media.opengl.GL gl,
javax.media.opengl.glu.GLU glu)
Sets drawing related variable. |
void |
setHighlighted(boolean v)
This functionality is currently unavailable. |
void |
setMacroMoleculeComponent(MacroMoleculeComponent mmc)
A MacroMoleculeComponent can be set and in this case this will be a
visualizer of a ligand in the macromolecule. |
void |
setMolecule(Molecule mol)
Sets the Molecule of the MoleculeComponent to mol,
sets proper atomIterators, and computes the bounding box. |
void |
setVisible(boolean v)
Sets the component to be visible/invisible. |
void |
showFaded()
Faded atoms will be fully visible again. |
void |
torsion(double angle,
float[] axis,
float[] center,
int[] atomArray)
Changes torsion angle. |
void |
translate(float[] v)
Translates the molecule with the parameter as a vector. |
void |
unSelect()
Unselects the component, say sets all parts to be unselected. |
void |
unSelectAllAtoms()
Sets all atoms to be unselected. |
void |
unSelectAtom(int i)
Sets the atom with the given index to be unselected. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface chemaxon.marvin.space.MacroMoleculeComponent.MoleculeVisualizer |
|---|
getDrawProperty, getName |
| Methods inherited from interface chemaxon.marvin.space.UsableObject |
|---|
getName, setName, toString |
| Field Detail |
|---|
protected static final int DRAW_TYPE_WIRE
protected static final int DRAW_TYPE_BALL
protected static final int DRAW_TYPE_STICK
protected static final int DRAW_TYPE_BALL_AND_WIRE
protected static final int DRAW_TYPE_BALL_AND_STICK
protected static final int DRAW_TYPE_SPACEFILL
protected static final int BOND_DRAW_TYPE_BOND
protected static final int BOND_DRAW_TYPE_STICK
protected static final int BOND_DRAW_TYPE_WIRE
protected static final double DEFAULT_BALL_RADIUS
protected static final double DEFAULT_BOND_RADIUS
protected static final double DEFAULT_STICK_RADIUS
protected static final double DEFAULT_LINE_WIDTH
protected static final int DEFAULT_BOND_DISTANCE
protected static final int DEFAULT_BOND_WIDTH
protected static final boolean SMOOTH_STICKS
protected static final boolean BOND_FACING
protected static final boolean SCALED_BALLS
protected static final boolean DISPLAY_BOND_ORDER
protected static final int DEFAULT_H_BALL_PRECISION
protected static final int DEFAULT_H_SPACEFILL_PRECISION
protected static final int DEFAULT_H_JOINT_PRECISION
protected static final int DEFAULT_H_BOND_SLICE_PRECISION
protected static final int DEFAULT_H_STICK_SLICE_PRECISION
protected static final int DEFAULT_M_BALL_PRECISION
protected static final int DEFAULT_M_SPACEFILL_PRECISION
protected static final int DEFAULT_M_JOINT_PRECISION
protected static final int DEFAULT_M_BOND_SLICE_PRECISION
protected static final int DEFAULT_M_STICK_SLICE_PRECISION
protected static final int DEFAULT_L_BALL_PRECISION
protected static final int DEFAULT_L_SPACEFILL_PRECISION
protected static final int DEFAULT_L_JOINT_PRECISION
protected static final int DEFAULT_L_BOND_SLICE_PRECISION
protected static final int DEFAULT_L_STICK_SLICE_PRECISION
protected static final int COMPONENT_TYPE_ATOM
protected static final int COMPONENT_TYPE_BOND
protected static final int COMPONENT_TYPE_MOLECULE
protected static final java.awt.Color DEFAULT_COLOR
public static final int[] elementList
public static final int LONE_PAIR_TYPE
protected static java.util.HashMap drawTypes
protected Molecule mol
protected MacroMoleculeComponent mmc
protected chemaxon.struc.MacroMolecule.HeteroComponent hc
protected int drawType
protected boolean drawHydrogens
protected double ballRadius
protected double bondRadius
protected double stickRadius
protected double lineWidth
protected int bondDistance
protected int bondWidth
protected boolean smoothStickColoring
protected boolean bondFacing
protected boolean scaledBalls
protected boolean displayBondOrder
protected int ballPrecision
protected int spacefillPrecision
protected int bondSlicePrecision
protected int stickSlicePrecision
protected int jointPrecision
protected int colorType
protected boolean[] selectedAtoms
protected boolean selectionBeforeInit
protected java.awt.Color color
| Constructor Detail |
|---|
protected MoleculeComponent()
public MoleculeComponent(Molecule mol)
MoleculeComponent from the given molecule.
public MoleculeComponent(chemaxon.struc.MacroMolecule.HeteroComponent hc,
MacroMoleculeComponent mmc)
MoleculeComponent from the given
HeteroComponent and MacroMoleculeComponent;
this class can be used as a visualizer of a ligand.
| Method Detail |
|---|
public void onRemoveGraphicComponent()
onRemoveGraphicComponent in class GraphicComponentpublic void onRemove()
onRemove in interface MacroMoleculeComponent.MoleculeVisualizerpublic boolean isGraphicComponent()
isGraphicComponent in interface chemaxon.marvin.space.UsableObjectisGraphicComponent in class GraphicComponentpublic GraphicComponent getGraphicComponent()
getGraphicComponent in interface chemaxon.marvin.space.UsableObjectgetGraphicComponent in class GraphicComponentpublic chemaxon.marvin.space.UOID getId()
GraphicComponentGraphicCell
may also alter its value. Thus to preserve a component for later use,
store the component itself rather than its Id.
getId in interface chemaxon.marvin.space.UsableObjectgetId in class GraphicComponentpublic void setMacroMoleculeComponent(MacroMoleculeComponent mmc)
MacroMoleculeComponent can be set and in this case this will be a
visualizer of a ligand in the macromolecule.
public boolean isMacromoleculePart()
MoleculeComponent is a visualizer of a ligand in a complex
or an independent small molecule.
public MacroMoleculeComponent getMacroMoleculeComponent()
MoleculeComponent visualizes
a ligand in a complex.
getMacroMoleculeComponent in interface MacroMoleculeComponent.MoleculeVisualizer
public void setGL(javax.media.opengl.GL gl,
javax.media.opengl.glu.GLU glu)
setGL in interface MacroMoleculeComponent.MoleculeVisualizersetGL in class GraphicComponentgl - Interface to OpenGLglu - Interface to OpenGLpublic java.awt.Color getColor()
GraphicComponent
getColor in interface MacroMoleculeComponent.MoleculeVisualizergetColor in interface chemaxon.marvin.space.UsableObjectgetColor in class GraphicComponentpublic void setColor(java.awt.Color color)
setColor in interface chemaxon.marvin.space.UsableObjectsetColor in class GraphicComponent
public void setColor(float r,
float g,
float b)
setColor in class GraphicComponentpublic BoundingBox getBoundingBox()
BoundingBox that is the smallest container box of the component.
Either hydrogens are displayed or not they are always considered.
getBoundingBox in interface MacroMoleculeComponent.MoleculeVisualizergetBoundingBox in class GraphicComponentpublic Molecule getMolecule()
Molecule of the MoleculeComponent.
public void setMolecule(Molecule mol)
Molecule of the MoleculeComponent to mol,
sets proper atomIterators, and computes the bounding box.
public chemaxon.struc.MoleculeIterators.AtomIteratorInterface getAtomIterator(boolean enumerateHydrogens)
MoleculeIterators.AtomIteratorInterface for details.
getAtomIterator in interface chemaxon.struc.MoleculeIterators.MoleculeInterfaceenumerateHydrogens - enable/disable enumeration of hydrogenspublic chemaxon.struc.MoleculeIterators.AtomPropertyInterface getAtomProperty()
MoleculeIterators.AtomPropertyInterface for details.
getAtomProperty in interface chemaxon.struc.MoleculeIterators.MoleculeInterfacepublic chemaxon.struc.MoleculeIterators.BondIteratorInterface getBondIterator(boolean enumerateHydrogens)
MoleculeIterators.BondIteratorInterface for details.
getBondIterator in interface chemaxon.struc.MoleculeIterators.MoleculeInterfaceenumerateHydrogens - enable/disable enumeration of hydrogenspublic int getAtomCount(boolean enumerateHydrogens)
getAtomCount in interface chemaxon.struc.MoleculeIterators.MoleculeInterfacepublic int getBondCount(boolean enumerateHydrogens)
getBondCount in interface chemaxon.struc.MoleculeIterators.MoleculeInterfacepublic void translate(float[] v)
translate in class GraphicComponentv - translation vector
public void rotate(float[] v,
float[] center)
rotate in class GraphicComponentv - measure of rotation around the 3 axescenter - Center of the rotation.
public void torsion(double angle,
float[] axis,
float[] center,
int[] atomArray)
public boolean isControllable(java.lang.String type)
isControllable in class GraphicComponenttype - "Shift", "Rotate", "Resize"
protected void setBoundingBox()
public void initDraw()
MacroMoleculeComponent, because GraphicComponents
would get GL from the GraphicCell during initialization,
but MacroMoleculeComponent has to pass it to its visualizers.
initDraw in interface MacroMoleculeComponent.MoleculeVisualizerpublic void draw()
GraphicCell from the Jogl rendering thread and draws the molecule.
See GraphicComponent.draw().
draw in interface MacroMoleculeComponent.MoleculeVisualizerdraw in class GraphicComponentpublic void drawTransparentPart()
drawTransparentPart in interface MacroMoleculeComponent.MoleculeVisualizerdrawTransparentPart in class GraphicComponentpublic ComponentElement getComponentElement()
ComponentElement or the whole
component as a ComponentElement, if no picking happened.
getComponentElement in class GraphicComponent
public void getCoordinates(ComponentElement element,
float[] c)
getCoordinates in class GraphicComponentelement - specific part of the componentc - allocated array where coordinates will be putpublic java.lang.String getDescription(ComponentElement element)
getDescription in interface MacroMoleculeComponent.MoleculeVisualizergetDescription in class GraphicComponentelement - specific part of the component
public boolean isLigand()
public ComponentElement[] getLabelInformation(java.lang.String labeltype,
boolean onlyOnHeavyAtoms)
getLabelInformation in class GraphicComponentlabeltype - onlyOnHeavyAtoms - label info needed only for heavy atoms.
public ComponentElement[] getLabelInformation(java.lang.String labeltype)
getLabelInformation in interface MacroMoleculeComponent.MoleculeVisualizergetLabelInformation in class GraphicComponentpublic boolean isSelectedAtom(int atomIndex)
isSelectedAtom in interface MacroMoleculeComponent.MoleculeVisualizerpublic MolAtom getSelectedAtom(int i)
public boolean[] getAtomSelections()
public void selectAtom(int i)
selectAtom in interface MacroMoleculeComponent.MoleculeVisualizerpublic void unSelectAtom(int i)
unSelectAtom in interface MacroMoleculeComponent.MoleculeVisualizerpublic void selectAllAtoms()
public void unSelectAllAtoms()
public void setVisible(boolean v)
GraphicComponent, because in case of visualizing
a ligand of a macromolecule, the BoundingBox should be refreshed.
setVisible in interface MacroMoleculeComponent.MoleculeVisualizersetVisible in interface chemaxon.marvin.space.UsableObjectsetVisible in class GraphicComponentv - of visibilitypublic void showFaded()
showFaded in interface MacroMoleculeComponent.MoleculeVisualizershowFaded in class GraphicComponentpublic void hideSelected()
hideSelected in interface MacroMoleculeComponent.MoleculeVisualizerhideSelected in class GraphicComponentpublic void hideUnselected()
hideUnselected in interface MacroMoleculeComponent.MoleculeVisualizerhideUnselected in class GraphicComponentpublic void fadeSelected()
fadeSelected in interface MacroMoleculeComponent.MoleculeVisualizerfadeSelected in class GraphicComponentpublic void fadeUnselected()
fadeUnselected in interface MacroMoleculeComponent.MoleculeVisualizerfadeUnselected in class GraphicComponentpublic boolean isHighlighted()
isHighlighted in interface MacroMoleculeComponent.MoleculeVisualizerpublic void setHighlighted(boolean v)
setHighlighted in interface MacroMoleculeComponent.MoleculeVisualizerpublic boolean isVisible()
isVisible in interface MacroMoleculeComponent.MoleculeVisualizerisVisible in interface chemaxon.marvin.space.UsableObjectisVisible in class GraphicComponentpublic boolean isVisible(ComponentElement item)
isVisible in class GraphicComponentitem - part of the component
public boolean isAtomVisible(int i)
isAtomVisible in interface MacroMoleculeComponent.MoleculeVisualizeri - atom index given by MoleculeIterators.AtomIteratorInterface.current() }
public boolean isAtomFaded(int i)
isAtomFaded in interface MacroMoleculeComponent.MoleculeVisualizeri - atom index given by MoleculeIterators.AtomIteratorInterface.current() }
public int getVisibleAtomCount()
getVisibleAtomCount in interface MacroMoleculeComponent.MoleculeVisualizerpublic boolean hasTransparentPart()
DRAW_TYPE_WIRE or
DRAW_TYPE_BALL_AND_WIRE mode.
hasTransparentPart in interface MacroMoleculeComponent.MoleculeVisualizerhasTransparentPart in class GraphicComponentpublic void select()
select in interface MacroMoleculeComponent.MoleculeVisualizerselect in interface chemaxon.marvin.space.UsableObjectselect in class GraphicComponentpublic void unSelect()
unSelect in interface MacroMoleculeComponent.MoleculeVisualizerunSelect in interface chemaxon.marvin.space.UsableObjectunSelect in class GraphicComponentpublic void selectComponentElementsInside(BoundingBox bb)
selectComponentElementsInside in interface MacroMoleculeComponent.MoleculeVisualizerselectComponentElementsInside in class GraphicComponentbb - given box represented by a BoundingBoxpublic boolean isSelected(ComponentElement item)
isSelected in class GraphicComponentitem - specific part of the component
public boolean isSelected()
isSelected in interface MacroMoleculeComponent.MoleculeVisualizerisSelected in interface chemaxon.marvin.space.UsableObjectisSelected in class GraphicComponentpublic boolean hasSelectedElements()
hasSelectedElements in class GraphicComponentpublic int selectedAtomCount()
selectedAtomCount in interface MacroMoleculeComponent.MoleculeVisualizerpublic void exclusiveSelection()
exclusiveSelection in class GraphicComponentpublic void extendSelection()
extendSelection in class GraphicComponentpublic void invertSelection()
invertSelection in class GraphicComponentprotected void drawSelection(int mode)
GraphicComponent
drawSelection in class GraphicComponentmode - GL_RENDER or GL_SELECTpublic void drawAtomSelection(int mode)
drawAtomSelection in interface MacroMoleculeComponent.MoleculeVisualizer
protected void pickObject(int offset,
double[] maxZ,
float[] modelview)
GraphicComponentGraphicComponent.pickedItem to be the picked part of the component.
pickObject in class GraphicComponentoffset - Integer used in the name stack to identify the part of the component.maxZ - Stores the z coordinate of the part with maximum z coordinate in the actual picking.
It has to be set if the part with the current offset has greater z coordinate than the stored one.
Example to compute: int aIdx = GeomCalc.newVector( picked.x(), picked.y(), picked.z() );
GeomCalc.multVectorWithMatrix(aIdx, modelview);
z coordinate: maxZ[0] = GeomCalc.getZ(aIdx)modelview - Is to compute the proper z coordinate.public int getColorType()
getColorType in interface MacroMoleculeComponent.MoleculeVisualizer
public void setDrawProperty(java.lang.String propertyName,
java.lang.String propertyValue)
draw property.
StringString
String
String
String
String
String
String
String
String
StringString
setDrawProperty in interface MacroMoleculeComponent.MoleculeVisualizersetDrawProperty in interface chemaxon.marvin.space.UsableObjectsetDrawProperty in class GraphicComponentpropertyName - identifier of the draw propertypropertyValue - value of the draw property as a String
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||