All Packages Class Hierarchy This Package Previous Next Index
Class quicktime.qd.Polygon
java.lang.Object
|
+----quicktime.QTObject
|
+----quicktime.util.QTHandleRef
|
+----quicktime.qd.Polygon
- public final class Polygon
- extends QTHandleRef
- implements QuickTimeLib, Cloneable
The Polygon represents an arbitary area or set of areas on the drawing coordinate plane.
Methods are implemented for a corresponding QuickDraw structure used by QuickTime.
refer to Polygon in QuickDraw
-
Polygon(QDGraphics)
- Allocates a new empty Polygon.
-
clone()
- Copies the mathematical structure of the implicit Polygon into a newly created Polygon.
-
close()
- Completes the collection of lines that define the polygon.
-
copy()
- Copies the mathematical structure of the implicit Polygon into a newly created Polygon.
-
getBounds()
- Returns a copy of the bounding rectangle of the Polygon.
-
getPolyBBox()
- Returns a copy of the bounding rectangle of the Polygon.
-
getSize()
- Returns size of the Polygon.
-
offset(int, int)
- offset moves the Polygon by adding
the value you specify in the dh parameter to the horizontal coordinates of its points,
and by adding the value you specify in the dv parameter to the vertical coordinates of
all points of its boundary.
-
toString()
- Print information about this object.
Polygon
public Polygon(QDGraphics g) throws QTException
- Allocates a new empty Polygon.
QuickDraw::OpenPoly
- Parameters:
- port - the port which the open polygon will record operations from
close
public void close() throws QDException
- Completes the collection of lines that define the polygon.
QuickDraw::ClosePoly
getSize
public int getSize()
- Returns size of the Polygon.
- Overrides:
- getSize in class QTHandleRef
getPolyBBox
public QDRect getPolyBBox()
- Returns a copy of the bounding rectangle of the Polygon.
- Returns:
- a rect
getBounds
public QDRect getBounds()
- Returns a copy of the bounding rectangle of the Polygon.
- Returns:
- a rect
copy
public Polygon copy() throws QTException
- Copies the mathematical structure of the implicit Polygon into a newly created Polygon.
- Returns:
- A new Polygon copy.
clone
public Object clone()
- Copies the mathematical structure of the implicit Polygon into a newly created Polygon.
- Returns:
- A new Polygon copy.
- Overrides:
- clone in class Object
toString
public String toString()
- Print information about this object.
- Returns:
- a string representing this Polygon object
- Overrides:
- toString in class QTHandleRef
offset
public void offset(int dh,
int dv) throws QDException
- offset moves the Polygon by adding
the value you specify in the dh parameter to the horizontal coordinates of its points,
and by adding the value you specify in the dv parameter to the vertical coordinates of
all points of its boundary. If the values of dh and dv are positive, the movement
is to the right and down; if either is negative, the corresponding movement is in the opposite
direction. The Polygon retains its size and shape. This doesn’t affect the screen unless
you subsequently redraw the polygon.
QuickDraw::OffsetPoly()
- Parameters:
- poly - Polygon to offset.
- dh - The horizontal distance to move the polygon.
- dv - The vertical distance to move the polygon.
All Packages Class Hierarchy This Package Previous Next Index