Package weka.core
Class FontHelper
- java.lang.Object
-
- weka.core.FontHelper
-
public class FontHelper extends java.lang.ObjectWrapper class for Font objects. Fonts wrapped in this class can be serialized by Weka's XML serialization mechanism.- Version:
- $Revision: $
- Author:
- Mark Hall (mhall{[at]}pentaho{[dot]}com)
-
-
Constructor Summary
Constructors Constructor Description FontHelper()No-op constructor (for beans conformity)FontHelper(java.awt.Font font)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.FontgetFont()Get the Font wrapped by this instancejava.lang.StringgetFontName()Get the font nameintgetFontSize()Get the font sizeintgetFontStyle()Get the font style (see constants in Font class)voidsetFontName(java.lang.String fontName)Set the font namevoidsetFontSize(int size)Set the font sizevoidsetFontStyle(int style)Set the font style (see constants in Font class)
-
-
-
Method Detail
-
setFontName
public void setFontName(java.lang.String fontName)
Set the font name- Parameters:
fontName- the name of the font
-
getFontName
public java.lang.String getFontName()
Get the font name- Returns:
- the font name
-
setFontStyle
public void setFontStyle(int style)
Set the font style (see constants in Font class)- Parameters:
style- the style of the font
-
getFontStyle
public int getFontStyle()
Get the font style (see constants in Font class)- Returns:
- the style of the font
-
setFontSize
public void setFontSize(int size)
Set the font size- Parameters:
size- the size
-
getFontSize
public int getFontSize()
Get the font size- Returns:
- the size
-
getFont
public java.awt.Font getFont()
Get the Font wrapped by this instance- Returns:
- the Font object
-
-