Font getStyledFont(final Font font)
Returns the specified font, but with the style's bold and italic flags applied.
final boolean bold
Whether the text should be bold.
SyntaxStyle(final Color color, final boolean italic, final boolean bold)
Creates a new instance.
void updateStyledFont(final Font font)
Update lastFont and lastStyledFont for the given font.
Font lastFont
The base font used to calculate lastStyledFont.
Font lastStyledFont
The font lastFont with applied italics and bold settings.
A simple text style class.
FontMetrics fontMetrics
The font metrics for lastStyledFont.
final boolean italic
Whether the text should be italics.
FontMetrics getFontMetrics(final Font font, final Graphics g)
Returns the font metrics for the styled font.
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...