|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectchemaxon.struc.MObject
chemaxon.struc.graphics.MChemicalStruct
public class MChemicalStruct
Molecule graph object.
| Field Summary |
|---|
| Fields inherited from class chemaxon.struc.MObject |
|---|
PAINT_ANTIALIAS, PAINT_FOCUSED, TRANSFORM_DISTORT |
| Constructor Summary | |
|---|---|
protected |
MChemicalStruct(MChemicalStruct mcs)
Copy constructor. |
|
MChemicalStruct(MoleculeGraph m)
Contructs a molecule graph object. |
| Method Summary | |
|---|---|
void |
calcCenter(DPoint3 p,
CTransform3D t)
Calculates the geometrical center. |
java.lang.Object |
clone()
Creates a clone. |
boolean |
containsAtom(MolAtom a)
Checks if the atom set contains the specified atom object. |
double |
distanceFrom(double x,
double y,
CTransform3D t)
Gets the 2D distance from the specified point. |
static double |
distanceFrom(MoleculeGraph molg,
double x,
double y,
CTransform3D t)
Gets the 2D distance from the specified point. |
MoleculeGraph |
getMoleculeGraph()
Gets the stored molecule graph. |
MPoint |
getPoint(int i)
Gets a point of the object. |
int |
getPointCount()
Gets the number of points (atoms). |
boolean |
hasSelection()
Checks the existence of the selection. |
static boolean |
hasSelection(MoleculeGraph molg)
Checks the existence of the selection. |
boolean |
isEmpty()
A chemical structure object is empty if the molecule graph is empty. |
void |
setSelected(boolean s)
Selects or unselects the object. |
static void |
setSelected(MoleculeGraph molg,
boolean s)
Selects or unselects atoms in a molecule graph. |
void |
transform(CTransform3D t,
int opts,
CTransform3D trot)
Transforms all points. |
void |
unselectContents()
Unselects atoms. |
| Methods inherited from class chemaxon.struc.MObject |
|---|
addAttributeKeys, addCdataAttributeKeys, addNotify, checkValidity, distanceFrom, finishCloning, getAttribute, getBackground, getColor, getLineColor, getPointRef, getPointRefCount, hasBackground, hasColor, hasLineColor, isChildOf, isInternalSelectable, isReactionArrow, isSelectableNow, isSelected, isTransformable, makeColor, paint, removeChild, removeNotify, replaceAtom, setAttribute, setBackground, setColor, setLineColor, toString, updateBoundingRect |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MChemicalStruct(MoleculeGraph m)
m - the molecule graphprotected MChemicalStruct(MChemicalStruct mcs)
mcs - the original object| Method Detail |
|---|
public MoleculeGraph getMoleculeGraph()
public java.lang.Object clone()
clone in class MObjectpublic boolean isEmpty()
isEmpty in class MObjectpublic int getPointCount()
getPointCount in class MObjectpublic MPoint getPoint(int i)
getPoint in class MObjecti - the point index
public boolean containsAtom(MolAtom a)
containsAtom in class MObject
public void transform(CTransform3D t,
int opts,
CTransform3D trot)
transform in class MObjectt - the transformation matrixopts - transform options or 0trot - the viewing transformation or nullMObject.TRANSFORM_DISTORT
public void calcCenter(DPoint3 p,
CTransform3D t)
calcCenter in class MObjectp - store the coordinates heret - the transformation matrix or null
public double distanceFrom(double x,
double y,
CTransform3D t)
distanceFrom in class MObjectx - the x coordinatey - the y coordinatet - transformation or null
public static double distanceFrom(MoleculeGraph molg,
double x,
double y,
CTransform3D t)
x - the x coordinatey - the y coordinatet - transformation or nullpublic void setSelected(boolean s)
setSelected in class MObjects - use true to select, false to unselect
public static void setSelected(MoleculeGraph molg,
boolean s)
s - use true to select, false to unselectpublic boolean hasSelection()
public static boolean hasSelection(MoleculeGraph molg)
public void unselectContents()
unselectContents in class MObject
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||