Class CartesianScaleTitle
- java.lang.Object
- 
- org.pepstock.charba.client.configuration.CartesianScaleTitle
 
- 
 public class CartesianScaleTitle extends Object When creating a chart, you want to tell the viewer what data they are viewing. To do this, you need to label the axis.
 The scale title configuration defines options for the scale title.
 Note that this only applies to cartesian axes.- Author:
- Andrea "Stock" Stocchero
 
- 
- 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description ScaleTitleAligngetAlign()Returns the alignment of the axis title.AxisgetAxis()Returns the axis instance.IsColorgetColor()Returns the font color.StringgetColorAsString()Returns the font color as string.FontgetFont()Returns the font element.PaddinggetPadding()Returns the padding element.List<String>getText()Returns the title text to display, as a list of strings.booleanisDisplay()If true, display the axis title.voidsetAlign(ScaleTitleAlign align)Sets the alignment of the axis title.voidsetColor(String color)Sets the font color.voidsetColor(IsColor color)Sets the font color.voidsetDisplay(boolean display)If true, display the axis title.voidsetText(String... text)Sets the title text to display.
 If specified as an array, text is rendered on multiple lines.
 
- 
- 
- 
Method Detail- 
getFontpublic Font getFont() Returns the font element.- Returns:
- the font
 
 - 
setColorpublic void setColor(IsColor color) Sets the font color.- Parameters:
- color- font color.
 
 - 
setColorpublic void setColor(String color) Sets the font color.- Parameters:
- color- font color.
 
 - 
getColorAsStringpublic String getColorAsString() Returns the font color as string.- Returns:
- font color as string
 
 - 
getColorpublic IsColor getColor() Returns the font color.- Returns:
- font color
 
 - 
getPaddingpublic Padding getPadding() Returns the padding element.- Returns:
- the padding
 
 - 
setDisplaypublic void setDisplay(boolean display) If true, display the axis title.- Parameters:
- display- If true, display the axis title.
 
 - 
isDisplaypublic boolean isDisplay() If true, display the axis title.- Returns:
- If true, display the axis title.
 
 - 
setTextpublic void setText(String... text) Sets the title text to display.
 If specified as an array, text is rendered on multiple lines.- Parameters:
- text- the title text to display.
 If specified as an array, text is rendered on multiple lines.
 
 - 
getTextpublic List<String> getText() Returns the title text to display, as a list of strings.- Returns:
- a list of strings
 
 - 
setAlignpublic void setAlign(ScaleTitleAlign align) Sets the alignment of the axis title.- Parameters:
- align- the alignment of the axis title
 
 - 
getAlignpublic ScaleTitleAlign getAlign() Returns the alignment of the axis title.- Returns:
- the alignment of the axis title
 
 - 
getAxispublic final Axis getAxis() Returns the axis instance.- Returns:
- the axis
 
 
- 
 
-