Class AbstractSelectionRenderer
- java.lang.Object
-
- org.locationtech.jts.jump.workbench.ui.renderer.FeatureCollectionRenderer
-
- org.locationtech.jts.jump.workbench.ui.renderer.AbstractSelectionRenderer
-
- Direct Known Subclasses:
FeatureSelectionRenderer
,LineStringSelectionRenderer
,PartSelectionRenderer
,SelectionBackgroundRenderer
public abstract class AbstractSelectionRenderer extends FeatureCollectionRenderer implements Style
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.locationtech.jts.jump.workbench.ui.renderer.Renderer
Renderer.Factory
-
-
Field Summary
Fields Modifier and Type Field Description static int
HANDLE_WIDTH
protected LayerViewPanel
panel
-
Constructor Summary
Constructors Constructor Description AbstractSelectionRenderer(Object contentID, LayerViewPanel panel, Color color, boolean paintingHandles, boolean filling)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Object
clone()
protected abstract CollectionMap
featureToSelectedItemsMap(Layer layer)
Icon
getIcon()
String
getName()
void
initialize(Layer layer)
Called before #paint is applied to each Feature.boolean
isEnabled()
protected Map
layerToFeaturesMap()
void
paint(org.locationtech.jts.geom.Geometry geometry, Graphics2D g, Viewport viewport)
void
paint(Feature f, Graphics2D g, Viewport viewport)
static void
paintHandles(Graphics2D g, org.locationtech.jts.geom.Coordinate[] coordinates, Stroke stroke, Color fillColor, Color lineColor, Viewport viewport)
void
setEnabled(boolean enabled)
protected Collection
styles()
-
Methods inherited from class org.locationtech.jts.jump.workbench.ui.renderer.FeatureCollectionRenderer
cancel, clearImageCache, copyTo, createRunnable, getContentID, isRendering
-
-
-
-
Field Detail
-
HANDLE_WIDTH
public static final int HANDLE_WIDTH
- See Also:
- Constant Field Values
-
panel
protected LayerViewPanel panel
-
-
Constructor Detail
-
AbstractSelectionRenderer
public AbstractSelectionRenderer(Object contentID, LayerViewPanel panel, Color color, boolean paintingHandles, boolean filling)
-
-
Method Detail
-
getName
public String getName()
-
getIcon
public Icon getIcon()
-
setEnabled
public void setEnabled(boolean enabled)
- Specified by:
setEnabled
in interfaceStyle
-
initialize
public void initialize(Layer layer)
Description copied from interface:Style
Called before #paint is applied to each Feature.- Specified by:
initialize
in interfaceStyle
-
paint
public void paint(Feature f, Graphics2D g, Viewport viewport) throws NoninvertibleTransformException
- Specified by:
paint
in interfaceStyle
- Throws:
NoninvertibleTransformException
-
paint
public void paint(org.locationtech.jts.geom.Geometry geometry, Graphics2D g, Viewport viewport) throws NoninvertibleTransformException
- Throws:
NoninvertibleTransformException
-
styles
protected Collection styles()
- Specified by:
styles
in classFeatureCollectionRenderer
-
layerToFeaturesMap
protected Map layerToFeaturesMap()
- Specified by:
layerToFeaturesMap
in classFeatureCollectionRenderer
-
featureToSelectedItemsMap
protected abstract CollectionMap featureToSelectedItemsMap(Layer layer)
-
paintHandles
public static void paintHandles(Graphics2D g, org.locationtech.jts.geom.Coordinate[] coordinates, Stroke stroke, Color fillColor, Color lineColor, Viewport viewport) throws NoninvertibleTransformException
- Throws:
NoninvertibleTransformException
-
-