| |||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public static class Path2D.Float extends Path2D implements Serializable
The {@code Float} class defines a geometric path with coordinates stored in single precision floating point.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.awt.geom.Path2D |
---|
Path2D.Double, Path2D.Float |
Field Summary |
---|
Fields inherited from class java.awt.geom.Path2D |
---|
WIND_EVEN_ODD, WIND_NON_ZERO |
Constructor Summary | |
---|---|
Constructs a new empty single precision object with a default winding rule of java.awt.geom.Path2D.WIND_NON_ZERO. |
|
Path2D.Float(int rule) Constructs a new empty single precision object with the specified winding rule to control operations that require the interior of the path to be defined. |
|
Path2D.Float(int rule, int initialCapacity) Constructs a new empty single precision object with the specified winding rule and the specified initial capacity to store path segments. |
|
Constructs a new single precision object from an arbitrary java.awt.Shape object. |
|
Path2D.Float(Shape s, AffineTransform at) Constructs a new single precision object from an arbitrary java.awt.Shape object, transformed by an java.awt.geom.AffineTransform object. |
Method Summary | |
---|---|
void |
append(PathIterator pi, boolean connect) Appends the geometry of the specified object to the path, possibly connecting the new geometry to the existing path segments with a line segment. |
Object |
clone() Creates a new object of the same class as this object. |
void |
curveTo(double x1, double y1, double x2, double y2, double x3, double y3) Adds a curved segment, defined by three new points, to the path by drawing a Bézier curve that intersects both the current coordinates and the specified coordinates , using the specified points and as Bézier control points. |
void |
curveTo(float x1, float y1, float x2, float y2, float x3, float y3) Adds a curved segment, defined by three new points, to the path by drawing a Bézier curve that intersects both the current coordinates and the specified coordinates , using the specified points and as Bézier control points. |
Rectangle2D |
|
PathIterator |
|
void |
lineTo(double x, double y) Adds a point to the path by drawing a straight line from the current coordinates to the new specified coordinates specified in double precision. |
void |
lineTo(float x, float y) Adds a point to the path by drawing a straight line from the current coordinates to the new specified coordinates specified in float precision. |
void |
moveTo(double x, double y) Adds a point to the path by moving to the specified coordinates specified in double precision. |
void |
moveTo(float x, float y) Adds a point to the path by moving to the specified coordinates specified in float precision. |
void |
quadTo(double x1, double y1, double x2, double y2) Adds a curved segment, defined by two new points, to the path by drawing a Quadratic curve that intersects both the current coordinates and the specified coordinates , using the specified point as a quadratic parametric control point. |
void |
quadTo(float x1, float y1, float x2, float y2) Adds a curved segment, defined by two new points, to the path by drawing a Quadratic curve that intersects both the current coordinates and the specified coordinates , using the specified point as a quadratic parametric control point. |
void |
Transforms the geometry of this path using the specified java.awt.geom.AffineTransform. |
Methods inherited from class java.awt.geom.Path2D |
---|
append, append, clone, closePath, contains, contains, contains, contains, contains, contains, contains, contains, createTransformedShape, curveTo, getBounds, getCurrentPoint, getPathIterator, getWindingRule, intersects, intersects, intersects, intersects, lineTo, moveTo, quadTo, reset, setWindingRule, transform |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Path2D.Float()
public Path2D.Float(int rule)
rule
- the winding rulepublic Path2D.Float(int rule, int initialCapacity)
rule
- the winding ruleinitialCapacity
- the estimate for the number of path segments
in the pathpublic Path2D.Float(Shape s)
s
- the specified {@code Shape} objectpublic Path2D.Float(Shape s, AffineTransform at)
s
- the specified {@code Shape} objectat
- the specified {@code AffineTransform} objectMethod Detail |
---|
public final void append(PathIterator pi, boolean connect)
append
in class Path2D
pi
connect
public final Object clone()
clone
in class Path2D
public final synchronized void curveTo(double x1, double y1, double x2, double y2, double x3, double y3)
curveTo
in class Path2D
x1
y1
x2
y2
x3
y3
public final synchronized void curveTo(float x1, float y1, float x2, float y2, float x3, float y3)
This method provides a single precision variant of the double precision {@code curveTo()} method on the base {@code Path2D} class.
x1
- the X coordinate of the first Bézier control pointy1
- the Y coordinate of the first Bézier control pointx2
- the X coordinate of the second Bézier control pointy2
- the Y coordinate of the second Bézier control pointx3
- the X coordinate of the final end pointy3
- the Y coordinate of the final end pointpublic final synchronized Rectangle2D getBounds2D()
public PathIterator getPathIterator(AffineTransform at)
The iterator for this class is not multi-threaded safe, which means that the {@code Path2D} class does not guarantee that modifications to the geometry of this {@code Path2D} object do not affect any iterations of that geometry that are already in process.
at
public final synchronized void lineTo(double x, double y)
lineTo
in class Path2D
x
y
public final synchronized void lineTo(float x, float y)
This method provides a single precision variant of the double precision {@code lineTo()} method on the base {@code Path2D} class.
x
- the specified X coordinatey
- the specified Y coordinatepublic final synchronized void moveTo(double x, double y)
moveTo
in class Path2D
x
y
public final synchronized void moveTo(float x, float y)
This method provides a single precision variant of the double precision {@code moveTo()} method on the base {@code Path2D} class.
x
- the specified X coordinatey
- the specified Y coordinatepublic final synchronized void quadTo(double x1, double y1, double x2, double y2)
quadTo
in class Path2D
x1
y1
x2
y2
public final synchronized void quadTo(float x1, float y1, float x2, float y2)
This method provides a single precision variant of the double precision {@code quadTo()} method on the base {@code Path2D} class.
x1
- the X coordinate of the quadratic control pointy1
- the Y coordinate of the quadratic control pointx2
- the X coordinate of the final end pointy2
- the Y coordinate of the final end pointpublic final void transform(AffineTransform at)
transform
in class Path2D
at
| |||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |