The Viewer tab (ViewerPage.qml, route Viewer) provides a hardware-friendly pyramidal whole-slide image viewport paired with drawing tools, class management panels, prediction overlays, and direct Predict… triggers.
Viewer canvas with top ViewerToolbar, left ViewerLayerToolbar, floating Brush bar (in editor mode), and annotation/prediction class panels.
Availability & Prerequisites
Active Project Required: Yes (First, select a project in the Projects tab.).
Active Slide Required: Select a WSI from the TopBar slide dropdown (Select a slide from the dropdown in the top bar.), or import slides into the active project.
Bio-Formats Slides (.vsi, etc.): Require a configured Java 11+ runtime in Admin → Settings → Java runtime for Bio-Formats.
Step-by-Step User Workflows
1. Navigate & Inspect Slides
Ensure an active slide is selected in TopBar. Wait briefly if "Loading overview…" appears while low-resolution pyramid levels load.
Use the Pan tool (H) to drag around the tissue, mouse wheel or Zoom in (+) / Zoom out (-) to zoom smoothly, or Fit to screen to reset framing.
If the high-resolution image file was moved on disk (WSI reference is saved, but high-resolution...), follow the Viewer prompt to re-link the file path without losing annotations.
2. Draw & Edit Ground-Truth Annotations
Pick Brush tool (B) or Rectangle tool (R) in ViewerToolbar to automatically enable Annotation Editor Mode.
When Brush is active, ViewerFloatingToolbar appears with a Brush diameter slider (2 to 80 px at level 0, step 2, default 12) plus Undo brush edit / Redo brush edit.
Use Select annotation (V) to click an existing annotation, then right-click to access:
Predict... — run inference focused on the selected region.
Change class... — reassign its class name and color (#RRGGBB / RGB sliders / presets).
Delete... — remove the selected annotation (with confirmation).
3. Inspect Predictions & Export to QuPath
Use the left ViewerLayerToolbar to toggle visibility for:
Base WSI (always on, cannot be toggled off)
Annotations (enabled when non-prediction annotation sets exist)
Predictions (enabled after inference completes for the active WSI)
Use the Annotation classes / Prediction classes panels to click All or None, rename a class (Edit class name...), customize hex/RGB colors (Choose Color), or delete annotations by class or run.
Right-click inside the viewport or on a prediction object and click Export to QuPath... (PredictionQuPathExportDialog) or Import QuPath GeoJSON... to exchange GeoJSON ROIs with QuPath.
flowchart LR
Load["Select Project & WSI in TopBar"] --> Nav["Pan (H) / Zoom (+,-) / Fit"]
Nav --> Annotate["Draw Annotations: Brush (B) or Rectangle (R)"]
Nav --> Predict["Right-click -> Predict... (Slide or Selected ROI)"]
Annotate --> GeoJSON["Import / Export QuPath GeoJSON"]
Predict --> Overlay["Toggle Predictions Layer & Class Filters"]
Overlay --> ExportPred["Export Predictions to QuPath GeoJSON"]
UI Controls & Toolbars Reference
Primary Toolbar (ViewerToolbar.qml)
Control
Shortcut
Tool Mode / Action
Notes
Pan tool
H
Navigation mode (annotationEditorMode = false)
Drag canvas to pan across slide
Select annotation
V
Selection mode
Click shapes to inspect, reclassify, delete, or run Predict...
Predict..., Change class..., Export to QuPath..., Delete this prediction annotation..., Delete all annotations of this run...
Viewport General Context Menu
Import QuPath GeoJSON..., Export to QuPath...
Class Panel Context Menu
Edit class name..., Delete class annotations / Delete prediction class..., plus All / None quick visibility toggles
Choose Color Dialog
Preset palette swatches, #RRGGBB hex input, RGB 0–255 sliders, and live preview swatch
Technical Reference
Memory Budget Governance: Decoded pyramid tile caching uses the Decoded tile cache (64–2048 MiB) budget and Java Bio-Formats slides obey Java heap (512–32768 MiB) configured in Admin → Settings (restart required after changing budgets).
Prediction Deletion Scopes: Deletion strictly separates three scopes via predictionDeletionDialog — single clicked object, entire prediction class on this WSI, or entire inference run — leaving unrelated runs intact.
Global Class Mapping Guard: If an import or inference prediction introduces unrecognized class names, root classMappingDialog / mappingBlockedDialog handles semantic class alignment before persistence.