|
SGT Home | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Object | +--gov.noaa.pmel.sgt.Ruler
Description of Class Ruler
| Field Summary | |
static int |
BOTH_SIDES
Draw the tics on both sides of the axes. |
static int |
HORIZONTAL
Orient Key horizontally. |
static int |
NEGATIVE_SIDE
Place the label and/or tic on the negative side of the axis. |
static int |
NO_LABEL
Do not draw a label and/or tic. |
static int |
POSITIVE_SIDE
Place the label and/or tic on the positive side of the axis. |
static int |
VERTICAL
Orient Key vertically. |
| Constructor Summary | |
Ruler()
Default constructor for Ruler. |
|
Ruler(java.lang.String ident)
Constructor for Ruler. |
|
| Method Summary | |
LayerChild |
copy()
Create a copy of the LayerChild. |
void |
draw(java.awt.Graphics g)
Draw the LayerChild. |
java.awt.Rectangle |
getBounds()
Get the bounding box for the axis in device units. |
Rectangle2D.Double |
getBoundsP()
Get the bounding box for the axis in physical units. |
java.lang.String |
getId()
Set the axis identifier. |
java.awt.Color |
getLabelColor()
|
java.awt.Font |
getLabelFont()
Get the label font. |
java.lang.String |
getLabelFormat()
|
double |
getLabelHeightP()
Get the label height. |
int |
getLabelInterval()
|
int |
getLabelPosition()
Get the label position. |
double |
getLargeTicHeightP()
Get the large tic height. |
Layer |
getLayer()
Get the associated Layer. |
java.awt.Color |
getLineColor()
|
int |
getNumberSmallTics()
Get the number of small tics between large tics. |
int |
getOrientation()
Get axis orientation |
AbstractPane |
getPane()
Get AbstractPane of the LayerChild. |
Range2D |
getRangeU()
|
int |
getSignificantDigits()
|
double |
getSmallTicHeightP()
Get the small tic height. |
int |
getTicPosition()
Get the tic position. |
SGLabel |
getTitle()
Get the axis title. |
boolean |
isSelectable()
Returns true if the current state is selectable. |
boolean |
isSelected()
Returns true if the object's selected property is set. |
boolean |
isVisible()
Check if LayerChild is visible. |
void |
modified(java.lang.String mess)
Used by sgt internally. |
void |
setBounds(int x,
int y,
int width,
int height)
|
void |
setBounds(java.awt.Rectangle r)
|
void |
setBoundsP(Rectangle2D.Double bounds)
Set the bounding box for the axis in physical units. |
void |
setId(java.lang.String id)
Set the axis identifier. |
void |
setLabelColor(java.awt.Color labelColor)
|
void |
setLabelFont(java.awt.Font fnt)
Set the label font. |
void |
setLabelFormat(java.lang.String labelFormat)
|
void |
setLabelHeightP(double lhgt)
Set the label height in physical units. |
void |
setLabelInterval(int labelInterval)
|
void |
setLabelPosition(int labp)
Set the label position. |
void |
setLargeTicHeightP(double lthgt)
Set the large tic height in physical units. |
void |
setLayer(Layer l)
Associate a Layer with the LayerChild. |
void |
setLineColor(java.awt.Color lineColor)
|
void |
setNumberSmallTics(int nstic)
Set the number of small tics between large tics. |
void |
setOrientation(int orient)
Set ruler orientation. |
void |
setRangeU(Range2D range)
Change the user unit range of Ruler |
void |
setSelectable(boolean select)
Set the Selectable property. |
void |
setSelected(boolean sel)
Sets the selected property. |
void |
setSignificantDigits(int sigDigits)
|
void |
setSmallTicHeightP(double sthgt)
Set the small tic height in physical units. |
void |
setTicPosition(int tpos)
Set the tic position. |
void |
setTitle(SGLabel title)
Set the axis title. |
void |
setVisible(boolean visible)
Set visibility for a LayerChild. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface gov.noaa.pmel.sgt.LayerChild |
toString |
| Field Detail |
public static final int HORIZONTAL
public static final int VERTICAL
public static final int POSITIVE_SIDE
public static final int NEGATIVE_SIDE
public static final int NO_LABEL
public static final int BOTH_SIDES
| Constructor Detail |
public Ruler()
public Ruler(java.lang.String ident)
numberSmallTics = 0
largeTicHeightP = 0.1
smallTicHeightP = 0.05
ticPosition = NEGATIVE_SIDE
labelPosition = NEGATIVE_SIDE
labelInterval = 2
labelFont = Font("Helvetica", Font.ITALIC, 10);
labelHeightP = 0.15
significantDigits = 2;
labelFormat = ""
title = null
orientation = HORIZONTAL
Id = ""
| Method Detail |
public LayerChild copy()
LayerChildLayerChild.
copy in interface LayerChildLayerChild.public void setSelected(boolean sel)
Selectable
setSelected in interface Selectablesel - true if selected, false if not.public boolean isSelected()
Selectable
isSelected in interface Selectablepublic void setSelectable(boolean select)
Selectable
setSelectable in interface Selectableselect - if true object is selectablepublic boolean isSelectable()
Selectable
isSelectable in interface Selectablepublic void setLargeTicHeightP(double lthgt)
lthgt - large tic height.public double getLargeTicHeightP()
public void setNumberSmallTics(int nstic)
nstic - number of small tics.public int getNumberSmallTics()
public void setSmallTicHeightP(double sthgt)
sthgt - small tic height.public double getSmallTicHeightP()
public void setTicPosition(int tpos)
tpos - tic positionpublic int getTicPosition()
public void setLabelPosition(int labp)
public int getLabelPosition()
public void setLabelFont(java.awt.Font fnt)
fnt - label fontpublic java.awt.Font getLabelFont()
public void setLabelHeightP(double lhgt)
lhgt - label height.public double getLabelHeightP()
public void setId(java.lang.String id)
setId in interface LayerChildid - identifierpublic java.lang.String getId()
getId in interface LayerChildLayerChild identification.public void setLayer(Layer l)
LayerChildLayer with the LayerChild.
setLayer in interface LayerChildl - Parent layer.public Layer getLayer()
LayerChildLayer.
getLayer in interface LayerChildpublic AbstractPane getPane()
LayerChildAbstractPane of the LayerChild.
getPane in interface LayerChildpublic void modified(java.lang.String mess)
LayerChild
modified in interface LayerChildpublic void setRangeU(Range2D range)
Ruler
public Range2D getRangeU()
public void setBoundsP(Rectangle2D.Double bounds)
public Rectangle2D.Double getBoundsP()
public void setOrientation(int orient)
public int getOrientation()
public void setTitle(SGLabel title)
title - axis titlepublic SGLabel getTitle()
public java.awt.Rectangle getBounds()
getBounds in interface Selectablepublic void setBounds(java.awt.Rectangle r)
public void setBounds(int x,
int y,
int width,
int height)
public void draw(java.awt.Graphics g)
LayerChildLayerChild.
draw in interface LayerChildg - Graphics contextpublic boolean isVisible()
LayerChildLayerChild is visible.
isVisible in interface LayerChildpublic void setVisible(boolean visible)
LayerChildLayerChild.
setVisible in interface LayerChildvisible - visible if truepublic int getLabelInterval()
public void setLabelInterval(int labelInterval)
public int getSignificantDigits()
public void setSignificantDigits(int sigDigits)
public java.lang.String getLabelFormat()
public void setLabelFormat(java.lang.String labelFormat)
public java.awt.Color getLabelColor()
public void setLabelColor(java.awt.Color labelColor)
public java.awt.Color getLineColor()
public void setLineColor(java.awt.Color lineColor)
|
SGT Home | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||