Package ucar.unidata.idv.control
Class MapDisplayControl.LatLonLabelState
java.lang.Object
ucar.unidata.gis.maps.LatLonLabelData
ucar.unidata.idv.control.MapDisplayControl.LatLonLabelState
- Enclosing class:
MapDisplayControl
This class holds the state associated with a given lat/lon
-
Field Summary
Fields inherited from class ucar.unidata.gis.maps.LatLonLabelData
fastRendering, myLatLonLabels -
Constructor Summary
ConstructorsConstructorDescriptionParameterless ctorLatLonLabelState(boolean isLatitude, float spacing) The ctorCtor for creating from a LatLonData -
Method Summary
Modifier and TypeMethodDescriptionprotected voidApply the visibility to the myLatLonprotected booleanOverwrite the base class method to take into account the display's visibilityprotected voidinit(MapDisplayControl mapDisplayControl) Set the MapDisplayControlvoidinitWith(LatLonLabelData that) Copy the state from the given LatLonDatavoidsetAlignment(String value) Set the alignment pointvoidsetBaseValue(float value) Set the basevoidSet the colorvoidsetFastRendering(boolean value) Set the fast rendering flagvoidSet the fontvoidsetInterval(float value) Set the spacing of the linesvoidsetLabelFormat(String value) Set the label formatvoidsetLabelLines(float[] values) Set the label lines of the linesvoidsetSphere(boolean value) Set the sphere flagvoidsetUse360(boolean value) Set the use360 propertyvoidsetVisible(boolean value) Set the visibilityvoidCalled by the base class when one of the latlon values have changed.toString()to stringMethods inherited from class ucar.unidata.gis.maps.LatLonLabelData
formatLabelLines, getAlignment, getBaseValue, getColor, getFastRendering, getFont, getInterval, getIsLatitude, getLabelFormat, getLabelLines, getLatLonLabels, getMaxValue, getMinValue, getSphere, getUse360, getVisible, parseLabelLineString, setIsLatitude, setLabelsLineString, setMaxValue, setMinValue
-
Constructor Details
-
LatLonLabelState
public LatLonLabelState()Parameterless ctor -
LatLonLabelState
Ctor for creating from a LatLonData- Parameters:
that- The object to copy from
-
LatLonLabelState
public LatLonLabelState(boolean isLatitude, float spacing) The ctor- Parameters:
isLatitude- Is this latitude or longitudespacing- Line spacing
-
-
Method Details
-
init
Set the MapDisplayControl- Parameters:
mapDisplayControl- The display I am part of
-
initWith
Copy the state from the given LatLonData- Overrides:
initWithin classLatLonLabelData- Parameters:
that- The LatLonData to copy from
-
setColor
Set the color- Overrides:
setColorin classLatLonLabelData- Parameters:
value- the new Color
-
setVisible
public void setVisible(boolean value) Set the visibility- Overrides:
setVisiblein classLatLonLabelData- Parameters:
value- true to be visible
-
setFastRendering
public void setFastRendering(boolean value) Set the fast rendering flag- Overrides:
setFastRenderingin classLatLonLabelData- Parameters:
value- true to turn on fast rendering
-
setLabelLines
public void setLabelLines(float[] values) Set the label lines of the lines- Overrides:
setLabelLinesin classLatLonLabelData- Parameters:
values- the label lines
-
setInterval
public void setInterval(float value) Set the spacing of the lines- Overrides:
setIntervalin classLatLonLabelData- Parameters:
value- the line spacing
-
setBaseValue
public void setBaseValue(float value) Set the base- Overrides:
setBaseValuein classLatLonLabelData- Parameters:
value- the line width
-
setFont
Set the font- Overrides:
setFontin classLatLonLabelData- Parameters:
value- the label font
-
setAlignment
Set the alignment point- Overrides:
setAlignmentin classLatLonLabelData- Parameters:
value- the alignment point
-
setLabelFormat
Set the label format- Overrides:
setLabelFormatin classLatLonLabelData- Parameters:
value- the label format
-
setSphere
public void setSphere(boolean value) Set the sphere flag- Overrides:
setSpherein classLatLonLabelData- Parameters:
value- the sphere flag
-
setUse360
public void setUse360(boolean value) Set the use360 property- Overrides:
setUse360in classLatLonLabelData- Parameters:
value- true to use 0-360 for longitudes
-
checkVisibility
protected void checkVisibility()Apply the visibility to the myLatLon -
getRealVisibility
protected boolean getRealVisibility()Overwrite the base class method to take into account the display's visibility- Overrides:
getRealVisibilityin classLatLonLabelData- Returns:
- THe actual visibility to use
-
stateChanged
public void stateChanged()Called by the base class when one of the latlon values have changed.- Overrides:
stateChangedin classLatLonLabelData
-
toString
to string
-