|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.cosylab.gui.components.range2.ManualTickCalculator
public class ManualTickCalculator
ManualTickCalculator
calculates ticks explicitely. Ticks are calculated
according to the supplied parameters which define at which values major and minor
ticks should be.
Constructor Summary | |
---|---|
ManualTickCalculator()
Constructs a new ManualTickProvider with null value. |
|
ManualTickCalculator(double[] majorTicks,
double[] labels,
double minor)
Constructs a new ManualTickProvider with the given parameters. |
Method Summary | |
---|---|
Tick[] |
calculateTicks(int length,
Range range,
RangedValue rangedValue)
Calculates ticks using some default TickParameters. |
Tick[] |
calculateTicks(int spaceLength,
TickParameters measurer,
Range range,
RangedValue rangedValue)
Calculates ticks using the given TickParameters. |
double[] |
getLabels()
Returns the values which have labels printed next to the ticks. |
double[] |
getMajorTicks()
Returns the values which have major ticks. |
double |
getMinor()
Returns the number of minor ticks between two major ticks. |
static void |
main(java.lang.String[] args)
|
void |
setLabels(double[] labels)
Sets the values that will have labels printed next to ticks. |
void |
setMajorTicks(double[] majorTicks)
Sets the values which will have major ticks. |
void |
setMinor(double minor)
Sets the number of minor ticks between two major ticks. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ManualTickCalculator()
public ManualTickCalculator(double[] majorTicks, double[] labels, double minor)
majorTicks
- values that major ticks will be created forlabels
- values that will have labels (only major ticks can have labels).minor
- number of minor ticks between two major ticksMethod Detail |
---|
public void setLabels(double[] labels)
labels
- public void setMajorTicks(double[] majorTicks)
majorTicks
- public void setMinor(double minor)
minor
- public double[] getLabels()
public double[] getMajorTicks()
public double getMinor()
public Tick[] calculateTicks(int length, Range range, RangedValue rangedValue)
TickCalculator
calculateTicks
in interface TickCalculator
length
- the available space for ticks in the displayerrange
- range which provides transformation to absolute/relative valuesrangedValue
- the value bounds
public Tick[] calculateTicks(int spaceLength, TickParameters measurer, Range range, RangedValue rangedValue)
TickCalculator
calculateTicks
in interface TickCalculator
spaceLength
- the available space for ticks in the displayermeasurer
- TickParameters used to measure ticksrange
- range which provides transformation to absolute/relative valuesrangedValue
- the value bounds
public static void main(java.lang.String[] args)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |