Package weka.core

Class FontHelper


  • public class FontHelper
    extends Object
    Wrapper 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 Detail

      • FontHelper

        public FontHelper​(Font font)
        Constructor
        Parameters:
        font - the font to wrap
      • FontHelper

        public FontHelper()
        No-op constructor (for beans conformity)
    • Method Detail

      • setFontName

        public void setFontName​(String fontName)
        Set the font name
        Parameters:
        fontName - the name of the font
      • getFontName

        public 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 Font getFont()
        Get the Font wrapped by this instance
        Returns:
        the Font object