|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.deegree.graphics.DefaultScaleBar
public class DefaultScaleBar
Field Summary |
---|
Fields inherited from interface org.deegree.graphics.ScaleBar |
---|
L_NONE, L_SCALE, L_SCALEDENOMINATOR |
Constructor Summary | |
---|---|
DefaultScaleBar()
Constructor just using defaults |
|
DefaultScaleBar(int topLabel,
int bottomLabel,
double scale,
double scaleDenominator,
java.lang.String units,
java.awt.Color labelColor,
java.awt.Color barColor,
java.awt.Color allgColor,
java.lang.String barStyle,
java.awt.Font barFont,
java.text.NumberFormat numberFormat)
Constructor with all Parameters |
Method Summary | |
---|---|
void |
paint(java.awt.Graphics g)
will paint the scale bar to the passed graphic context |
void |
setBackgroundColor(java.awt.Color color)
sets the background color of the scale bar |
void |
setBarColor(java.awt.Color color)
sets the bar color of the scale bar |
void |
setBottomLabel(int labelType)
sets the type of the label below the scale bar |
void |
setColor(java.awt.Color color)
sets the front color of the scale bar |
void |
setFont(java.awt.Font font)
sets the font for label rendering |
void |
setLabelColor(java.awt.Color color)
sets the label color of the scale bar |
void |
setNumberFormat(java.text.NumberFormat numberFormat)
sets the number format for a scale bar |
void |
setScale(double scale)
sets the scale as defined in the OGC WMS 1.1.1 specification. |
void |
setScaleDenominator(double scaleDen)
sets the scale denominator for the scale bar. |
void |
setStyle(java.lang.String style)
sets the style of the scale bar. default style is |--------| the list of known styles depends on the implementation |
void |
setTopLabel(int labelType)
sets the type of the label above the scale bar |
void |
setUnits(java.lang.String units)
sets the units the scale and the scale denominater will be expressed at. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultScaleBar(int topLabel, int bottomLabel, double scale, double scaleDenominator, java.lang.String units, java.awt.Color labelColor, java.awt.Color barColor, java.awt.Color allgColor, java.lang.String barStyle, java.awt.Font barFont, java.text.NumberFormat numberFormat)
topLabel
- type of the label on top of the scale bar. Chose L_NONE or no label, L_SCALE for
scale on top and L_SCALEDENOMIATOR for scaledenominator on top.bottomLabel
- the same as above but below the scalebar.scale
- the scale to be displayed. For a value of e.g. 1000 there will be 1:1000 displayedscaleDenominator
- the scaledenominator to be displayedunits
- the units the scaledenominator is in. Possible values are inch, Meter, Mile,
Kilometer...labelColor
- the Color the label has to be in (and of course the text below and above)barColor
- allgColor
- not used so farbarStyle
- the style the bar appears in. Currently just "default" is supported.barFont
- the font the text above and below the scale bar appears in.numberFormat
- public DefaultScaleBar()
Method Detail |
---|
public void paint(java.awt.Graphics g)
paint
in interface ScaleBar
g
- graphic contextpublic void setTopLabel(int labelType)
setTopLabel
in interface ScaleBar
labelType
- lable typepublic void setBottomLabel(int labelType)
setBottomLabel
in interface ScaleBar
labelType
- lable typepublic void setScale(double scale)
setScale
in interface ScaleBar
scale
- map scalepublic void setScaleDenominator(double scaleDen)
setScaleDenominator
in interface ScaleBar
scaleDen
- scale denominator valuepublic void setUnits(java.lang.String units)
setUnits
in interface ScaleBar
units
- name units (meter, miles, feet etc.)public void setColor(java.awt.Color color)
color
- public void setLabelColor(java.awt.Color color)
setLabelColor
in interface ScaleBar
color
- public void setBarColor(java.awt.Color color)
setBarColor
in interface ScaleBar
color
- public void setStyle(java.lang.String style)
setStyle
in interface ScaleBar
style
- style namepublic void setFont(java.awt.Font font)
setFont
in interface ScaleBar
font
- awt font objectpublic void setBackgroundColor(java.awt.Color color)
ScaleBar
setBackgroundColor
in interface ScaleBar
public void setNumberFormat(java.text.NumberFormat numberFormat)
setNumberFormat
in interface ScaleBar
numberFormat
-
|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org