org.jfree.chart.fx.interaction
Interface MouseHandlerFX
-
- All Known Implementing Classes:
- AbstractMouseHandlerFX, AnchorHandlerFX, DispatchHandlerFX, PanHandlerFX, ScrollHandlerFX, TooltipHandlerFX, ZoomHandlerFX
public interface MouseHandlerFXThe interface for a mouse handler, which is an object that listens for mouse events on aChartCanvasand 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 theChartCanvasas 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.
- Since:
- 1.0.18
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description java.lang.StringgetID()Returns the ID for the handler.voidhandleMouseClicked(ChartCanvas canvas, javafx.scene.input.MouseEvent e)Handles a mouse clicked event.voidhandleMouseDragged(ChartCanvas canvas, javafx.scene.input.MouseEvent e)Handles a mouse dragged event.voidhandleMouseMoved(ChartCanvas canvas, javafx.scene.input.MouseEvent e)Handles a mouse moved event.voidhandleMousePressed(ChartCanvas canvas, javafx.scene.input.MouseEvent e)Handles a mouse pressed event.voidhandleMouseReleased(ChartCanvas canvas, javafx.scene.input.MouseEvent e)Handles a mouse released event.voidhandleScroll(ChartCanvas canvas, javafx.scene.input.ScrollEvent e)Handles a scroll event.booleanhasMatchingModifiers(javafx.scene.input.MouseEvent e)Returnstrueif the specified mouse event has modifier keys that match this handler.booleanisEnabled()Returnstrueif the mouse handler is enabled, andfalseif it is disabled.
-
-
-
Method Detail
-
getID
java.lang.String getID()
Returns the ID for the handler.- Returns:
- The ID (never
null).
-
isEnabled
boolean isEnabled()
Returnstrueif the mouse handler is enabled, andfalseif it is disabled.- Returns:
- A boolean.
-
hasMatchingModifiers
boolean hasMatchingModifiers(javafx.scene.input.MouseEvent e)
Returnstrueif the specified mouse event has modifier keys that match this handler.- Parameters:
e- the mouse event (nullnot permitted).- Returns:
- A boolean.
-
handleMouseMoved
void handleMouseMoved(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
Handles a mouse moved event.- Parameters:
canvas- the canvas (nullnot permitted).e- the event (nullnot permitted).
-
handleMouseClicked
void handleMouseClicked(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
Handles a mouse clicked event.- Parameters:
canvas- the canvas (nullnot permitted).e- the event (nullnot permitted).
-
handleMousePressed
void handleMousePressed(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
Handles a mouse pressed event.- Parameters:
canvas- the canvas (nullnot permitted).e- the event (nullnot permitted).
-
handleMouseDragged
void handleMouseDragged(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
Handles a mouse dragged event.- Parameters:
canvas- the canvas (nullnot permitted).e- the event (nullnot permitted).
-
handleMouseReleased
void handleMouseReleased(ChartCanvas canvas, javafx.scene.input.MouseEvent e)
Handles a mouse released event.- Parameters:
canvas- the canvas (nullnot permitted).e- the event (nullnot permitted).
-
handleScroll
void handleScroll(ChartCanvas canvas, javafx.scene.input.ScrollEvent e)
Handles a scroll event.- Parameters:
canvas- the canvas (nullnot permitted).e- the event (nullnot permitted).
-
-
DMelt 3.0 © DataMelt by jWork.ORG