public class BasicRectangle extends BasicFigure
| Constructor and Description |
|---|
BasicRectangle(double x,
double y,
double width,
double height)
Create a new rectangle with the given origin and size, a
unit-width continuous stroke and no paint pattern.
|
BasicRectangle(double x,
double y,
double width,
double height,
float lineWidth)
Create a new rectangle with the given origin, size, and
outline width.
|
BasicRectangle(double x,
double y,
double width,
double height,
Paint fill)
Create a new rectangle with the given origin, size, and
fill paint.
|
BasicRectangle(double x,
double y,
double width,
double height,
Paint fill,
float lineWidth)
Create a new rectangle with the given origin, size, fill, and
outline width.
|
BasicRectangle(Rectangle2D rect)
Create a new rectangle with the given rectangle shape, a
unit-width continuous stroke and no paint pattern.
|
BasicRectangle(Rectangle2D bounds,
Paint fill)
Create a new rectangle with the given bounds and
fill paint.
|
| Modifier and Type | Method and Description |
|---|---|
void |
translate(double x,
double y)
Translate the rectangle the given distance
|
getBounds, getComposite, getDashArray, getFillPaint, getLineWidth, getShape, getStrokePaint, hit, paint, setComposite, setDashArray, setFillPaint, setLineWidth, setShape, setStroke, setStrokePaint, transformcontains, getInteractor, getLayer, getOrigin, getParent, getToolTipText, getTransformContext, getUserObject, intersects, isVisible, paint, repaint, repaint, setInteractor, setParent, setToolTipText, setUserObject, setVisibleclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcontains, getInteractor, getLayer, getOrigin, getParent, getToolTipText, intersects, setInteractor, setParent, setToolTipTextisVisible, paint, setVisiblegetTransformContext, repaint, repaintgetUserObject, setUserObjectpublic BasicRectangle(Rectangle2D rect)
public BasicRectangle(double x,
double y,
double width,
double height)
public BasicRectangle(double x,
double y,
double width,
double height,
Paint fill)
public BasicRectangle(Rectangle2D bounds, Paint fill)
public BasicRectangle(double x,
double y,
double width,
double height,
float lineWidth)
public BasicRectangle(double x,
double y,
double width,
double height,
Paint fill,
float lineWidth)
public void translate(double x,
double y)
translate in interface Figuretranslate in class BasicFigureCopyright © 2025 Central Laboratory of the Research Councils. All Rights Reserved.