Humboldt Alignment Editor 2.5.0

eu.esdihumboldt.hale.ui.views.styledmap.painter
Class StyledInstanceMarker

java.lang.Object
  extended by de.fhg.igd.mapviewer.marker.AbstractMarker<T>
      extended by de.fhg.igd.mapviewer.marker.BoundingBoxMarker<InstanceWaypoint>
          extended by eu.esdihumboldt.hale.ui.views.styledmap.painter.InstanceMarker
              extended by eu.esdihumboldt.hale.ui.views.styledmap.painter.StyledInstanceMarker
All Implemented Interfaces:
de.fhg.igd.mapviewer.marker.Marker<InstanceWaypoint>

public class StyledInstanceMarker
extends InstanceMarker

Instance marker support styles provided through the StyleService.

Author:
Simon Templer

Constructor Summary
StyledInstanceMarker(InstanceWaypoint wp)
          Create a instance marker supporting styles.
 
Method Summary
protected  boolean applyFill(Graphics2D g, InstanceWaypoint context)
           
protected  boolean applyStroke(Graphics2D g, InstanceWaypoint context)
           
protected  Color getBorderColor(InstanceWaypoint context)
           
protected  Stroke getLineStroke(InstanceWaypoint context)
          Get the stroke for drawing lines.
protected  Color getPaintColor(InstanceWaypoint context)
           
protected  boolean isToSmall(int width, int height, int zoom)
           
protected  de.fhg.igd.mapviewer.marker.area.Area paintPoint(com.vividsolutions.jts.geom.Point geometry, Graphics2D g, CRSDefinition crsDefinition, InstanceWaypoint context, org.jdesktop.swingx.mapviewer.PixelConverter converter, int zoom, org.opengis.referencing.crs.CoordinateReferenceSystem mapCRS, boolean calculateArea)
          Paint a point geometry.
 void resetStyle()
          Reset the marker style
 
Methods inherited from class eu.esdihumboldt.hale.ui.views.styledmap.painter.InstanceMarker
areaReset, doPaintMarker, getFallbackMarker, paintGeometry, paintLine, paintPolygon, reset
 
Methods inherited from class de.fhg.igd.mapviewer.marker.BoundingBoxMarker
paintFallback, paintMarker
 
Methods inherited from class de.fhg.igd.mapviewer.marker.AbstractMarker
getArea, paint
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StyledInstanceMarker

public StyledInstanceMarker(InstanceWaypoint wp)
Create a instance marker supporting styles.

Parameters:
wp - the way-point the marker is associated with
Method Detail

resetStyle

public void resetStyle()
Reset the marker style


getPaintColor

protected Color getPaintColor(InstanceWaypoint context)
Overrides:
getPaintColor in class InstanceMarker
See Also:
InstanceMarker.getPaintColor(InstanceWaypoint)

getBorderColor

protected Color getBorderColor(InstanceWaypoint context)
Overrides:
getBorderColor in class InstanceMarker
See Also:
InstanceMarker.getBorderColor(InstanceWaypoint)

getLineStroke

protected Stroke getLineStroke(InstanceWaypoint context)
Get the stroke for drawing lines.

Overrides:
getLineStroke in class InstanceMarker
Parameters:
context - the context
Returns:
the stroke

applyFill

protected boolean applyFill(Graphics2D g,
                            InstanceWaypoint context)
Overrides:
applyFill in class de.fhg.igd.mapviewer.marker.BoundingBoxMarker<InstanceWaypoint>
See Also:
BoundingBoxMarker.applyFill(Graphics2D, SelectableWaypoint)

applyStroke

protected boolean applyStroke(Graphics2D g,
                              InstanceWaypoint context)
Overrides:
applyStroke in class InstanceMarker
See Also:
BoundingBoxMarker.applyStroke(Graphics2D, SelectableWaypoint)

isToSmall

protected boolean isToSmall(int width,
                            int height,
                            int zoom)
Overrides:
isToSmall in class de.fhg.igd.mapviewer.marker.BoundingBoxMarker<InstanceWaypoint>
See Also:
BoundingBoxMarker.isToSmall(int, int, int)

paintPoint

protected de.fhg.igd.mapviewer.marker.area.Area paintPoint(com.vividsolutions.jts.geom.Point geometry,
                                                           Graphics2D g,
                                                           CRSDefinition crsDefinition,
                                                           InstanceWaypoint context,
                                                           org.jdesktop.swingx.mapviewer.PixelConverter converter,
                                                           int zoom,
                                                           org.opengis.referencing.crs.CoordinateReferenceSystem mapCRS,
                                                           boolean calculateArea)
Description copied from class: InstanceMarker
Paint a point geometry.

Overrides:
paintPoint in class InstanceMarker
Parameters:
geometry - the point
g - the graphics object to paint on
crsDefinition - the CRS definition associated to the geometry
context - the context
converter - the pixel converter
zoom - the zoom level
mapCRS - the map coordinate reference system
calculateArea - if the area representing the marker should be calculated, if false is given here the return value is ignored and should be null
Returns:
the point marker area or null if painting failed
See Also:
InstanceMarker.paintPoint(Point, Graphics2D, CRSDefinition, InstanceWaypoint, PixelConverter, int, CoordinateReferenceSystem, boolean)

Humboldt Alignment Editor 2.5.0

Build 2012-12-03_12-30-59
Revision 9d2dd4b0318cda9f1393b1ddd390f7f792d70a2d