Package qupath.lib.gui.viewer
Interface QuPathViewerListener
- All Superinterfaces:
EventListener
- All Known Implementing Classes:
UndoRedoManager
,ViewerManager
,ViewTracker
Interface for defining a listener that needs to know whenever the data
related to a QuPathViewer has changed in some way - such as by changing
the underlying ImageData, or by moving the field of view.
- Author:
- Pete Bankhead
-
Method Summary
Modifier and TypeMethodDescriptionvoid
imageDataChanged
(QuPathViewer viewer, ImageData<BufferedImage> imageDataOld, ImageData<BufferedImage> imageDataNew) Called with the image data within a viewer has changed.void
selectedObjectChanged
(QuPathViewer viewer, PathObject pathObjectSelected) Called when the primary selected object has changed in a viewer.void
viewerClosed
(QuPathViewer viewer) Called when a viewer is closed.void
visibleRegionChanged
(QuPathViewer viewer, Shape shape) Called when the visible region has changed in a viewer.
-
Method Details
-
imageDataChanged
void imageDataChanged(QuPathViewer viewer, ImageData<BufferedImage> imageDataOld, ImageData<BufferedImage> imageDataNew) Called with the image data within a viewer has changed.- Parameters:
viewer
- the viewer whose image has changedimageDataOld
- the image previously open in the viewerimageDataNew
- the image now open in the viewer
-
visibleRegionChanged
Called when the visible region has changed in a viewer.- Parameters:
viewer
- the viewer whose visible region has changed.shape
- shape representing the new visible region (in image pixel coordinates). This is rectangular, but may also be rotated.
-
selectedObjectChanged
Called when the primary selected object has changed in a viewer.- Parameters:
viewer
- the viewerpathObjectSelected
-
-
viewerClosed
Called when a viewer is closed.- Parameters:
viewer
- the viewer that has been closed.
-