Class LegendLabels
java.lang.Object
software.xdev.chartjs.model.options.LegendLabels
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionsetBoxWidth
(Integer boxWidth) Width of coloured boxsetFontColor
(Object fontColor) Font color inherited from global configurationsetFontFamily
(String fontFamily) Font family inherited from global configurationsetFontSize
(Integer fontSize) Font size inherited from global configurationsetFontStyle
(FontStyle fontStyle) Font style inherited from global configurationsetGenerateLabels
(JavaScriptFunction generateLabels) Generates legend items for each thing in the legend.setPadding
(Integer padding) Padding between rows of colored boxessetUsePointStyle
(Boolean usePointStyle) Label style will match corresponding point style (size is based on fontSize, boxWidth is not used in this case).
-
Field Details
-
boxWidth
-
fontSize
-
fontStyle
-
fontColor
-
fontFamily
-
padding
-
generateLabels
-
usePointStyle
-
-
Constructor Details
-
LegendLabels
public LegendLabels()
-
-
Method Details
-
getBoxWidth
- See Also:
-
setBoxWidth
Width of coloured box
Default
40
-
getFontSize
- See Also:
-
setFontSize
Font size inherited from global configuration
Default
12
-
getFontStyle
- See Also:
-
setFontStyle
Font style inherited from global configuration
Default
"normal"
-
getFontColor
- See Also:
-
setFontColor
Font color inherited from global configuration
Default
"#666"
-
getFontFamily
- See Also:
-
setFontFamily
Font family inherited from global configuration
Default
"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif"
-
getPadding
- See Also:
-
setPadding
Padding between rows of colored boxes
Default
10
-
getGenerateLabels
- See Also:
-
setGenerateLabels
Generates legend items for each thing in the legend. Default implementation returns the text + styling for the color box. See Legend Item for details.
Default
function(chart) { }
-
getUsePointStyle
- See Also:
-
setUsePointStyle
Label style will match corresponding point style (size is based on fontSize, boxWidth is not used in this case).
Default
false
-