Interface FontProperties

All Known Implementing Classes:
AbstractFontElement, AbstractValueElement, FieldElement, FieldPart, JavaBean, Subreport, TextPart

public interface FontProperties
Interface for elements that displays text formatted with fonts.

This class is part of the RDC.
Since:
6.0
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Constant for the logical font Dialog.
    static final String
    Constant for the logical font Monospace (e.g.
    static final String
    Constant for the logical font SansSerif (e.g.
    static final String
    Constant for the logical font Serif (e.g.
    static final int
    Constant for the font style bold
    static final int
    Constant for the font style italic
    static final int
    Constant for the font style strikethrough
    static final int
    Constant for the font style underline
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the font color for the text in this element as an RGB value consisting of the red component in bits 16-23, the green component in bits 8-15, and the blue component in bits 0-7.
    Returns the property formula for the font color.
    Returns the font name for the text in this element.
    Returns the property formula for the font name.
    int
    Returns the font size for the text in this element, in points.
    Returns the property formula for the font size.
    int
    Returns the font size for the text in this element, in twips.
    int
    Returns the font style for the text in this element.
    Returns the property formula for the font style.
    Returns the formula field for whether the text is struck through or not.
    Returns the formula field for whether the text is underlined or not.
    boolean
    Returns whether the text in this element is bold or not.
    boolean
    Returns whether the text in this element is italic or not.
    boolean
    Returns whether the text in this element is struck through or not.
    boolean
    Returns whether the text in this element is underlined or not.
    void
    setBold(boolean newValue)
    Sets whether the text in this element is to be bold or not.
    void
    setFontColor(int newValue)
    Sets the font color for the text in this element to the given RGB value consisting of the red component in bits 16-23, the green component in bits 8-15, and the blue component in bits 0-7.
    void
    Sets the property formula for the font color.
    void
    setFontName(String newValue)
    Sets the font name for the text in this element.
    void
    Sets a property formula for the font name.
    void
    setFontSize(int newValue)
    Sets the font size for the text in this element in points.
    void
    Sets a property formula for the font size.
    void
    setFontSizeTwips(int newValue)
    Sets the font size for the text in this element in twips.
    void
    setFontStyle(int newValue)
    Sets the font style for the text.
    void
    Sets a property formula for the font style.
    void
    setItalic(boolean newValue)
    Sets whether the text in this element is to be italic or not.
    void
    setStrikeout(boolean newValue)
    Sets whether the text in this element is to be struck through or not.
    void
    Sets the formula field for whether the text is to be struck through or not.
    void
    setUnderline(boolean newValue)
    Sets whether the text in this element is to be underlined or not.
    void
    Sets the formula field for whether the text is to be underlined or not.
  • Field Details

    • FONT_SANS_SERIF

      static final String FONT_SANS_SERIF
      Constant for the logical font SansSerif (e.g. Arial).
      See Also:
    • FONT_SERIF

      static final String FONT_SERIF
      Constant for the logical font Serif (e.g. Times).
      See Also:
    • FONT_MONOSPACED

      static final String FONT_MONOSPACED
      Constant for the logical font Monospace (e.g. Courier New).
      See Also:
    • FONT_DIALOG

      static final String FONT_DIALOG
      Constant for the logical font Dialog.
      See Also:
    • FONT_STYLE_BOLD

      static final int FONT_STYLE_BOLD
      Constant for the font style bold
      See Also:
    • FONT_STYLE_ITALIC

      static final int FONT_STYLE_ITALIC
      Constant for the font style italic
      See Also:
    • FONT_STYLE_UNDERLINE

      static final int FONT_STYLE_UNDERLINE
      Constant for the font style underline
      See Also:
    • FONT_STYLE_STRIKETHROUGH

      static final int FONT_STYLE_STRIKETHROUGH
      Constant for the font style strikethrough
      See Also:
  • Method Details

    • setFontSize

      void setFontSize(int newValue)
      Sets the font size for the text in this element in points.
      Parameters:
      newValue - The font size in points
      Since:
      6.0
    • getFontSize

      int getFontSize()
      Returns the font size for the text in this element, in points.
      Returns:
      The font size in points.
      Since:
      6.0
    • setFontSizeFormula

      void setFontSizeFormula(FormulaField newFormula)
      Sets a property formula for the font size.
      Parameters:
      newFormula - The new property formula for the font size.
      Since:
      6.0
    • getFontSizeFormula

      FormulaField getFontSizeFormula()
      Returns the property formula for the font size.
      Returns:
      The FormulaField for the font size.
      Since:
      6.0
      See Also:
    • setFontName

      void setFontName(String newValue)
      Sets the font name for the text in this element.
      Parameters:
      newValue - The font name
      Since:
      6.0
    • getFontName

      String getFontName()
      Returns the font name for the text in this element.
      Returns:
      The font name
      Since:
      6.0
    • setFontNameFormula

      void setFontNameFormula(FormulaField newFormula)
      Sets a property formula for the font name.
      Parameters:
      newFormula - The new property formula for the font name.
      Since:
      6.0
    • getFontNameFormula

      FormulaField getFontNameFormula()
      Returns the property formula for the font name.
      Returns:
      The FormulaField for the font name.
      Since:
      6.0
    • setFontStyle

      void setFontStyle(int newValue)
      Sets the font style for the text. The font style can be FONT_STYLE_BOLD, FONT_STYLE_ITALIC, FONT_STYLE_UNDERLINE, and/or FONT_STYLE_STRIKETHROUGH. If more than one of these properties is to be set, they are to be connected via bitwise "OR", e.g. (FONT_STYLE_BOLD | FONT_STYLE_UNDERLINE).
      Parameters:
      newValue - Font style to set for this element.
      Since:
      6.0
      See Also:
    • getFontStyle

      int getFontStyle()
      Returns the font style for the text in this element. The font style can be FONT_STYLE_BOLD, FONT_STYLE_ITALIC, FONT_STYLE_UNDERLINE, and/or FONT_STYLE_STRIKETHROUGH. If more than one of these properties is set, they are connected via bitwise "OR", e.g. (FONT_STYLE_BOLD | FONT_STYLE_UNDERLINE).
      Returns:
      The font style
      Since:
      6.0
      See Also:
    • setFontStyleFormula

      void setFontStyleFormula(FormulaField newFormula)
      Sets a property formula for the font style.
      Parameters:
      newFormula - The new property formula for the font style.
      Since:
      6.0
    • getFontStyleFormula

      FormulaField getFontStyleFormula()
      Returns the property formula for the font style.
      Returns:
      The FormulaField for the font style.
      Since:
      6.0
    • setItalic

      void setItalic(boolean newValue)
      Sets whether the text in this element is to be italic or not.
      Parameters:
      newValue - true if the text is to be italic, false otherwise.
      Since:
      6.0
      See Also:
    • isItalic

      boolean isItalic()
      Returns whether the text in this element is italic or not.
      Returns:
      true if the text is italic, false otherwise.
      Since:
      7.0
      See Also:
    • isUnderline

      boolean isUnderline()
      Returns whether the text in this element is underlined or not.
      Returns:
      true if the text is underlined, false otherwise.
      Since:
      7.0
      See Also:
    • getUnderlineFormula

      FormulaField getUnderlineFormula()
      Returns the formula field for whether the text is underlined or not.
      Returns:
      the formula field for whether the text is underlined or not.
      Since:
      6.0
    • isStrikeout

      boolean isStrikeout()
      Returns whether the text in this element is struck through or not.
      Returns:
      true if the text is struck through, false otherwise.
      Since:
      7.0
      See Also:
    • getStrikeoutFormula

      FormulaField getStrikeoutFormula()
      Returns the formula field for whether the text is struck through or not.
      Returns:
      the formula field for whether the text is struck through or not.
      Since:
      6.0
    • setUnderline

      void setUnderline(boolean newValue)
      Sets whether the text in this element is to be underlined or not.
      Parameters:
      newValue - true if the text is to be underlined, false otherwise.
      Since:
      6.0
      See Also:
    • setUnderlineFormula

      void setUnderlineFormula(FormulaField newFormula)
      Sets the formula field for whether the text is to be underlined or not.
      Parameters:
      newFormula - the formula field for whether the text is to be underlined or not.
      Since:
      6.0
    • setStrikeout

      void setStrikeout(boolean newValue)
      Sets whether the text in this element is to be struck through or not.
      Parameters:
      newValue - true if the text is to be struck through, false otherwise.
      Since:
      6.0
      See Also:
    • setStrikeoutFormula

      void setStrikeoutFormula(FormulaField newFormula)
      Sets the formula field for whether the text is to be struck through or not.
      Parameters:
      newFormula - the formula field for whether the text is to be struck through or not.
      Since:
      6.0
    • isBold

      boolean isBold()
      Returns whether the text in this element is bold or not.
      Returns:
      true if the text is bold, false otherwise.
      Since:
      7.0
      See Also:
    • setBold

      void setBold(boolean newValue)
      Sets whether the text in this element is to be bold or not.
      Parameters:
      newValue - true if the text is to be bold, false otherwise.
      Since:
      6.0
      See Also:
    • setFontColor

      void setFontColor(int newValue)
      Sets the font color for the text in this element to the given RGB value consisting of the red component in bits 16-23, the green component in bits 8-15, and the blue component in bits 0-7.
      Parameters:
      newValue - The new RGB value to set as the font color for the text
      Since:
      6.0
    • setFontColorFormula

      void setFontColorFormula(FormulaField newFormula)
      Sets the property formula for the font color.
      Parameters:
      newFormula - The new property formula for the font color
      Since:
      6.0
    • getFontColor

      int getFontColor()
      Returns the font color for the text in this element as an RGB value consisting of the red component in bits 16-23, the green component in bits 8-15, and the blue component in bits 0-7.
      Returns:
      The font color of the text
      Since:
      6.0
    • getFontColorFormula

      FormulaField getFontColorFormula()
      Returns the property formula for the font color.
      Returns:
      The new property formula for the font color
      Since:
      6.0
    • setFontSizeTwips

      void setFontSizeTwips(int newValue)
      Sets the font size for the text in this element in twips.
      Parameters:
      newValue - The font size in twips
      Since:
      6.0
    • getFontSizeTwips

      int getFontSizeTwips()
      Returns the font size for the text in this element, in twips.
      Returns:
      The font size in twips.
      Since:
      6.0