public interface GeometryDrawer| Modifier and Type | Method and Description |
|---|---|
void |
drawCircle(double x, double y, double radius, DrawMode
Draw a circle.
|
void |
drawGeometry(Geometry
Draw the given geometry on this surface.
|
void |
drawRectangle(double x, double y, double width, double height, DrawMode
Draw a rectangle that is defined by a top left position and a width and height.
|
void |
drawRectangleAbsolute(double x1, double y1, double x2, double y2, DrawMode
Draw a rectangle that is defined by it's absolute positions of each corner.
|
void |
drawRectangleCentered(double x, double y, double width, double height, DrawMode
Draw a rectangle that is defined by a center position and a width and height.
|
void |
drawSegment(double x1, double y1, double x2, double y2)
Draw a segment on the surface.
|
void |
drawString(double x, double y, String
Draw this string to the given position.
|
void |
setColorBackground(ColorCode
Set the color to use for filling in future drawing operations.
|
void |
setColorForeground(ColorCode
Set the color to use for lines in future drawing operations.
|
void |
setLineWidth(double width)
Set the width of lines in future drawing operations.
|
void setColorForeground(ColorCodec)
c - the color for lines.
void setColorBackground(ColorCodec)
c - the color for fillings.
void setLineWidth(double width)
width - the width of lines.
void drawGeometry(Geometryg, DrawMode mode)
g - the geometry to draw.
mode - the drawing mode
void drawSegment(double x1,
double y1,
double x2,
double y2)
x1 - the first coordinate's x component
y1 - the first coordinate's y component
x2 - the second coordinate's x component
y2 - the second coordinate's y component
void drawRectangleAbsolute(double x1,
double y1,
double x2,
double y2,
DrawMode mode)
x1 - the left x coordinate.
y1 - the top y coordinate.
x2 - the right x coordinate.
y2 - the bottom y coordinate.
mode - the drawing mode
void drawRectangle(double x,
double y,
double width,
double height,
DrawMode mode)
x - the left x coordinate.
y - the top y coordinate.
width - the width of the rectangle.
height - the height of the rectangle.
mode - the drawing mode
void drawRectangleCentered(double x,
double y,
double width,
double height,
DrawMode mode)
x - the center x coordinate.
y - the center y coordinate.
width - the width of the rectangle.
height - the height of the rectangle.
mode - the drawing mode
void drawCircle(double x,
double y,
double radius,
DrawMode mode)
x - the x coordinate of the circle's center.
y - the y coordinate of the circle's center.
radius - the radius.
mode - the drawing mode
void drawString(double x,
double y,
String text,
int fontsize,
int xoff,
int yoff)
x - position coordinate
y - position coordinate
text - the text to draw
fontsize - the size of font
xoff - x offset in image space
yoff - y offset in image space