|
SGT Home | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | 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.Font |
getLabelFont()
Get the label font. |
double |
getLabelHeightP()
Get the label height. |
int |
getLabelPosition()
Get the label position. |
double |
getLargeTicHeightP()
Get the large tic height. |
Layer |
getLayer()
Get the associated Layer . |
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()
|
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 |
setLabelFont(java.awt.Font fnt)
Set the label font. |
void |
setLabelHeightP(double lhgt)
Set the label height in physical units. |
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 |
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 |
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 = ""
id
- axis identificationMethod Detail |
public LayerChild copy()
LayerChild
LayerChild
.copy
in interface LayerChild
gov.noaa.pmel.sgt.LayerChild
LayerChild
.public void setSelected(boolean sel)
Selectable
setSelected
in interface Selectable
gov.noaa.pmel.sgt.Selectable
sel
- true if selected, false if not.public boolean isSelected()
Selectable
isSelected
in interface Selectable
gov.noaa.pmel.sgt.Selectable
public void setSelectable(boolean select)
Selectable
setSelectable
in interface Selectable
gov.noaa.pmel.sgt.Selectable
select
- if true object is selectablepublic boolean isSelectable()
Selectable
isSelectable
in interface Selectable
gov.noaa.pmel.sgt.Selectable
public 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)
lapb
- label position.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 LayerChild
id
- identifierpublic java.lang.String getId()
getId
in interface LayerChild
id
- identifierpublic void setLayer(Layer l)
LayerChild
Layer
with the LayerChild
.setLayer
in interface LayerChild
gov.noaa.pmel.sgt.LayerChild
l
- Parent layer.public Layer getLayer()
LayerChild
Layer
.getLayer
in interface LayerChild
gov.noaa.pmel.sgt.LayerChild
public AbstractPane getPane()
LayerChild
AbstractPane
of the LayerChild
.getPane
in interface LayerChild
public void modified(java.lang.String mess)
LayerChild
modified
in interface LayerChild
public void setRangeU(Range2D range)
Ruler
public Range2D getRangeU()
public void setBoundsP(Rectangle2D.Double bounds)
public Rectangle2D.Double getBoundsP()
public void setOrientation(int orient)
or
- orientationpublic int getOrientation()
public void setTitle(SGLabel title)
title
- axis titlepublic SGLabel getTitle()
public java.awt.Rectangle getBounds()
getBounds
in interface Selectable
public void setBounds(java.awt.Rectangle r)
public void setBounds(int x, int y, int width, int height)
public void draw(java.awt.Graphics g)
LayerChild
LayerChild
.draw
in interface LayerChild
gov.noaa.pmel.sgt.LayerChild
g
- Graphics contextLayerNotFoundException
- No layer is associated with the LayerChild
.public boolean isVisible()
LayerChild
LayerChild
is visible.isVisible
in interface LayerChild
gov.noaa.pmel.sgt.LayerChild
public void setVisible(boolean visible)
LayerChild
LayerChild
.setVisible
in interface LayerChild
gov.noaa.pmel.sgt.LayerChild
visible
- visible if true
|
SGT Home | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |