Package ucar.nc2.ui.grid
Class ContourFeatureRenderer
- java.lang.Object
-
- ucar.nc2.ui.gis.GisFeatureRenderer
-
- ucar.nc2.ui.grid.ContourFeatureRenderer
-
- All Implemented Interfaces:
Renderer
public class ContourFeatureRenderer extends GisFeatureRenderer
Contour rendering.
-
-
Field Summary
-
Fields inherited from class ucar.nc2.ui.gis.GisFeatureRenderer
displayProject, shapeList
-
-
Constructor Summary
Constructors Constructor Description ContourFeatureRenderer(ContourGrid conGrid, ProjectionImpl dataProjection)
cstr
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
draw(Graphics2D g, AffineTransform deviceFromNormalAT)
Overrides the GisFeatureRenderer draw() method, to draw contours and with contour labels.protected ProjectionImpl
getDataProjection()
protected List
getFeatures()
LatLonRect
getPreferredArea()
Preferred map area on opening for first time.void
setShowLabels(boolean showlabels)
set switch whether contours labels are desired.-
Methods inherited from class ucar.nc2.ui.gis.GisFeatureRenderer
getColor, getShapes, setColor, setProjection
-
-
-
-
Constructor Detail
-
ContourFeatureRenderer
public ContourFeatureRenderer(ContourGrid conGrid, ProjectionImpl dataProjection)
cstr
-
-
Method Detail
-
setShowLabels
public void setShowLabels(boolean showlabels)
set switch whether contours labels are desired. default true is set in cstr.
-
getPreferredArea
@Nullable public LatLonRect getPreferredArea()
Description copied from class:GisFeatureRenderer
Preferred map area on opening for first time.- Specified by:
getPreferredArea
in interfaceRenderer
- Specified by:
getPreferredArea
in classGisFeatureRenderer
- Returns:
- lat/lon bounding box that specifies preferred area.
-
getFeatures
protected List getFeatures()
- Specified by:
getFeatures
in classGisFeatureRenderer
-
getDataProjection
protected ProjectionImpl getDataProjection()
- Specified by:
getDataProjection
in classGisFeatureRenderer
-
draw
public void draw(Graphics2D g, AffineTransform deviceFromNormalAT)
Overrides the GisFeatureRenderer draw() method, to draw contours and with contour labels.- Specified by:
draw
in interfaceRenderer
- Overrides:
draw
in classGisFeatureRenderer
- Parameters:
g
- the Graphics2D context on which to drawdeviceFromNormalAT
- transforms "Normalized Device" to Device coordinates
-
-