Class WWOMeasureDisplay
- java.lang.Object
-
- gov.nasa.worldwindx.applications.worldwindow.util.measuretool.WWOMeasureDisplay
-
- All Implemented Interfaces:
WWOMeasureTool.MeasureDisplay
public class WWOMeasureDisplay extends java.lang.Object implements WWOMeasureTool.MeasureDisplay
-
-
Field Summary
Fields Modifier and Type Field Description protected ScreenAnnotationannotationprotected AnnotationAttributesannotationAttributesprotected AVListImplavListprotected WWOMeasureToolmeasureToolprotected UnitsFormatunitsFormat-
Fields inherited from interface gov.nasa.worldwindx.applications.worldwindow.util.measuretool.WWOMeasureTool.MeasureDisplay
ACCUMULATED_LABEL, ANGLE_LABEL, AREA_LABEL, CENTER_LATITUDE_LABEL, CENTER_LONGITUDE_LABEL, HEADING_LABEL, HEIGHT_LABEL, LATITUDE_LABEL, LENGTH_LABEL, LONGITUDE_LABEL, MAJOR_AXIS_LABEL, MINOR_AXIS_LABEL, PERIMETER_LABEL, RADIUS_LABEL, WIDTH_LABEL
-
-
Constructor Summary
Constructors Constructor Description WWOMeasureDisplay(WWOMeasureTool measureTool)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddToLayer(RenderableLayer layer)protected booleanareLocationsRedundant(LatLon locA, LatLon locB, UnitsFormat units)protected java.lang.DoublecomputeAccumulatedLength(LatLon pos, WWOMeasureTool mt)protected AnglecomputeAngleBetween(LatLon a, LatLon b, LatLon c)protected Vec4computeAnnotationPosition(Position pos, WWOMeasureTool mt)protected doublecomputePathLength(WWOMeasureTool mt)protected java.lang.StringformatCircleMeasurements(Position pos, WWOMeasureTool mt)protected voidformatControlPoints(Position pos, WWOMeasureTool mt, java.lang.StringBuilder sb)protected java.lang.StringformatEllipseMeasurements(Position pos, WWOMeasureTool mt)protected java.lang.StringformatLineMeasurements(Position pos, WWOMeasureTool mt)protected java.lang.StringformatPolygonMeasurements(Position pos, WWOMeasureTool mt)protected java.lang.StringformatQuadMeasurements(Position pos, WWOMeasureTool mt)protected java.lang.StringformatSquareMeasurements(Position pos, WWOMeasureTool mt)protected java.lang.StringgetDisplayString(Position pos, WWOMeasureTool mt)java.lang.StringgetLabel(java.lang.String labelName)booleanisAnnotation(java.lang.Object o)protected booleanlengthsEssentiallyEqual(double l1, double l2)voidremoveFromLayer(RenderableLayer layer)protected voidsetInitialLabels()voidsetLabel(java.lang.String labelName, java.lang.String label)voidupdateMeasureDisplay(Position position)
-
-
-
Field Detail
-
measureTool
protected WWOMeasureTool measureTool
-
annotation
protected ScreenAnnotation annotation
-
annotationAttributes
protected AnnotationAttributes annotationAttributes
-
avList
protected AVListImpl avList
-
unitsFormat
protected UnitsFormat unitsFormat
-
-
Constructor Detail
-
WWOMeasureDisplay
public WWOMeasureDisplay(WWOMeasureTool measureTool)
-
-
Method Detail
-
setInitialLabels
protected void setInitialLabels()
-
addToLayer
public void addToLayer(RenderableLayer layer)
- Specified by:
addToLayerin interfaceWWOMeasureTool.MeasureDisplay
-
removeFromLayer
public void removeFromLayer(RenderableLayer layer)
- Specified by:
removeFromLayerin interfaceWWOMeasureTool.MeasureDisplay
-
setLabel
public void setLabel(java.lang.String labelName, java.lang.String label)- Specified by:
setLabelin interfaceWWOMeasureTool.MeasureDisplay
-
getLabel
public java.lang.String getLabel(java.lang.String labelName)
- Specified by:
getLabelin interfaceWWOMeasureTool.MeasureDisplay
-
isAnnotation
public boolean isAnnotation(java.lang.Object o)
- Specified by:
isAnnotationin interfaceWWOMeasureTool.MeasureDisplay
-
updateMeasureDisplay
public void updateMeasureDisplay(Position position)
- Specified by:
updateMeasureDisplayin interfaceWWOMeasureTool.MeasureDisplay
-
getDisplayString
protected java.lang.String getDisplayString(Position pos, WWOMeasureTool mt)
-
computeAnnotationPosition
protected Vec4 computeAnnotationPosition(Position pos, WWOMeasureTool mt)
-
formatCircleMeasurements
protected java.lang.String formatCircleMeasurements(Position pos, WWOMeasureTool mt)
-
formatEllipseMeasurements
protected java.lang.String formatEllipseMeasurements(Position pos, WWOMeasureTool mt)
-
formatSquareMeasurements
protected java.lang.String formatSquareMeasurements(Position pos, WWOMeasureTool mt)
-
formatQuadMeasurements
protected java.lang.String formatQuadMeasurements(Position pos, WWOMeasureTool mt)
-
formatPolygonMeasurements
protected java.lang.String formatPolygonMeasurements(Position pos, WWOMeasureTool mt)
-
formatLineMeasurements
protected java.lang.String formatLineMeasurements(Position pos, WWOMeasureTool mt)
-
formatControlPoints
protected void formatControlPoints(Position pos, WWOMeasureTool mt, java.lang.StringBuilder sb)
-
computeAccumulatedLength
protected java.lang.Double computeAccumulatedLength(LatLon pos, WWOMeasureTool mt)
-
computePathLength
protected double computePathLength(WWOMeasureTool mt)
-
lengthsEssentiallyEqual
protected boolean lengthsEssentiallyEqual(double l1, double l2)
-
areLocationsRedundant
protected boolean areLocationsRedundant(LatLon locA, LatLon locB, UnitsFormat units)
-
-