![]() |
SWMMVis
6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
|
Manifest-driven screenshot capture for the user manual's figures. More...
#include <QElapsedTimer>#include <QJsonObject>#include <QList>#include <QObject>#include <QSize>#include <QString>Go to the source code of this file.
Classes | |
| struct | openswmmvis::ui::FigureSpec |
| One row of the manifest: a figure and how to reach it. More... | |
| struct | openswmmvis::ui::FigureResult |
| Result of attempting one row; serialised into run.json. More... | |
| class | openswmmvis::ui::FigureCapture |
| Drives a manifest of figures to PNG, then quits the application. More... | |
Namespaces | |
| namespace | openswmmvis |
| namespace | openswmmvis::ui |
Enumerations | |
| enum class | openswmmvis::ui::FigureLane { openswmmvis::ui::Offscreen , openswmmvis::ui::Live , openswmmvis::ui::Human } |
| Which platform a figure can be captured on. More... | |
Manifest-driven screenshot capture for the user manual's figures.
The manual (docs/manual/) declares every screenshot as a \figtodo placeholder and turns it into \fig once the PNG exists in docs/manual/images/. This class produces those PNGs without a human at the keyboard: SWMMVIS_CAPTURE_MANIFEST=<abs .json> names a list of figures, each describing the UI state to reach and the widget to grab.
Generalises the three one-off SWMMVIS_SNAPSHOT_* dev hooks in swmmvis.cpp (which stay, being documented in appendices/a04_performance.md) into one table so a whole chapter is captured per launch — 326 one-shot launches would be ~45 min of pure startup, grouped runs are ~2 min.
Two run modes, one manifest. QT_QPA_PLATFORM=offscreen handles widget-only figures (dialogs, docks, panels) with no display; anything containing scene-graph content (2D mesh, 2D results) reads back BLANK offscreen and must run on the live cocoa platform. Rows are not classified by hand: every grab is scored and a blank one is reported so it can be re-shot on the live lane.
Deliberately public-API only (ActionRegistry, ThemeManager, QWidget) so it needs no access to SWMMVis internals. Models are supplied by the launcher through SWMMVIS_OPEN_ON_STARTUP, one launch per model.