33#ifndef OPENSWMMVIS_UI_WIDGETS_LEGENDOVERLAY_H
34#define OPENSWMMVIS_UI_WIDGETS_LEGENDOVERLAY_H
84 bool eventFilter(QObject *watched, QEvent *event)
override;
87 void onStyleChanged();
88 void openPropertiesDialog();
89 void copyLegendImage();
94 void recomputeLayout();
95 void clampInsideCanvas();
96 void anchorToCanvas();
101 [[nodiscard]]
int edgesAt(
const QPoint &
pos)
const;
103 void updateCursor(
int edges);
114 QPointer<OpenSWMMVisLayer> layer;
117 QVector<ItemBand> items;
127 QPair<OpenSWMMVisLayer *, QString> itemAtY(
int y)
const;
129 QPointer<MapCanvas> m_canvas;
131 bool m_ownsStyle =
false;
132 QPoint m_dragStartOffset;
133 bool m_dragging =
false;
134 bool m_positioned =
false;
135 QVector<LayerBand> m_layerBands;
138 int m_resizeEdges = 0;
139 QRect m_resizeStartGeom;
140 QPoint m_resizeStartGlobal;
141 bool m_resizing =
false;
The central map display widget — QGIS-style hybrid rendering.
Definition mapcanvas.h:63
Model object holding the on-canvas legend's chrome configuration.
Definition legendoverlaystyle.h:50
Abstract base class for all layers displayed in the MapCanvas.
Definition openswmmvislayer.h:116
Definition legendoverlay.h:51
void paintEvent(QPaintEvent *event) override
Definition legendoverlay.cpp:323
void hideRequested()
Emitted when the user selects "Hide Legend" from the context menu. The toolbar should toggle actionSh...
bool eventFilter(QObject *watched, QEvent *event) override
Definition legendoverlay.cpp:732
void contextMenuEvent(QContextMenuEvent *event) override
Definition legendoverlay.cpp:581
void mouseMoveEvent(QMouseEvent *event) override
Definition legendoverlay.cpp:516
OpenSWMM::Render::LegendOverlayStyle * style() const noexcept
Returns the LegendOverlayStyle this overlay paints with. Never null while the overlay exists....
Definition legendoverlay.h:64
void mouseReleaseEvent(QMouseEvent *event) override
Definition legendoverlay.cpp:551
~LegendOverlay() override
Definition legendoverlay.cpp:104
void mousePressEvent(QMouseEvent *event) override
Definition legendoverlay.cpp:495
void setStyle(OpenSWMM::Render::LegendOverlayStyle *style, bool takeOwnership=false)
Swap in a different (project- or canvas-scoped) style. The overlay disconnects from the previous styl...
Definition legendoverlay.cpp:153
void setCanvas(MapCanvas *canvas)
Re-bind to a (possibly null) canvas; disconnects from the old canvas's signals and connects to the ne...
Definition legendoverlay.cpp:112
Definition gisrasterlayer.h:40
Definition openswmmvislayer.h:43
int pos
Definition queryparser.cpp:36