Class TextStyle

java.lang.Object
com.inductiveautomation.snap.text.TextStyle
All Implemented Interfaces:
RMTypes, TextTypes, Cloneable

public class TextStyle extends Object implements TextTypes, Cloneable
A class to hold style attributes for a text run.
  • Constructor Details

    • TextStyle

      public TextStyle()
  • Method Details

    • getFont

      public SnapFont getFont()
      Returns the font for this run.
    • getColor

      public SnapColor getColor()
      Returns the color for this run.
    • isUnderlined

      public boolean isUnderlined()
      Returns whether this run is underlined.
    • getUnderlineStyle

      public int getUnderlineStyle()
      Returns the underline style of this run.
    • getScripting

      public int getScripting()
      Returns the scripting for this run (1=SuperScripting, -1=Subscripting, 0=none).
    • getCharSpacing

      public double getCharSpacing()
      Returns the char spacing.
    • getLink

      public TextLink getLink()
      Returns the link.
    • equals

      public boolean equals(Object anObj)
      Standard equals implementation.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Standard hashCode implementation.
      Overrides:
      hashCode in class Object
    • clone

      public TextStyle clone()
      Standard clone implementation.
      Overrides:
      clone in class Object
    • clone

      public TextStyle clone(SnapFont aFont)
      Clone with font.
    • clone

      public TextStyle clone(SnapColor aColor)
      Clone with color.
    • clone

      public TextStyle clone(String aKey, Object aValue)
      Clone with key/value.
    • clone

      public TextStyle clone(Map<?,?> aMap)
      Clone with map.
    • toString

      public String toString()
      Standard toString implementation.
      Overrides:
      toString in class Object