Package com.illumon.iris.db.plot.themes
Class ThemeImpl
java.lang.Object
com.illumon.iris.db.plot.themes.ThemeImpl
- All Implemented Interfaces:
Theme
,Serializable
,Cloneable
public class ThemeImpl extends Object implements Theme
The theme of a chart.
Sets the default colors and fonts of various parts of a chart, such as
axes, gridlines, and background colors, axes and figure title fonts.
- See Also:
- Serialized Form
-
Constructor Summary
Constructors Constructor Description ThemeImpl()
-
Method Summary
Modifier and Type Method Description ThemeImpl
axisColor(Paint color)
Sets the Axis's color.ThemeImpl
axisColor(String color)
Sets the Axis's color.ThemeImpl
axisTickLabelColor(Paint color)
Sets the color of the Axis's tick labels.ThemeImpl
axisTickLabelColor(String color)
Sets the color of the Axis's tick labels.ThemeImpl
axisTicksFont(Font font)
Sets the Font of the Axis's tick labels.ThemeImpl
axisTicksFont(String family, String style, int size)
Sets the Font of the Axis's tick labels.ThemeImpl
axisTitleColor(Paint color)
Sets the color of the Axis's title.ThemeImpl
axisTitleColor(String color)
Sets the color of the Axis's title.ThemeImpl
axisTitleFont(Font font)
Sets the Font of the Axis's title.ThemeImpl
axisTitleFont(String family, String style, int size)
Sets the Font of the Axis's title.ThemeImpl
chartBackgroundColor(Paint color)
Sets the color of the Chart's background.ThemeImpl
chartBackgroundColor(String color)
Sets the color of the Chart's background.ThemeImpl
chartTitleColor(Paint color)
Sets the color of the Chart's title.ThemeImpl
chartTitleColor(String color)
Sets the color of the Chart's title.ThemeImpl
chartTitleFont(Font font)
Sets the Font of the Chart's title.ThemeImpl
chartTitleFont(String family, String style, int size)
Sets the Font of the Chart's title.ThemeImpl
copy()
Deep copy of this theme.boolean
equals(Object obj)
ThemeImpl
figureTextColor(Paint color)
Defines the color of the default Font of the Figure's text.ThemeImpl
figureTextColor(String color)
Defines the color of the default Font of the Figure's text.ThemeImpl
figureTextFont(Font font)
Defines the default Font of the Figure's text.ThemeImpl
figureTextFont(String family, String style, int size)
Defines the default Font of the Figure's text.ThemeImpl
figureTitleColor(Paint color)
Sets the color of the Figure's title.ThemeImpl
figureTitleColor(String color)
Sets the color of the default Font of the Figure's text.ThemeImpl
figureTitleFont(Font font)
Sets the Font of the Figure's title.ThemeImpl
figureTitleFont(String family, String style, int size)
Sets the Font of the Figure's title.Paint
getAxisColor()
Gets the color of the Axes.Paint
getAxisTickLabelColor()
Gets thePaint
used for the color of each tick label.Font
getAxisTicksFont()
Gets the font used for the Axis's title.Paint
getAxisTitleColor()
Font
getAxisTitleFont()
Gets the font used for the Axis's title.Paint
getChartBackgroundColor()
Gets the color used for the background of the Chart.Paint
getChartTitleColor()
Font
getChartTitleFont()
Gets the font used for the Chart's title.boolean
getDisplayXGridLines()
boolean
getDisplayYGridLines()
Paint
getFigureTextColor()
Gets thePaint
of the figure's text.Font
getFigureTextFont()
Gets theFont
of the figure's text.Paint
getFigureTitleColor()
Gets the color used for the title of the Figure.Font
getFigureTitleFont()
Gets the font used for the Figure's title.Paint
getGridLineColor()
Font
getLegendFont()
Gets the font used for the Chart's legend.Paint
getLegendTextColor()
Gets the color used for the legend's font.String
getName()
Gets the name of this theme.Paint
getPointLabelColor()
Gets the color used for point labels.Font
getPointLabelFont()
Gets the font used for point labels.Paint
getSeriesColor(int i)
Gets the color of thei
-th series in the ChartColorPalette
getSeriesColorPalette()
Gets theColorPalette
used for eachChart
.ThemeImpl
gridLineColor(Paint color)
Sets the color of the Chart's grid lines.ThemeImpl
gridLineColor(String color)
Sets the color of the Chart's grid lines.ThemeImpl
gridLinesVisible(boolean visible)
ThemeImpl
gridLinesVisible(String visible)
int
hashCode()
ThemeImpl
legendFont(Font font)
Sets the Font of the legend's text.ThemeImpl
legendFont(String family, String style, int size)
Sets the Font of the legend's text.ThemeImpl
legendTextColor(Paint color)
Sets the color of the legned's text.ThemeImpl
legendTextColor(String color)
Sets the color of the legend's text.ThemeImpl
name(String name)
Sets the name of the ThemeThemeImpl
pointLabelColor(Paint color)
Sets the color used for point labels.ThemeImpl
pointLabelColor(String color)
Sets the color used for point labels.ThemeImpl
pointLabelFont(Font font)
Sets the font used for point labels.ThemeImpl
pointLabelFont(String family, String style, int size)
Sets the font used for point labels.ThemeImpl
seriesColorGenerator(ColorPalette seriesColorPalette)
Sets the ColorPalette of this Theme.ThemeImpl
xGridLinesVisible(boolean visible)
ThemeImpl
xGridLinesVisible(String visible)
ThemeImpl
yGridLinesVisible(boolean visible)
ThemeImpl
yGridLinesVisible(String visible)
-
Constructor Details
-
ThemeImpl
public ThemeImpl()
-
-
Method Details
-
getName
Description copied from interface:Theme
Gets the name of this theme. -
getFigureTitleFont
Description copied from interface:Theme
Gets the font used for the Figure's title.- Specified by:
getFigureTitleFont
in interfaceTheme
- Returns:
- Figure's title font
-
getFigureTitleColor
Description copied from interface:Theme
Gets the color used for the title of the Figure.- Specified by:
getFigureTitleColor
in interfaceTheme
- Returns:
- color of the Figure's title
-
getChartTitleFont
Description copied from interface:Theme
Gets the font used for the Chart's title.- Specified by:
getChartTitleFont
in interfaceTheme
- Returns:
- Chart's title font
-
getChartBackgroundColor
Description copied from interface:Theme
Gets the color used for the background of the Chart.- Specified by:
getChartBackgroundColor
in interfaceTheme
- Returns:
- background color of the Chart
-
getLegendFont
Description copied from interface:Theme
Gets the font used for the Chart's legend.- Specified by:
getLegendFont
in interfaceTheme
- Returns:
- legend's font
-
getLegendTextColor
Description copied from interface:Theme
Gets the color used for the legend's font.- Specified by:
getLegendTextColor
in interfaceTheme
- Returns:
- color of the legend's font
-
getPointLabelFont
Description copied from interface:Theme
Gets the font used for point labels.- Specified by:
getPointLabelFont
in interfaceTheme
- Returns:
- font used for point labels.
-
getPointLabelColor
Description copied from interface:Theme
Gets the color used for point labels.- Specified by:
getPointLabelColor
in interfaceTheme
- Returns:
- color used for point labels.
-
getAxisColor
Description copied from interface:Theme
Gets the color of the Axes.- Specified by:
getAxisColor
in interfaceTheme
- Returns:
- color of the Axes
-
getAxisTitleFont
Description copied from interface:Theme
Gets the font used for the Axis's title.- Specified by:
getAxisTitleFont
in interfaceTheme
- Returns:
- Axis's title's font
-
getAxisTicksFont
Description copied from interface:Theme
Gets the font used for the Axis's title.- Specified by:
getAxisTicksFont
in interfaceTheme
- Returns:
- Axis's title's font
-
getSeriesColor
Description copied from interface:Theme
Gets the color of thei
-th series in the Chart- Specified by:
getSeriesColor
in interfaceTheme
- Parameters:
i
- color index- Returns:
- i-th color of the Chart's
ColorPalette
-
getFigureTextColor
Description copied from interface:Theme
Gets thePaint
of the figure's text.- Specified by:
getFigureTextColor
in interfaceTheme
- Returns:
Paint
of the figure's text
-
getFigureTextFont
Description copied from interface:Theme
Gets theFont
of the figure's text.- Specified by:
getFigureTextFont
in interfaceTheme
- Returns:
Font
of the figure's text
-
getChartTitleColor
Description copied from interface:Theme
- Specified by:
getChartTitleColor
in interfaceTheme
- Returns:
Paint
used for the title of eachChart
-
getGridLineColor
Description copied from interface:Theme
- Specified by:
getGridLineColor
in interfaceTheme
- Returns:
Paint
of eachChart
's text
-
getDisplayXGridLines
public boolean getDisplayXGridLines()- Specified by:
getDisplayXGridLines
in interfaceTheme
- Returns:
- whether to draw the grid lines in the x direction
-
getDisplayYGridLines
public boolean getDisplayYGridLines()- Specified by:
getDisplayYGridLines
in interfaceTheme
- Returns:
- whether to draw the grid lines in the y direction
-
getAxisTitleColor
Description copied from interface:Theme
- Specified by:
getAxisTitleColor
in interfaceTheme
- Returns:
Paint
used for the color of eachAxis
-
getAxisTickLabelColor
Description copied from interface:Theme
Gets thePaint
used for the color of each tick label.- Specified by:
getAxisTickLabelColor
in interfaceTheme
- Returns:
Paint
used for the color of each tick label
-
getSeriesColorPalette
Description copied from interface:Theme
Gets theColorPalette
used for eachChart
.- Specified by:
getSeriesColorPalette
in interfaceTheme
- Returns:
ColorPalette
used for eachChart
-
copy
Description copied from interface:Theme
Deep copy of this theme. -
name
Description copied from interface:Theme
Sets the name of the Theme -
figureTextFont
Description copied from interface:Theme
Defines the default Font of the Figure's text. If no Font is set for one of the Theme's properties, this font is used.- Specified by:
figureTextFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme
-
figureTextFont
Description copied from interface:Theme
Defines the default Font of the Figure's text. If no Font is set for one of the Theme's properties, this font is used.- Specified by:
figureTextFont
in interfaceTheme
- Parameters:
family
- family; if null, set to Arialstyle
- style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme
-
figureTextColor
Description copied from interface:Theme
Defines the color of the default Font of the Figure's text. If no Color is set for one of the Theme's properties, this color is used.- Specified by:
figureTextColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
figureTextColor
Description copied from interface:Theme
Defines the color of the default Font of the Figure's text. If no Color is set for one of the Theme's properties, this color is used.- Specified by:
figureTextColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
figureTitleFont
Description copied from interface:Theme
Sets the Font of the Figure's title.- Specified by:
figureTitleFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme
-
figureTitleFont
Description copied from interface:Theme
Sets the Font of the Figure's title.- Specified by:
figureTitleFont
in interfaceTheme
- Parameters:
family
- font family; if null, set to Arialstyle
- font style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme
-
figureTitleColor
Description copied from interface:Theme
Sets the color of the Figure's title.- Specified by:
figureTitleColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
figureTitleColor
Description copied from interface:Theme
Sets the color of the default Font of the Figure's text. If no Color is set for one of the Theme's properties, this color is used.- Specified by:
figureTitleColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
chartTitleFont
Description copied from interface:Theme
Sets the Font of the Chart's title.- Specified by:
chartTitleFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme
-
chartTitleFont
Description copied from interface:Theme
Sets the Font of the Chart's title.- Specified by:
chartTitleFont
in interfaceTheme
- Parameters:
family
- font family; if null, set to Arialstyle
- font style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme
-
chartTitleColor
Description copied from interface:Theme
Sets the color of the Chart's title.- Specified by:
chartTitleColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
chartTitleColor
Description copied from interface:Theme
Sets the color of the Chart's title.- Specified by:
chartTitleColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
chartBackgroundColor
Description copied from interface:Theme
Sets the color of the Chart's background.- Specified by:
chartBackgroundColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
chartBackgroundColor
Description copied from interface:Theme
Sets the color of the Chart's background.- Specified by:
chartBackgroundColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
gridLineColor
Description copied from interface:Theme
Sets the color of the Chart's grid lines.- Specified by:
gridLineColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
gridLineColor
Description copied from interface:Theme
Sets the color of the Chart's grid lines.- Specified by:
gridLineColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
gridLinesVisible
- Specified by:
gridLinesVisible
in interfaceTheme
- Parameters:
visible
- whether grid lines will be drawn- Returns:
- this Theme
-
gridLinesVisible
- Specified by:
gridLinesVisible
in interfaceTheme
- Parameters:
visible
- whether grid lines will be drawn- Returns:
- this Theme
-
xGridLinesVisible
- Specified by:
xGridLinesVisible
in interfaceTheme
- Parameters:
visible
- whether grid lines in the x direction will be drawn- Returns:
- this Theme
-
xGridLinesVisible
- Specified by:
xGridLinesVisible
in interfaceTheme
- Parameters:
visible
- whether grid lines in the x direction will be drawn- Returns:
- this Theme
-
yGridLinesVisible
- Specified by:
yGridLinesVisible
in interfaceTheme
- Parameters:
visible
- whether grid lines in the y direction will be drawn- Returns:
- this Theme
-
yGridLinesVisible
- Specified by:
yGridLinesVisible
in interfaceTheme
- Parameters:
visible
- whether grid lines in the y direction will be drawn- Returns:
- this Theme
-
axisColor
Description copied from interface:Theme
Sets the Axis's color. -
axisColor
Description copied from interface:Theme
Sets the Axis's color. -
axisTitleFont
Description copied from interface:Theme
Sets the Font of the Axis's title.- Specified by:
axisTitleFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme
-
axisTitleFont
Description copied from interface:Theme
Sets the Font of the Axis's title.- Specified by:
axisTitleFont
in interfaceTheme
- Parameters:
family
- font family; if null, set to Arialstyle
- font style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme
-
axisTitleColor
Description copied from interface:Theme
Sets the color of the Axis's title.- Specified by:
axisTitleColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
axisTitleColor
Description copied from interface:Theme
Sets the color of the Axis's title.- Specified by:
axisTitleColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
axisTicksFont
Description copied from interface:Theme
Sets the Font of the Axis's tick labels.- Specified by:
axisTicksFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme
-
axisTicksFont
Description copied from interface:Theme
Sets the Font of the Axis's tick labels.- Specified by:
axisTicksFont
in interfaceTheme
- Parameters:
family
- font family; if null, set to Arialstyle
- font style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme
-
axisTickLabelColor
Description copied from interface:Theme
Sets the color of the Axis's tick labels.- Specified by:
axisTickLabelColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
axisTickLabelColor
Description copied from interface:Theme
Sets the color of the Axis's tick labels.- Specified by:
axisTickLabelColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
legendFont
Description copied from interface:Theme
Sets the Font of the legend's text.- Specified by:
legendFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme
-
legendFont
Description copied from interface:Theme
Sets the Font of the legend's text.- Specified by:
legendFont
in interfaceTheme
- Parameters:
family
- font family; if null, set to Arialstyle
- font style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme
-
legendTextColor
Description copied from interface:Theme
Sets the color of the legned's text.- Specified by:
legendTextColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
legendTextColor
Description copied from interface:Theme
Sets the color of the legend's text.- Specified by:
legendTextColor
in interfaceTheme
- Parameters:
color
- color- Returns:
- this Theme
-
pointLabelFont
Description copied from interface:Theme
Sets the font used for point labels.- Specified by:
pointLabelFont
in interfaceTheme
- Parameters:
font
- font- Returns:
- this Theme.
-
pointLabelFont
Description copied from interface:Theme
Sets the font used for point labels.- Specified by:
pointLabelFont
in interfaceTheme
- Parameters:
family
- font family; if null, set to Arialstyle
- font style; if null, set toFont.FontStyle
PLAINsize
- the point size of the Font- Returns:
- this Theme.
-
pointLabelColor
Description copied from interface:Theme
Sets the color used for point labels.- Specified by:
pointLabelColor
in interfaceTheme
- Parameters:
color
- point label color- Returns:
- this Theme.
-
pointLabelColor
Description copied from interface:Theme
Sets the color used for point labels.- Specified by:
pointLabelColor
in interfaceTheme
- Parameters:
color
- point label color- Returns:
- this Theme.
-
seriesColorGenerator
Description copied from interface:Theme
Sets the ColorPalette of this Theme.- Specified by:
seriesColorGenerator
in interfaceTheme
- Parameters:
seriesColorPalette
- color palette- Returns:
- this Theme
-
equals
-
hashCode
public int hashCode()
-