@NotThreadSafe @MustImplementEqualsAndHashcode public class FontSpec extends Object
| Modifier and Type | Field and Description |
|---|---|
static Color |
DEFAULT_COLOR
The default font color: black
|
| Constructor and Description |
|---|
FontSpec(PreloadFont aPreloadFont,
float fFontSize) |
FontSpec(PreloadFont aPreloadFont,
float fFontSize,
Color aColor) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
FontSpec |
getCloneWithDifferentColor(Color aNewColor)
Return a clone of this object but with a different color.
|
FontSpec |
getCloneWithDifferentFont(PreloadFont aNewFont)
Return a clone of this object but with a different font.
|
FontSpec |
getCloneWithDifferentFontSize(float fNewFontSize)
Return a clone of this object but with a different font size.
|
Color |
getColor() |
float |
getFontSize() |
PreloadFont |
getPreloadFont() |
String |
getPreloadFontID() |
int |
hashCode() |
String |
toString() |
public static final Color DEFAULT_COLOR
public FontSpec(@Nonnull PreloadFont aPreloadFont, @Nonnegative float fFontSize)
public FontSpec(@Nonnull PreloadFont aPreloadFont, @Nonnegative float fFontSize, @Nonnull Color aColor)
@Nonnull public PreloadFont getPreloadFont()
null.@Nonnull @Nonempty public String getPreloadFontID()
null.@Nonnegative public float getFontSize()
@Nonnull public FontSpec getCloneWithDifferentFont(@Nonnull PreloadFont aNewFont)
aNewFont - The new font to use. Must not be null.@Nonnull public FontSpec getCloneWithDifferentFontSize(float fNewFontSize)
fNewFontSize - The new font size to use. Must be > 0.@Nonnull public FontSpec getCloneWithDifferentColor(@Nonnull Color aNewColor)
aNewColor - The new color to use. May not be null.Copyright © 2014–2016 Philip Helger. All rights reserved.