SwingTerminalFontConfiguration
public class AWTTerminalFontConfiguration extends Object
AWTTerminal
. By customizing this class, you can
choose which fonts are going to be used by an AWTTerminal
component and some other related settings.Modifier and Type | Class | Description |
---|---|---|
static class |
AWTTerminalFontConfiguration.BoldMode |
Controls how the SGR bold will take effect when enabled on a character.
|
Modifier | Constructor | Description |
---|---|---|
protected |
AWTTerminalFontConfiguration(boolean useAntiAliasing,
AWTTerminalFontConfiguration.BoldMode boldMode,
Font... fontsInOrderOfPriority) |
Modifier and Type | Method | Description |
---|---|---|
static Font[] |
filterMonospaced(Font... fonts) |
Given an array of fonts, returns another array with only the ones that are monospaced.
|
static AWTTerminalFontConfiguration |
getDefault() |
This is the default font settings that will be used if you don't specify anything
|
int |
getFontHeight() |
Returns the vertical size in pixels of the fonts configured
|
int |
getFontWidth() |
Returns the horizontal size in pixels of the fonts configured
|
boolean |
isAntiAliased() |
Returns
true if anti-aliasing has been enabled, false otherwise |
static AWTTerminalFontConfiguration |
newInstance(Font... fontsInOrderOfPriority) |
Creates a new font configuration from a list of fonts in order of priority.
|
protected static Font[] |
selectDefaultFont() |
Returns the default font to use depending on the platform
|
protected AWTTerminalFontConfiguration(boolean useAntiAliasing, AWTTerminalFontConfiguration.BoldMode boldMode, Font... fontsInOrderOfPriority)
protected static Font[] selectDefaultFont()
public static AWTTerminalFontConfiguration getDefault()
AWTTerminal
font configuration object with default values set uppublic static Font[] filterMonospaced(Font... fonts)
fonts
- Fonts to filter monospaced fonts frompublic static AWTTerminalFontConfiguration newInstance(Font... fontsInOrderOfPriority)
fontsInOrderOfPriority
- Fonts to use when drawing text, in order of prioritypublic int getFontWidth()
public int getFontHeight()
public boolean isAntiAliased()
true
if anti-aliasing has been enabled, false
otherwisetrue
if anti-aliasing has been enabled, false
otherwiseCopyright © 2020. All rights reserved.