Class AbstractText<T extends AbstractText<T>>

java.lang.Object
io.jmix.chartsflowui.kit.component.model.ChartObservableObject
io.jmix.chartsflowui.kit.component.model.shared.AbstractText<T>
Type Parameters:
T - origin text class type
All Implemented Interfaces:
HasText<T>, Serializable
Direct Known Subclasses:
AbstractRichText, Label, TextStyle

public abstract class AbstractText<T extends AbstractText<T>> extends ChartObservableObject implements HasText<T>
The base class for text components.
See Also:
  • Field Details

    • color

      protected Color color
    • fontStyle

      protected FontStyle fontStyle
    • fontWeight

      protected String fontWeight
    • fontFamily

      protected String fontFamily
    • fontSize

      protected Integer fontSize
    • lineHeight

      protected Integer lineHeight
    • width

      protected Integer width
    • height

      protected Integer height
    • textBorderColor

      protected Color textBorderColor
    • textBorderWidth

      protected Double textBorderWidth
    • textBorderType

      protected String textBorderType
    • textBorderDashOffset

      protected Integer textBorderDashOffset
    • textShadowColor

      protected Color textShadowColor
    • textShadowBlur

      protected Integer textShadowBlur
    • textShadowOffsetX

      protected Integer textShadowOffsetX
    • textShadowOffsetY

      protected Integer textShadowOffsetY
    • overflow

      protected Overflow overflow
    • ellipsis

      protected String ellipsis
  • Constructor Details

    • AbstractText

      public AbstractText()
  • Method Details

    • getColor

      public Color getColor()
    • setColor

      public void setColor(Color color)
    • getFontStyle

      public FontStyle getFontStyle()
    • setFontStyle

      public void setFontStyle(FontStyle fontStyle)
    • getFontWeight

      public String getFontWeight()
    • setFontWeight

      public void setFontWeight(String fontWeight)
    • getFontFamily

      public String getFontFamily()
    • setFontFamily

      public void setFontFamily(String fontFamily)
    • getFontSize

      public Integer getFontSize()
    • setFontSize

      public void setFontSize(Integer fontSize)
    • getLineHeight

      public Integer getLineHeight()
    • setLineHeight

      public void setLineHeight(Integer lineHeight)
    • getWidth

      public Integer getWidth()
    • setWidth

      public void setWidth(Integer width)
    • getHeight

      public Integer getHeight()
    • setHeight

      public void setHeight(Integer height)
    • getTextBorderColor

      public Color getTextBorderColor()
      Specified by:
      getTextBorderColor in interface HasText<T extends AbstractText<T>>
      Returns:
      stroke color of the text
    • setTextBorderColor

      public void setTextBorderColor(Color textBorderColor)
      Description copied from interface: HasText
      Sets a stroke color of the text or replaces an existing one.
      Specified by:
      setTextBorderColor in interface HasText<T extends AbstractText<T>>
      Parameters:
      textBorderColor - color to set
    • getTextBorderWidth

      public Double getTextBorderWidth()
      Specified by:
      getTextBorderWidth in interface HasText<T extends AbstractText<T>>
      Returns:
      stroke line width of the text in pixels
    • setTextBorderWidth

      public void setTextBorderWidth(Double textBorderWidth)
      Description copied from interface: HasText
      Sets a stroke line width of the text or replaces an existing one.
      Specified by:
      setTextBorderWidth in interface HasText<T extends AbstractText<T>>
      Parameters:
      textBorderWidth - line width to set in pixels
    • getTextBorderType

      public String getTextBorderType()
      Specified by:
      getTextBorderType in interface HasText<T extends AbstractText<T>>
      Returns:
      stroke line type of the text
    • setTextBorderType

      public void setTextBorderType(String textBorderType)
      Description copied from interface: HasText
      Sets a stroke line type of the text or replaces an existing one.
      Possible values are:
      • solid
      • dashed
      • dotted
      Since v5.0.0, it can also be a number. For more flexible customization use JmixChart.setNativeJson(String).
      Specified by:
      setTextBorderType in interface HasText<T extends AbstractText<T>>
      Parameters:
      textBorderType - stroke line type to set
    • getTextBorderDashOffset

      public Integer getTextBorderDashOffset()
      Specified by:
      getTextBorderDashOffset in interface HasText<T extends AbstractText<T>>
      Returns:
      offset of the line dash
    • setTextBorderDashOffset

      public void setTextBorderDashOffset(Integer textBorderDashOffset)
      Description copied from interface: HasText
      Sets offset of the line dash or replaces an existing one.
      Specified by:
      setTextBorderDashOffset in interface HasText<T extends AbstractText<T>>
      Parameters:
      textBorderDashOffset - offset of the line dash to set
      See Also:
    • getTextShadowColor

      public Color getTextShadowColor()
      Specified by:
      getTextShadowColor in interface HasText<T extends AbstractText<T>>
      Returns:
      text shadow color
    • setTextShadowColor

      public void setTextShadowColor(Color textShadowColor)
      Description copied from interface: HasText
      Sets a color of the text shadow or replaces an existing one.
      Specified by:
      setTextShadowColor in interface HasText<T extends AbstractText<T>>
      Parameters:
      textShadowColor - text shadow color to set
    • getTextShadowBlur

      public Integer getTextShadowBlur()
      Specified by:
      getTextShadowBlur in interface HasText<T extends AbstractText<T>>
      Returns:
      shadow blur of the text itself
    • setTextShadowBlur

      public void setTextShadowBlur(Integer textShadowBlur)
      Description copied from interface: HasText
      Sets a depth of text shadow blur or replaces an existing one.
      Specified by:
      setTextShadowBlur in interface HasText<T extends AbstractText<T>>
      Parameters:
      textShadowBlur - depth of text shadow blur
    • getTextShadowOffsetX

      public Integer getTextShadowOffsetX()
      Specified by:
      getTextShadowOffsetX in interface HasText<T extends AbstractText<T>>
      Returns:
      horizontal offset for text shadow in pixels
    • setTextShadowOffsetX

      public void setTextShadowOffsetX(Integer textShadowOffsetX)
      Description copied from interface: HasText
      Sets horizontal offset for text shadow or replaces an existing one.
      Specified by:
      setTextShadowOffsetX in interface HasText<T extends AbstractText<T>>
      Parameters:
      textShadowOffsetX - offset to set in pixels
    • getTextShadowOffsetY

      public Integer getTextShadowOffsetY()
      Specified by:
      getTextShadowOffsetY in interface HasText<T extends AbstractText<T>>
      Returns:
      vertical offset for text shadow in pixels
    • setTextShadowOffsetY

      public void setTextShadowOffsetY(Integer textShadowOffsetY)
      Description copied from interface: HasText
      Sets vertical offset for text shadow or replaces an existing one.
      Specified by:
      setTextShadowOffsetY in interface HasText<T extends AbstractText<T>>
      Parameters:
      textShadowOffsetY - offset to set in pixels
    • getOverflow

      public Overflow getOverflow()
    • setOverflow

      public void setOverflow(Overflow overflow)
    • getEllipsis

      public String getEllipsis()
    • setEllipsis

      public void setEllipsis(String ellipsis)
    • withColor

      public T withColor(Color color)
    • withFontStyle

      public T withFontStyle(FontStyle fontStyle)
    • withFontWeight

      public T withFontWeight(String fontWeight)
    • withFontFamily

      public T withFontFamily(String fontFamily)
    • withFontSize

      public T withFontSize(Integer fontSize)
    • withLineHeight

      public T withLineHeight(Integer lineHeight)
    • withWidth

      public T withWidth(Integer width)
    • withHeight

      public T withHeight(Integer height)
    • withOverflow

      public T withOverflow(Overflow overflow)
    • withEllipsis

      public T withEllipsis(String ellipsis)