public interface MouseHandlerFX
ChartCanvas and performs a function in response
to those events (typical functions include tooltip display, drag zooming,
mouse wheel zooming and panning). A handler can be registered with the
ChartCanvas as a regular handler or as an auxiliary handler. Upon a
mouse pressed event, the canvas will select *one* regular handler to be the
current "live" handler - this selection normally takes into account the
modifier keys that are specified for the handler. The live handler is
responsible for unregistering itself once it has finished handling mouse
events (it can be reselected again on subsequent mouse pressed events).
The auxiliary handlers are always called to respond to mouse events, but
after the live handler has dealt with the event first. Auxiliary handlers
should not perform tasks that could interfere with the live 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.
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getID()
Returns the ID for the handler.
|
void |
handleMouseClicked(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse clicked event.
|
void |
handleMouseDragged(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse dragged event.
|
void |
handleMouseMoved(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse moved event.
|
void |
handleMousePressed(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse pressed event.
|
void |
handleMouseReleased(ChartCanvas canvas,
javafx.scene.input.MouseEvent e)
Handles a mouse released event.
|
void |
handleScroll(ChartCanvas canvas,
javafx.scene.input.ScrollEvent e)
Handles a scroll event.
|
boolean |
hasMatchingModifiers(javafx.scene.input.MouseEvent e)
Returns
true if the specified mouse event has modifier
keys that match this handler. |
boolean |
isEnabled()
Returns
true if the mouse handler is enabled, and
false if it is disabled. |
java.lang.String getID()
null).boolean isEnabled()
true if the mouse handler is enabled, and
false if it is disabled.boolean hasMatchingModifiers(javafx.scene.input.MouseEvent e)
true if the specified mouse event has modifier
keys that match this handler.e - the mouse event (null not permitted).void handleMouseMoved(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
canvas - the canvas (null not permitted).e - the event (null not permitted).void handleMouseClicked(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
canvas - the canvas (null not permitted).e - the event (null not permitted).void handleMousePressed(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
canvas - the canvas (null not permitted).e - the event (null not permitted).void handleMouseDragged(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
canvas - the canvas (null not permitted).e - the event (null not permitted).void handleMouseReleased(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
canvas - the canvas (null not permitted).e - the event (null not permitted).void handleScroll(ChartCanvas canvas, javafx.scene.input.ScrollEvent e)
canvas - the canvas (null not permitted).e - the event (null not permitted).