public class FontFactory
extends java.lang.Object
Constructor and Description |
---|
FontFactory() |
Modifier and Type | Method and Description |
---|---|
static java.awt.Font |
build(java.lang.String fontFamilyName,
int style,
int size)
Creates a new
Font from the specified name, style and
point size. |
public static java.awt.Font build(java.lang.String fontFamilyName, int style, int size)
Font
from the specified name, style and
point size. Like new Font, but modifies the mapping of logical fonts.
E.g. Dialog will be translated to Segoe-UIfontFamilyName
- the font name. This can be a font face name or a font
family name, and may represent either a logical font or a physical
font
The family names for logical fonts are: Dialog, DialogInput,
Monospaced, Serif, or SansSerif.style
- the style constant for the Font
The style argument is an integer bitmask that may
be PLAIN, or a bitwise union of BOLD and/or ITALIC
(for example, ITALIC or BOLD|ITALIC).size
- the point size of the Font