public interface Segment
Line
which should be displayed without changing text
attributes.Modifier and Type | Method and Description |
---|---|
void |
draw(java.awt.Graphics g,
int y,
Fonts fonts)
Draws this segment to a
Graphics instance. |
java.awt.geom.RectangularShape |
getSize(Fonts fonts,
java.awt.font.FontRenderContext context)
Returns the size of this segment in pixels.
|
void |
setWidth(int width)
Sets the width to display the segment.
|
void |
setX(int x)
Sets the x-coordinate to display the segment.
|
void |
setY(int y)
Sets the y-coordinate to display the segment.
|
void |
updateAttributes(Fonts fonts,
java.awt.font.FontRenderContext context)
Updates the cached attributes of this segment.
|
void draw(@NotNull java.awt.Graphics g, int y, @NotNull Fonts fonts)
Graphics
instance.g
- the graphics to draw toy
- the y-coordinate to draw tofonts
- the fonts to use@NotNull java.awt.geom.RectangularShape getSize(@NotNull Fonts fonts, @NotNull java.awt.font.FontRenderContext context)
fonts
- the fonts instance to usecontext
- the font render context to usevoid setWidth(int width)
width
- the widthvoid setX(int x)
x
- the x-coordinatevoid setY(int y)
y
- the y-coordinatevoid updateAttributes(@NotNull Fonts fonts, @NotNull java.awt.font.FontRenderContext context)
fonts
- the fonts instance to usecontext
- the font render context to use