public abstract class TickLook extends Object
Modifier and Type | Field and Description |
---|---|
static TickLook |
CLASSIC
Old-style look - major tickmarks extend above and below axis.
|
static TickLook |
NONE
No ticks are drawn.
|
static TickLook |
STANDARD
Standard look - major tickmarks are twice as high as minor.
|
Modifier | Constructor and Description |
---|---|
protected |
TickLook(String name)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
static TickLook |
createClassicLook(String name,
int unit)
Returns a look with major ticks extending both below and above
the axis, minor ticks only above.
|
static TickLook |
createStandardLook(String name,
int unit)
Returns a look with major ticks twice as long as minor ones,
all ticks only extending above the axis.
|
abstract void |
drawMajor(Graphics2D g2)
Draws a major tickmark at the origin, with the axis considered
horizontal and the plot in the direction of the positive Y axis.
|
abstract void |
drawMinor(Graphics2D g2)
Draws a minor tickmark at the origin, with the axis considered
horizontal and the plot in the direction of the positive Y axis.
|
String |
getName()
Returns the name of this style.
|
String |
toString() |
public static final TickLook CLASSIC
public static final TickLook STANDARD
public static final TickLook NONE
protected TickLook(String name)
name
- style namepublic abstract void drawMinor(Graphics2D g2)
g2
- graphics contextpublic abstract void drawMajor(Graphics2D g2)
g2
- graphics contextpublic String getName()
public static TickLook createClassicLook(String name, int unit)
name
- style nameunit
- length in pixels of minor ticksCopyright © 2024 Central Laboratory of the Research Councils. All Rights Reserved.