|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectchemaxon.struc.MObject
chemaxon.struc.graphics.MPolyline
chemaxon.struc.graphics.MRectangle
Rectangle object.
| Field Summary | |
static int |
P_CENTER
Central point ID. |
static int |
P_E
Middle point on right edge. |
static int |
P_N
Middle point on top edge. |
static int |
P_NE
Top-right corner index. |
static int |
P_NW
Top-left corner index. |
static int |
P_S
Middle point on bottom edge. |
static int |
P_SE
Botton-right corner index. |
static int |
P_SW
Bottom-left corner index. |
static int |
P_W
Middle point on left edge. |
static int |
T_NOROT
Disable rotation. |
| Fields inherited from class chemaxon.struc.graphics.MPolyline |
ARROW_BACK_FLAG, ARROW_HALF_LEFT, ARROW_HALF_MASK, ARROW_HALF_RIGHT, CLOSED_FLAG, DEFAULT_THICKNESS, HEAD, TAIL, THICKNESS_SET_FLAG |
| Fields inherited from class chemaxon.struc.MObject |
PAINT_ANTIALIAS, PAINT_FOCUSED, TRANSFORM_DISTORT |
| Constructor Summary | |
|
MRectangle()
Contructs a rectangle. |
|
MRectangle(MPoint p1,
MPoint p2)
Contructs a rectangle with the specified corner points. |
|
MRectangle(MPoint p1,
MPoint p2,
java.awt.Color c,
java.awt.Color bg)
Contructs a rectangle with the specified corner points. |
protected |
MRectangle(MRectangle r)
Copy constructor. |
| Method Summary | |
void |
addAttributeKeys(java.util.Vector v)
Adds the attribute names to the specified vector. |
void |
calcCenter(DPoint3 p,
CTransform3D t)
Calculates the geometrical center. |
java.lang.Object |
clone()
Creates a clone. |
protected CTransform3D |
convertTransform(CTransform3D t,
boolean paint)
|
double |
distanceFrom(double x,
double y,
CTransform3D t)
Gets the 2D distance from the specified point. |
static void |
fixRectanglePointClones(MObject[] objarr0,
MObject[] objarr)
Fixes the parents of the cloned MRectanglePoints. |
java.lang.String |
getAttribute(java.lang.String s)
Gets the value of an attribute. |
protected java.lang.Object |
getClipObject(CTransform3D t)
Gets the clipping rectangle. |
MPoint |
getPointRef(int i,
CTransform3D trot)
Gets an internal selectable point of the rectangle. |
int |
getPointRefCount()
Gets the number of internal selectable point references. |
int |
getTCenter()
Gets the transformed point. |
int |
getTOption()
Gets the transformation options. |
void |
paint(java.awt.Graphics g,
CTransform3D t,
int f,
java.awt.Color c,
java.awt.Color selc,
java.awt.Color focusc)
Paints the object. |
void |
removeChild(MObject o)
Removes a child object. |
void |
setAttribute(java.lang.String s,
java.lang.String v)
Sets the value of an attribute. |
void |
setCorners(MPoint p1,
MPoint p2)
Sets the corners. |
void |
setTCenter(int t)
Sets the transformed point. |
void |
setTOption(int opts)
Sets the transformation options. |
void |
transform(CTransform3D t,
int opts,
CTransform3D trot)
Transforms the rectangle. |
void |
transformTo2D()
Rotate to the XY plane. |
| Methods inherited from class chemaxon.struc.graphics.MPolyline |
checkValidity, containsAtom, copyProperties, finishCloning, fixMidPointClones, getArcAngle, getArcCenter, getArcRadius, getArrowFlags, getArrowLength, getArrowWidth, getFlags, getMidPointLocation, getPoint, getPointCount, getPoints, getSkip, getThickness, hasBackground, hasColor, hasFace, hasLineColor, hasOutline, isArrow, isEmpty, isThicknessSet, replaceAtom, setArcAngle, setArrow, setArrowFlags, setArrowLength, setArrowWidth, setFlags, setPoints, setSkip, setThickness, unselectContents |
| Methods inherited from class chemaxon.struc.MObject |
addCdataAttributeKeys, addNotify, distanceFrom, getBackground, getColor, getLineColor, isChildOf, isInternalSelectable, isSelectableNow, isSelected, isTransformable, makeColor, removeNotify, setBackground, setColor, setLineColor, setSelected, toString |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final int T_NOROT
public static final int P_NW
public static final int P_NE
public static final int P_SE
public static final int P_SW
public static final int P_CENTER
public static final int P_N
public static final int P_E
public static final int P_S
public static final int P_W
| Constructor Detail |
public MRectangle()
public MRectangle(MPoint p1,
MPoint p2)
p1 - the top left cornerp2 - the bottom right corner
public MRectangle(MPoint p1,
MPoint p2,
java.awt.Color c,
java.awt.Color bg)
p1 - the top left cornerp2 - the bottom right cornerc - the colorbg - the background colorprotected MRectangle(MRectangle r)
r - the original rectangle| Method Detail |
public void calcCenter(DPoint3 p,
CTransform3D t)
calcCenter in class MPolylinep - store the coordinates heret - the transformation matrix or null
public void transform(CTransform3D t,
int opts,
CTransform3D trot)
transform in class MPolylinet - the transformation matrixopts - transform options or 0trot - the viewing transformation or nullpublic void transformTo2D()
protected CTransform3D convertTransform(CTransform3D t,
boolean paint)
public void paint(java.awt.Graphics g,
CTransform3D t,
int f,
java.awt.Color c,
java.awt.Color selc,
java.awt.Color focusc)
paint in class MPolylineg - the graphics contextt - the transformation matrixf - flagsc - the color to use or nullselc - the selection colorfocusc - the focus colorpublic void addAttributeKeys(java.util.Vector v)
addAttributeKeys in class MPolylinev - the vectorpublic java.lang.String getAttribute(java.lang.String s)
getAttribute in class MPolylines - the attribute name
public void setAttribute(java.lang.String s,
java.lang.String v)
setAttribute in class MPolylines - the attribute namev - the attribute value
public double distanceFrom(double x,
double y,
CTransform3D t)
distanceFrom in class MPolylinex - the x coordinatey - the y coordinatet - transformation or null
public void setCorners(MPoint p1,
MPoint p2)
p1 - the top left cornerp2 - the bottom right cornerpublic int getTOption()
public void setTOption(int opts)
opts - the optionsT_NOROTpublic int getTCenter()
public void setTCenter(int t)
t - the transformed point (if it is a corner point) or IDP_NW,
P_NE,
P_SE,
P_SW,
P_CENTER,
P_N,
P_E,
P_S,
P_W,
transform(CTransform3D, int, CTransform3D),
calcCenter(DPoint3, CTransform3D)public java.lang.Object clone()
MObject
clone in class MPolylinepublic void removeChild(MObject o)
MObject
removeChild in class MPolylinepublic int getPointRefCount()
getPointRefCount in class MPolyline
public MPoint getPointRef(int i,
CTransform3D trot)
getPointRef in class MPolylinei - the point indextrot - the viewing transformation or null
public static void fixRectanglePointClones(MObject[] objarr0,
MObject[] objarr)
objarr0 - the original object arrayobjarr - the cloned object arrayprotected final java.lang.Object getClipObject(CTransform3D t)
t - the transformation matrix
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||