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
categoricalpalette.h
Go to the documentation of this file.
1
16#ifndef CATEGORICALPALETTE_H
17#define CATEGORICALPALETTE_H
18
19#include <QColor>
20#include <QList>
21#include <QString>
22#include <QStringList>
23
25{
26
32[[nodiscard]] QColor at(int index);
33
37[[nodiscard]] int size();
38
42[[nodiscard]] QList<QColor> palette();
43
44// ── Slice BB-γ (2026-05-25) — named-palette catalogue ────────────────────
45//
46// Plotly's categorical palettes from plotly.colors.qualitative, plus the
47// existing Tab10 default. Lookups are case-insensitive; unknown names
48// fall back to Tab10.
49
57[[nodiscard]] QList<QColor> byName(const QString &name);
58
64[[nodiscard]] QStringList builtinNames();
65
66} // namespace CategoricalPalette
67
68#endif // CATEGORICALPALETTE_H
int index
Position in m_quadRegions / m_quadReports.
Definition meshgenerator.cpp:153
Definition categoricalpalette.h:25
QList< QColor > palette()
Returns the full palette as an ordered list.
Definition categoricalpalette.cpp:183
int size()
Number of colors in one full cycle before the palette wraps.
Definition categoricalpalette.cpp:178
QList< QColor > byName(const QString &name)
Returns the named palette as an ordered list. Falls back to the default (Tab10) when name doesn't mat...
Definition categoricalpalette.cpp:188
QColor at(int index)
Returns the i-th color from the default categorical palette.
Definition categoricalpalette.cpp:169
QStringList builtinNames()
Names of all built-in palettes, in catalogue order. Used by the Categorized tab's m_catScheme combo t...
Definition categoricalpalette.cpp:197
QString name
Definition sectionmodelbuilders.cpp:474