Class TwoLinesBehavior
java.lang.Object
org.gvsig.fmap.mapcontrol.tools.Behavior.Behavior
org.gvsig.fmap.mapcontrol.tools.Behavior.PointBehavior
org.gvsig.fmap.mapcontrol.tools.Behavior.TwoLinesBehavior
- All Implemented Interfaces:
IBehavior
- Author:
- omartinez
-
Field Summary
FieldsFields inherited from class org.gvsig.fmap.mapcontrol.tools.Behavior.Behavior
BUTTON_LEFT, BUTTON_MIDDLE, BUTTON_RIGHT, geomManager, LOG, LOGGER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected voiddrawPolyline(MapControlDrawer mapControlDrawer, org.gvsig.fmap.geom.primitive.Curve curve) Gets theToolListenerused by this behavior to perform actions on the associatedMapControlobject.protected List<org.gvsig.fmap.geom.aggregate.MultiLine> getPossibleGeometriesFromLayers(org.gvsig.fmap.geom.primitive.Point mapPoint) org.gvsig.fmap.geom.primitive.LinegetSegmentFrom(org.gvsig.fmap.geom.primitive.Point mapPoint) voidvoidvoidvoidvoidpaintComponent(MapControlDrawer mapControlDrawer) Method executed in real-time, when user is working with a tool on the associatedMapControlobject, repainting theMapControl's image.protected voidprocessEvent(PointEvent event) voidsetListener(ToolListener listener) Sets a tool listener to work with theMapControlusing this behavior.Methods inherited from class org.gvsig.fmap.mapcontrol.tools.Behavior.Behavior
clean, createArc, createArc, createArc, createCircle, createEllipse, createPoint, createPoint, getImageCursor, getMapControl, getUseSnapping, isMyButton, isMyButton, mouseClicked, mouseEntered, mouseExited, mouseWheelMoved, paintComponent, resetMyButton, setMapControl, setUseSnapping
-
Field Details
-
isClicked
protected boolean isClicked -
listener
-
cuadrantPoint
-
-
Constructor Details
-
TwoLinesBehavior
-
-
Method Details
-
paintComponent
Description copied from interface:IBehaviorMethod executed in real-time, when user is working with a tool on the associated
MapControlobject, repainting theMapControl's image.Returns immediately in all cases, even if the complete image has not yet been loaded.
This method will be implemented according to the specific nature of each behavior, and its extra and particular features.
- Specified by:
paintComponentin interfaceIBehavior- Overrides:
paintComponentin classBehavior- See Also:
-
drawPolyline
protected void drawPolyline(MapControlDrawer mapControlDrawer, org.gvsig.fmap.geom.primitive.Curve curve) -
mousePressed
- Specified by:
mousePressedin interfaceIBehavior- Overrides:
mousePressedin classPointBehavior- Throws:
BehaviorException- any exception processing the action associated to a mouse pressed event, by theIBehaviorobject- See Also:
-
mouseReleased
- Specified by:
mouseReleasedin interfaceIBehavior- Overrides:
mouseReleasedin classBehavior- Throws:
BehaviorException- any exception processing the action associated to a mouse released event, by theIBehaviorobject- See Also:
-
processEvent
- Throws:
BehaviorException
-
getPossibleGeometriesFromLayers
protected List<org.gvsig.fmap.geom.aggregate.MultiLine> getPossibleGeometriesFromLayers(org.gvsig.fmap.geom.primitive.Point mapPoint) -
getSegmentFrom
public org.gvsig.fmap.geom.primitive.Line getSegmentFrom(org.gvsig.fmap.geom.primitive.Point mapPoint) throws BehaviorException - Throws:
BehaviorException
-
mouseDragged
- Specified by:
mouseDraggedin interfaceIBehavior- Overrides:
mouseDraggedin classBehavior- Throws:
BehaviorException- any exception processing the action associated to a mouse dragged event, by theIBehaviorobject- See Also:
-
changeLastPoint
-
mouseMoved
- Specified by:
mouseMovedin interfaceIBehavior- Overrides:
mouseMovedin classBehavior- Throws:
BehaviorException- any exception processing the action associated to a mouse moved event, by theIBehaviorobject- See Also:
-
setListener
Description copied from class:PointBehaviorSets a tool listener to work with the
MapControlusing this behavior.- Overrides:
setListenerin classPointBehavior- Parameters:
listener- aPointListenerobject for this behavior
-
getListener
Description copied from interface:IBehaviorGets the
ToolListenerused by this behavior to perform actions on the associatedMapControlobject.- Specified by:
getListenerin interfaceIBehavior- Overrides:
getListenerin classPointBehavior- Returns:
- the
ToolListenerused by this behavior
-