SWMMVis  6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
Loading...
Searching...
No Matches
maptoolplotpick.h
Go to the documentation of this file.
1
21#ifndef OPENSWMMVIS_MAP_TOOLS_MAPTOOLPLOTPICK_H
22#define OPENSWMMVIS_MAP_TOOLS_MAPTOOLPLOTPICK_H
23
24#include "map/tools/maptool.h"
25#include "plot/plotattribute.h"
27
28#include <QStringList>
29#include "selection/selectionmanager.h" // SWMMObjectRef
30
32{
33 Q_OBJECT
34public:
35 explicit OpenSWMMVisMapToolPlotPick(MapCanvas *canvas, QObject *parent = nullptr);
36 ~OpenSWMMVisMapToolPlotPick() override = default;
37
38 QCursor cursor() const override;
39
43 void setSpeciesNames(QStringList names) { m_speciesNames = std::move(names); }
44
45 void mousePressEvent(QMouseEvent *event) override;
46 void keyPressEvent(QKeyEvent *event) override;
47
48signals:
54 const openswmmvis::plot::ResultDescriptor &descriptor);
55
59
63 void cancelled();
64
65private:
66 QStringList m_speciesNames;
67};
68
69#endif // OPENSWMMVIS_MAP_TOOLS_MAPTOOLPLOTPICK_H
The central map display widget — QGIS-style hybrid rendering.
Definition mapcanvas.h:63
Abstract base class for interactive map tools used in the MapCanvas.
Definition maptool.h:43
MapCanvas * canvas() const
Returns the MapCanvas this tool is attached to.
Definition maptool.cpp:29
Definition maptoolplotpick.h:32
~OpenSWMMVisMapToolPlotPick() override=default
void keyPressEvent(QKeyEvent *event) override
Definition maptoolplotpick.cpp:110
QCursor cursor() const override
Returns the mouse cursor to display while this tool is active.
Definition maptoolplotpick.cpp:29
void objectPicked(const SWMMObjectRef &ref, const openswmmvis::plot::ResultDescriptor &descriptor)
A map object was hit and the user picked an attribute from the submenu. Carries PlotAttribute::Unknow...
void setSpeciesNames(QStringList names)
Y2b-2: the active run's species names — shown in the attribute submenu beneath the fixed set....
Definition maptoolplotpick.h:43
void cancelled()
User pressed Escape or otherwise cancelled the pick tool. The owner should pop the tool off the canva...
void plotSystemRequested(openswmmvis::plot::PlotAttribute attribute)
A background click (no object under cursor) with a system attribute selected from the submenu.
void mousePressEvent(QMouseEvent *event) override
Definition maptoolplotpick.cpp:34
Abstract base class for all interactive tools attached to a MapCanvas.
PlotAttribute
What a series plots. One row per attribute in the Nx2 grid.
Definition plotattribute.h:38
Slice BL — canonical enumeration of plottable result attributes.
EdgeRef ref
Definition pslgminsize.cpp:377
QVector< int > parent
union-find
Definition pslgminsize.cpp:176
Y2b-1 (amendment D-Y4) — one plottable result, fixed or species.
Identifies a single SWMM object.
Definition selectionmanager.h:32
One plottable result: a fixed attribute OR a species by name.
Definition resultdescriptor.h:39