public class PanHandlerFX extends AbstractMouseHandlerFX
ChartCanvas
. This handler
should be configured with the required modifier keys and installed as a
live handler (not an auxiliary handler).
THE API FOR THIS CLASS IS SUBJECT TO CHANGE IN FUTURE RELEASES. This is so that we can incorporate feedback on the (new) JavaFX support in JFreeChart.
Constructor and Description |
---|
PanHandlerFX(java.lang.String id)
Creates a new instance that requires no modifier keys.
|
PanHandlerFX(java.lang.String id,
boolean altKey,
boolean ctrlKey,
boolean metaKey,
boolean shiftKey)
Creates a new instance that will be activated using the specified
combination of modifier keys.
|
Modifier and Type | Method and Description |
---|---|
void |
handleMouseDragged(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse dragged event by calculating the distance panned and
updating the axes accordingly.
|
void |
handleMousePressed(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse pressed event by recording the initial mouse pointer
location.
|
void |
handleMouseReleased(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse released event.
|
getID, handleMouseClicked, handleMouseMoved, handleScroll, hasMatchingModifiers, isEnabled, setEnabled
public PanHandlerFX(java.lang.String id)
id
- the id (null
not permitted).public PanHandlerFX(java.lang.String id, boolean altKey, boolean ctrlKey, boolean metaKey, boolean shiftKey)
id
- the id (null
not permitted).altKey
- require ALT key?ctrlKey
- require CTRL key?metaKey
- require META key?shiftKey
- require SHIFT key?public void handleMousePressed(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
handleMousePressed
in interface MouseHandlerFX
handleMousePressed
in class AbstractMouseHandlerFX
canvas
- the JavaFX canvas (null
not permitted).e
- the mouse event (null
not permitted).public void handleMouseDragged(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
handleMouseDragged
in interface MouseHandlerFX
handleMouseDragged
in class AbstractMouseHandlerFX
canvas
- the JavaFX canvas (null
not permitted).e
- the mouse event (null
not permitted).public void handleMouseReleased(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
AbstractMouseHandlerFX
handleMouseReleased
in interface MouseHandlerFX
handleMouseReleased
in class AbstractMouseHandlerFX
canvas
- the canvas (null
not permitted).e
- the event (null
not permitted).