public class YAxisLabels extends Labels<YAxisLabels>
YAxis.setLabels(org.moxieapps.gwt.highcharts.client.labels.YAxisLabels)
method. Example usage:
chart.getYAxis().setLabels(
new YAxisLabels()
.setAlign(Labels.Align.LEFT)
.setColor("#CC0000")
);
Labels.Align, Labels.VerticalAlign| Constructor and Description |
|---|
YAxisLabels() |
| Modifier and Type | Method and Description |
|---|---|
AxisLabelsFormatter |
getFormatter()
Returns the custom axis labels formatter that has been applied to the y-axis, or null if the
built-in generic formatter is being used instead.
|
YAxisLabels |
setFormatter(AxisLabelsFormatter axisLabelsFormatter)
Sets a custom formatter for the labels on the axis that can be used to control how the text of the
labels will be displayed.
|
YAxisLabels |
setStep(Number step)
Convenience method for setting the 'step' option for the labels.
|
setAlign, setColor, setEnabled, setRotation, setStyle, setVerticalAlign, setX, setYgetOptions, setOptionpublic YAxisLabels setFormatter(AxisLabelsFormatter axisLabelsFormatter)
AxisLabelsFormatter interface, and
in particular the AxisLabelsFormatter.format(AxisLabelsData) method for more details on
the capabilities available to custom formatters.axisLabelsFormatter - The custom formatter to use for the labels (if not given a built-in
generic formatter is used which simply returns the value as a string).YAxisLabels instance for convenient method chaining.public AxisLabelsFormatter getFormatter()
public YAxisLabels setStep(Number step)
yAxisLabels.setOption("step", 2);
To show only every n'th label on the axis, set the step to n. E.g. - setting the step to
2 shows every other label. Defaults to null.step - o show only every n'th label on the axis, set the step to n.YAxisLabels instance for convenient method chaining.Copyright © 2015. All Rights Reserved.