Class HdrAxisLabelHandler
- java.lang.Object
-
- com.metsci.glimpse.core.axis.painter.label.GridAxisLabelHandler
-
- com.metsci.glimpse.core.axis.painter.label.HdrAxisLabelHandler
-
- All Implemented Interfaces:
AxisLabelHandler
public class HdrAxisLabelHandler extends GridAxisLabelHandler
High dynamic range axis label handler. The tick labels are always a fixed width (modulo the negative sign) so zooming will never obfuscate the values.- Author:
- borkholder
-
-
Constructor Summary
Constructors Constructor Description HdrAxisLabelHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getAxisLabel(Axis1D axis)
String[]
getTickLabels(Axis1D axis, double[] tickPositions)
void
setAxisLabel(String label)
void
setAxisUnits(String milliUnits, String units, String kiloUnits)
-
Methods inherited from class com.metsci.glimpse.core.axis.painter.label.GridAxisLabelHandler
getAxisLabel, getAxisUnitConverter, getAxisUnits, getMinorTickPositions, getTickPositions, setAxisUnitConverter, setAxisUnits, setMinorTickCount, setTickSpacing
-
-
-
-
Method Detail
-
setAxisLabel
public void setAxisLabel(String label)
- Specified by:
setAxisLabel
in interfaceAxisLabelHandler
- Overrides:
setAxisLabel
in classGridAxisLabelHandler
- Parameters:
label
- provides a hint regarding what label information to display
-
setAxisUnits
public void setAxisUnits(String milliUnits, String units, String kiloUnits)
- Overrides:
setAxisUnits
in classGridAxisLabelHandler
-
getAxisLabel
public String getAxisLabel(Axis1D axis)
- Specified by:
getAxisLabel
in interfaceAxisLabelHandler
- Overrides:
getAxisLabel
in classGridAxisLabelHandler
- Returns:
- a text label describing the axis (the type of data displayed, the units, etc...)
-
getTickLabels
public String[] getTickLabels(Axis1D axis, double[] tickPositions)
- Specified by:
getTickLabels
in interfaceAxisLabelHandler
- Overrides:
getTickLabels
in classGridAxisLabelHandler
tickPositions
- the output from getTickPositions( ).- Returns:
- an array of string labels for the tick marks provided by getTickPositions( ).
-
-