Class ChartTicks

java.lang.Object
net.sourceforge.plantuml.chart.ChartTicks

public final class ChartTicks extends Object
The ticks of the axes of a chart, and how their values are written. They depend only on the axes, not on the way the chart is drawn: the graphic renderers and the text one place their ticks at the same values, with the same labels.
  • Method Details

    • valueTicks

      public static List<ChartTicks.Tick> valueTicks(ChartAxis axis)
      The ticks of a vertical value axis (and of the radial scale of a radar): custom ticks if defined, else ticks every "spacing", else five automatic intervals.
    • horizontalValueTicks

      public static List<ChartTicks.Tick> horizontalValueTicks(ChartAxis axis)
    • numericTicks

      public static List<ChartTicks.Tick> numericTicks(ChartAxis axis, Integer spacing)
      The ticks of a numeric h-axis (coordinate pairs, or an h-axis range): one every "spacing" when given, else about ten, starting at a multiple of the interval. They are placed by their value, as the points of the series.
    • formatValue

      public static String formatValue(double value)
      A value on a value axis, or on a point label: 0.80 is written 0.8, as the automatic range gives ticks like 0, 0.8, 1.6 ...