public abstract class AbstractAxis<T extends AbstractAxis> extends AbstractChartObject
ValueAxis
and CategoryAxis
.
Constructor and Description |
---|
AbstractAxis() |
Modifier and Type | Method and Description |
---|---|
T |
addDateFormats(DateFormat... dateFormats)
Adds date formats.
|
T |
addGuides(Guide... guides)
Adds guides.
|
java.lang.Boolean |
getAutoGridCount() |
java.lang.Integer |
getAutoRotateAngle() |
java.lang.Integer |
getAutoRotateCount() |
java.lang.Double |
getAxisAlpha() |
Color |
getAxisColor() |
java.lang.Integer |
getAxisThickness() |
Balloon |
getBalloon() |
java.lang.Boolean |
getBoldLabels() |
java.lang.Boolean |
getBoldPeriodBeginning() |
java.lang.Boolean |
getCenterLabelOnFullPeriod() |
java.lang.Boolean |
getCenterLabels() |
java.lang.Boolean |
getCenterRotatedLabels() |
Color |
getColor() |
java.lang.Integer |
getDashLength() |
java.util.List<DateFormat> |
getDateFormats() |
java.lang.Double |
getFillAlpha() |
Color |
getFillColor() |
DayOfWeek |
getFirstDayOfWeek() |
java.lang.Integer |
getFontSize() |
java.lang.Double |
getGridAlpha() |
Color |
getGridColor() |
java.lang.Integer |
getGridCount() |
java.lang.Integer |
getGridThickness() |
java.util.List<Guide> |
getGuides() |
java.lang.Boolean |
getIgnoreAxisWidth() |
java.lang.Boolean |
getInside() |
java.lang.Double |
getLabelFrequency() |
java.lang.Integer |
getLabelOffset() |
java.lang.Integer |
getLabelRotation() |
java.lang.Boolean |
getLabelsEnabled() |
java.lang.Boolean |
getMarkPeriodChange() |
java.lang.Integer |
getMinHorizontalGap() |
java.lang.Double |
getMinorGridAlpha() |
java.lang.Boolean |
getMinorGridEnabled() |
java.lang.Integer |
getMinorTickLength() |
java.lang.Integer |
getMinVerticalGap() |
java.lang.Integer |
getOffset() |
Position |
getPosition() |
java.lang.Boolean |
getShowFirstLabel() |
java.lang.Boolean |
getShowLastLabel() |
java.lang.Integer |
getTickLength() |
java.lang.String |
getTitle() |
java.lang.Boolean |
getTitleBold() |
Color |
getTitleColor() |
java.lang.Integer |
getTitleFontSize() |
java.lang.Integer |
getTitleRotation() |
T |
setAutoGridCount(java.lang.Boolean autoGridCount)
Set autoGridCount to false if you don't want that the number of gridCount will be specified automatically,
according to the axis size.
|
T |
setAutoRotateAngle(java.lang.Integer autoRotateAngle)
Sets angle of label rotation, if the number of series exceeds autoRotateCount.
|
T |
setAutoRotateCount(java.lang.Integer autoRotateCount)
Sets auto rotate count.
|
T |
setAxisAlpha(java.lang.Double axisAlpha)
Sets axis opacity.
|
T |
setAxisColor(Color axisColor)
Sets axis color.
|
T |
setAxisThickness(java.lang.Integer axisThickness)
Sets thickness of the axis.
|
T |
setBalloon(Balloon balloon)
Sets balloon to the axis.
|
T |
setBoldLabels(java.lang.Boolean boldLabels)
Set boldLabels to true if axis labels should be bold.
|
T |
setBoldPeriodBeginning(java.lang.Boolean boldPeriodBeginning)
Set boldPeriodBeginning to false if you want chart will not try to highlight the beginning of
the periods, like month, in bold.
|
T |
setCenterLabelOnFullPeriod(java.lang.Boolean centerLabelOnFullPeriod)
Set centerLabelOnFullPeriod to false if you want labels never to be centered between grid lines.
|
T |
setCenterLabels(java.lang.Boolean centerLabels)
Set centerLabels to true if you want to center labels of the date-based axis (in case it's category axis,
equalSpacing must be false).
|
void |
setCenterRotatedLabels(java.lang.Boolean centerRotatedLabels)
In case you have rotated labels on horizontal axis, you can force-center them using this property.
|
T |
setColor(Color color)
Sets color of axis value labels.
|
T |
setDashLength(java.lang.Integer dashLength)
Sets length of a dash.
|
T |
setDateFormats(java.util.List<DateFormat> dateFormats)
Sets list of date formats of different periods.
|
T |
setFillAlpha(java.lang.Double fillAlpha)
Sets fill opacity.
|
T |
setFillColor(Color fillColor)
Set fill color.
|
T |
setFirstDayOfWeek(DayOfWeek firstDayOfWeek)
Sets first day of the week.
|
T |
setFontSize(java.lang.Integer fontSize)
Sets size of value labels text.
|
T |
setGridAlpha(java.lang.Double gridAlpha)
Sets opacity of grid lines.
|
T |
setGridColor(Color gridColor)
Sets color of grid lines.
|
T |
setGridCount(java.lang.Integer gridCount)
Sets number of grid lines.
|
T |
setGridThickness(java.lang.Integer gridThickness)
Sets thickness of grid lines.
|
T |
setGuides(java.util.List<Guide> guides)
Sets list of guides belonging to this axis
|
T |
setIgnoreAxisWidth(java.lang.Boolean ignoreAxisWidth)
Set ignoreAxisWidth to true if autoMargins of a chart is set to true, but you want this axis not to be
measured when calculating margin.
|
T |
setInside(java.lang.Boolean inside)
Set inside to true if values should be placed inside of plot area.
|
T |
setLabelFrequency(java.lang.Double labelFrequency)
Sets frequency at which labels should be placed.
|
T |
setLabelOffset(java.lang.Integer labelOffset)
Sets offset of axes labels.
|
T |
setLabelRotation(java.lang.Integer labelRotation)
Sets rotation angle of a label.
|
T |
setLabelsEnabled(java.lang.Boolean labelsEnabled)
Set labelsEnabled to false if you don't wont to display category axis labels and value axis values.
|
T |
setMarkPeriodChange(java.lang.Boolean markPeriodChange)
Set markPeriodChange to false if the start of longer periods shouldn't use a different date format and
shouldn't be bold.
|
T |
setMinHorizontalGap(java.lang.Integer minHorizontalGap)
Sets minimum cell width required for one span between grid lines.
|
T |
setMinorGridAlpha(java.lang.Double minorGridAlpha)
Sets opacity of minor grid.
|
T |
setMinorGridEnabled(java.lang.Boolean minorGridEnabled)
Set minorGridEnabled to true if minor grid should be displayed.
|
T |
setMinorTickLength(java.lang.Integer minorTickLength)
Sets length of minor grid tick.
|
T |
setMinVerticalGap(java.lang.Integer minVerticalGap)
Sets minimum cell height required for one span between grid lines.
|
T |
setOffset(java.lang.Integer offset)
Sets the distance of the axis to the plot area, in pixels.
|
T |
setPosition(Position position)
Sets position.
|
T |
setShowFirstLabel(java.lang.Boolean showFirstLabel)
Set showFirstLabel to false if you don't want to show first axis label.
|
T |
setShowLastLabel(java.lang.Boolean showLastLabel)
Set showFirstLabel to false if you don't want to show last axis label.
|
T |
setTickLength(java.lang.Integer tickLength)
Sets length of the tick marks.
|
T |
setTitle(java.lang.String title)
Sets title of the axis.
|
T |
setTitleBold(java.lang.Boolean titleBold)
Set titleBold to false if title shouldn't be bold.
|
T |
setTitleColor(Color titleColor)
Sets color of axis title.
|
T |
setTitleFontSize(java.lang.Integer titleFontSize)
Sets font size of axis title.
|
T |
setTitleRotation(java.lang.Integer titleRotation)
Sets rotation of axis title.
|
public java.lang.Boolean getAutoGridCount()
public T setAutoGridCount(java.lang.Boolean autoGridCount)
autoGridCount
- auto grid count optionpublic java.lang.Double getAxisAlpha()
public T setAxisAlpha(java.lang.Double axisAlpha)
axisAlpha
- axis opacitypublic Color getAxisColor()
public T setAxisColor(Color axisColor)
axisColor
- axis colorpublic java.lang.Integer getAxisThickness()
public T setAxisThickness(java.lang.Integer axisThickness)
axisThickness
- thickness of the axispublic Color getColor()
public T setColor(Color color)
color
- color of axis value labelspublic java.lang.Integer getDashLength()
public T setDashLength(java.lang.Integer dashLength)
dashLength
- length of a dashpublic java.lang.Double getFillAlpha()
public T setFillAlpha(java.lang.Double fillAlpha)
fillAlpha
- fill opacitypublic Color getFillColor()
public T setFillColor(Color fillColor)
fillColor
- fill colorpublic java.lang.Integer getFontSize()
public T setFontSize(java.lang.Integer fontSize)
fontSize
- size of value labels textpublic java.lang.Double getGridAlpha()
public T setGridAlpha(java.lang.Double gridAlpha)
gridAlpha
- opacity of grid linespublic Color getGridColor()
public T setGridColor(Color gridColor)
gridColor
- color of grid linespublic java.lang.Integer getGridCount()
public T setGridCount(java.lang.Integer gridCount)
gridCount
- grid countpublic java.lang.Integer getGridThickness()
public T setGridThickness(java.lang.Integer gridThickness)
gridThickness
- thickness of grid linespublic java.util.List<Guide> getGuides()
public T setGuides(java.util.List<Guide> guides)
guides
- list of guidespublic T addGuides(Guide... guides)
guides
- guidespublic java.lang.Boolean getIgnoreAxisWidth()
public T setIgnoreAxisWidth(java.lang.Boolean ignoreAxisWidth)
ignoreAxisWidth
- ignoreAxisWidth optionpublic java.lang.Boolean getInside()
public T setInside(java.lang.Boolean inside)
inside
- inside optionpublic java.lang.Double getLabelFrequency()
public T setLabelFrequency(java.lang.Double labelFrequency)
labelFrequency
- frequency at which labels should be placedpublic java.lang.Integer getLabelRotation()
public T setLabelRotation(java.lang.Integer labelRotation)
labelRotation
- rotation angle of a labelpublic java.lang.Boolean getLabelsEnabled()
public T setLabelsEnabled(java.lang.Boolean labelsEnabled)
labelsEnabled
- labelsEnabled optionpublic java.lang.Integer getMinHorizontalGap()
public T setMinHorizontalGap(java.lang.Integer minHorizontalGap)
minHorizontalGap
- minimum cell width required for one span between grid linespublic java.lang.Double getMinorGridAlpha()
public T setMinorGridAlpha(java.lang.Double minorGridAlpha)
minorGridAlpha
- opacity of minor gridpublic java.lang.Boolean getMinorGridEnabled()
public T setMinorGridEnabled(java.lang.Boolean minorGridEnabled)
minorGridEnabled
- minorGridEnabled optionpublic java.lang.Integer getMinVerticalGap()
public T setMinVerticalGap(java.lang.Integer minVerticalGap)
minVerticalGap
- minimum cell height required for one span between grid linespublic java.lang.Integer getOffset()
public T setOffset(java.lang.Integer offset)
offset
- the distance of the axis to the plot area, in pixelspublic Position getPosition()
public T setPosition(Position position)
position
- positionpublic java.lang.Boolean getShowFirstLabel()
public T setShowFirstLabel(java.lang.Boolean showFirstLabel)
ValueAxis
. With CategoryAxis
it wont work 100%, it depends on the period, zooming, etc.
There is no guaranteed way to force category axis to show or hide first label. If not set the default value is
true.showFirstLabel
- showFirstLabel optionpublic java.lang.Boolean getShowLastLabel()
public T setShowLastLabel(java.lang.Boolean showLastLabel)
ValueAxis
. With CategoryAxis
it wont work 100%, it depends on the period, zooming, etc.
There is no guaranteed way to force category axis to show or hide last label. If not set the default value is
true.showLastLabel
- showLastLabel optionpublic java.lang.Integer getTickLength()
public T setTickLength(java.lang.Integer tickLength)
tickLength
- length of the tick markspublic java.lang.String getTitle()
public T setTitle(java.lang.String title)
title
- title of the axispublic java.lang.Boolean getTitleBold()
public T setTitleBold(java.lang.Boolean titleBold)
titleBold
- titleBold optionpublic Color getTitleColor()
public T setTitleColor(Color titleColor)
titleColor
- color of axis titlepublic java.lang.Integer getTitleFontSize()
public T setTitleFontSize(java.lang.Integer titleFontSize)
titleFontSize
- font size of axis titlepublic java.lang.Boolean getBoldLabels()
public T setBoldLabels(java.lang.Boolean boldLabels)
boldLabels
- bold labels optionpublic java.lang.Integer getAutoRotateAngle()
public T setAutoRotateAngle(java.lang.Integer autoRotateAngle)
autoRotateAngle
- angle of label rotationpublic java.lang.Integer getAutoRotateCount()
public T setAutoRotateCount(java.lang.Integer autoRotateCount)
autoRotateCount
- auto rotate countpublic java.lang.Boolean getCenterLabels()
public T setCenterLabels(java.lang.Boolean centerLabels)
centerLabels
- center labels optionpublic java.util.List<DateFormat> getDateFormats()
public T setDateFormats(java.util.List<DateFormat> dateFormats)
[{"period":"fff", "format":"JJ:NN:SS"},
{"period":"ss", "format":"JJ:NN:SS"},
{"period":"mm", "format":"JJ:NN"},
{"period":"hh", "format":"JJ:NN"},
{"period":"DD", "format":"MMM DD"},
{"period":"WW", "format":"MMM DD"},
{"period":"MM", "format":"MMM"},
{"period":"YYYY", "format":"YYYY"}]
dateFormats
- list of date formatspublic T addDateFormats(DateFormat... dateFormats)
dateFormats
- date formatspublic java.lang.Integer getMinorTickLength()
public T setMinorTickLength(java.lang.Integer minorTickLength)
minorTickLength
- length of minor grid tickpublic java.lang.Integer getTitleRotation()
public T setTitleRotation(java.lang.Integer titleRotation)
titleRotation
- rotation of axis titlepublic Balloon getBalloon()
public T setBalloon(Balloon balloon)
balloon
- balloonpublic java.lang.Boolean getBoldPeriodBeginning()
public T setBoldPeriodBeginning(java.lang.Boolean boldPeriodBeginning)
boldPeriodBeginning
- boldPeriodBeginning optionpublic java.lang.Boolean getCenterLabelOnFullPeriod()
public T setCenterLabelOnFullPeriod(java.lang.Boolean centerLabelOnFullPeriod)
centerLabelOnFullPeriod
- centerLabelOnFullPeriod optionpublic DayOfWeek getFirstDayOfWeek()
public T setFirstDayOfWeek(DayOfWeek firstDayOfWeek)
firstDayOfWeek
- first day of the weekpublic java.lang.Integer getLabelOffset()
public T setLabelOffset(java.lang.Integer labelOffset)
CategoryAxis
and ValueAxis
. If not set the default
value is 0.labelOffset
- offset of axes labelspublic java.lang.Boolean getMarkPeriodChange()
public T setMarkPeriodChange(java.lang.Boolean markPeriodChange)
markPeriodChange
- markPeriodChange optionpublic java.lang.Boolean getCenterRotatedLabels()
public void setCenterRotatedLabels(java.lang.Boolean centerRotatedLabels)
centerRotatedLabels
- centerRotatedLabels option