Font lastStyledFont
The font lastFont with applied italics and bold settings.
void setGraphicsFlags(final Graphics gfx, final Font font)
Sets the text color and font of the specified graphics context to that specified in this style.
final boolean bold
Whether the text should be bold.
SyntaxStyle(final Color color, final boolean italic, final boolean bold)
Creates a new instance.
final boolean italic
Whether the text should be italics.
FontMetrics fontMetrics
The font metrics for lastStyledFont.
FontMetrics getFontMetrics(final Font font, final Graphics g)
Returns the font metrics for the styled font.
void updateStyledFont(final Font font)
Update lastFont and lastStyledFont for the given font.
Font lastFont
The base font used to calculate lastStyledFont.
Font getStyledFont(final Font font)
Returns the specified font, but with the style's bold and italic flags applied.
A simple text style class.