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
themetokens.h
Go to the documentation of this file.
1#ifndef THEMETOKENS_H
2#define THEMETOKENS_H
3
21#include <QColor>
22
23namespace openswmmvis::ui {
24
26 // Surfaces (back to front) and primary content.
30 QColor text;
31 QColor hintText;
32 QColor border;
33
34 // Interaction.
35 QColor accent;
36 QColor accentText;
37 QColor focusRing;
40
41 // Semantic status (used as text colors on surfaces).
42 QColor error;
43 QColor warning;
44 QColor success;
45 QColor info;
46
47 // Inline banners (message strips inside dialogs).
51
52 // Plot chrome (profile/mesh plot widgets — axes, not data series).
54 QColor plotAxis;
55 QColor plotGrid;
59
60 // Map canvas chrome.
62};
63
64inline const ThemeColors &lightColors()
65{
66 static const ThemeColors c = {
67 /* surfaceWindow */ QColor(0xF5, 0xF5, 0xF7),
68 /* surfaceRaised */ QColor(0xFF, 0xFF, 0xFF),
69 /* surfaceSunken */ QColor(0xE9, 0xE9, 0xED),
70 /* text */ QColor(0x1D, 0x1D, 0x1F),
71 /* hintText */ QColor(0x5A, 0x5A, 0x60),
72 /* border */ QColor(0xC9, 0xC9, 0xCE),
73
74 /* accent */ QColor(0x0A, 0x66, 0xC2),
75 /* accentText */ QColor(0xFF, 0xFF, 0xFF),
76 /* focusRing */ QColor(0x0A, 0x66, 0xC2),
77 /* selectionFill */ QColor(0x0A, 0x66, 0xC2),
78 /* selectionText */ QColor(0xFF, 0xFF, 0xFF),
79
80 /* error */ QColor(0xB3, 0x26, 0x1E),
81 /* warning */ QColor(0x7A, 0x59, 0x00),
82 /* success */ QColor(0x1E, 0x6B, 0x34),
83 /* info */ QColor(0x0A, 0x66, 0xC2),
84
85 /* bannerErrorBg */ QColor(0xF9, 0xDE, 0xDC),
86 /* bannerErrorFg */ QColor(0x7A, 0x17, 0x10),
87 /* bannerSuccessBg */ QColor(0xDF, 0xF0, 0xE1),
88 /* bannerSuccessFg */ QColor(0x14, 0x4D, 0x26),
89 /* bannerInfoBg */ QColor(0xDE, 0xE9, 0xF7),
90 /* bannerInfoFg */ QColor(0x11, 0x3A, 0x66),
91
92 /* plotBackground */ QColor(0xFF, 0xFF, 0xFF),
93 /* plotAxis */ QColor(0x55, 0x55, 0x5B),
94 /* plotGrid */ QColor(0xDC, 0xDC, 0xE0),
95 /* plotConduit */ QColor(0x33, 0x33, 0x33),
96 /* plotNodeBar */ QColor(0x22, 0x22, 0x22),
97 /* plotNodeLabel */ QColor(0x10, 0x10, 0x10),
98
99 /* canvasSelectionHighlight */ QColor(0x00, 0xB8, 0xD9),
100 };
101 return c;
102}
103
104inline const ThemeColors &darkColors()
105{
106 static const ThemeColors c = {
107 /* surfaceWindow */ QColor(0x1E, 0x1E, 0x22),
108 /* surfaceRaised */ QColor(0x2A, 0x2A, 0x30),
109 /* surfaceSunken */ QColor(0x17, 0x17, 0x1A),
110 /* text */ QColor(0xE8, 0xE8, 0xEA),
111 /* hintText */ QColor(0xA5, 0xA5, 0xAD),
112 /* border */ QColor(0x3F, 0x3F, 0x46),
113
114 /* accent */ QColor(0x4C, 0x9A, 0xFF),
115 /* accentText */ QColor(0x0B, 0x1E, 0x36),
116 /* focusRing */ QColor(0x4C, 0x9A, 0xFF),
117 /* selectionFill */ QColor(0x4C, 0x9A, 0xFF),
118 /* selectionText */ QColor(0x0B, 0x1E, 0x36),
119
120 /* error */ QColor(0xF2, 0x72, 0x6B),
121 /* warning */ QColor(0xE0, 0xA9, 0x3E),
122 /* success */ QColor(0x5D, 0xBB, 0x7A),
123 /* info */ QColor(0x4C, 0x9A, 0xFF),
124
125 /* bannerErrorBg */ QColor(0x3A, 0x15, 0x13),
126 /* bannerErrorFg */ QColor(0xF5, 0xB8, 0xB3),
127 /* bannerSuccessBg */ QColor(0x12, 0x30, 0x1C),
128 /* bannerSuccessFg */ QColor(0xA8, 0xDD, 0xB8),
129 /* bannerInfoBg */ QColor(0x10, 0x2A, 0x4A),
130 /* bannerInfoFg */ QColor(0xA9, 0xCC, 0xF5),
131
132 /* plotBackground */ QColor(0x23, 0x23, 0x27),
133 /* plotAxis */ QColor(0xA5, 0xA5, 0xAD),
134 /* plotGrid */ QColor(0x3A, 0x3A, 0x40),
135 /* plotConduit */ QColor(0xC8, 0xC8, 0xCC),
136 /* plotNodeBar */ QColor(0xD8, 0xD8, 0xDC),
137 /* plotNodeLabel */ QColor(0xEF, 0xEF, 0xF2),
138
139 /* canvasSelectionHighlight */ QColor(0x33, 0xD6, 0xF5),
140 };
141 return c;
142}
143
144} // namespace openswmmvis::ui
145
146#endif // THEMETOKENS_H
Definition openswmmvislayer.h:43
const ThemeColors & lightColors()
Definition themetokens.h:64
const ThemeColors & darkColors()
Definition themetokens.h:104
Definition themetokens.h:25
QColor border
separators, frames
Definition themetokens.h:32
QColor accent
brand/interactive color (links, checked)
Definition themetokens.h:35
QColor plotNodeLabel
Definition themetokens.h:58
QColor success
Definition themetokens.h:44
QColor bannerErrorFg
Definition themetokens.h:48
QColor plotNodeBar
Definition themetokens.h:57
QColor surfaceSunken
wells, alternate rows
Definition themetokens.h:29
QColor bannerSuccessBg
Definition themetokens.h:49
QColor plotGrid
Definition themetokens.h:55
QColor plotBackground
Definition themetokens.h:53
QColor error
Definition themetokens.h:42
QColor selectionText
text on selectionFill
Definition themetokens.h:39
QColor info
Definition themetokens.h:45
QColor text
primary text on any surface tier
Definition themetokens.h:30
QColor bannerSuccessFg
Definition themetokens.h:49
QColor warning
Definition themetokens.h:43
QColor surfaceRaised
views, editors, cards (QPalette::Base)
Definition themetokens.h:28
QColor selectionFill
item-view selection background
Definition themetokens.h:38
QColor canvasSelectionHighlight
Definition themetokens.h:61
QColor focusRing
keyboard-focus outline (≥ 3:1 on surfaces)
Definition themetokens.h:37
QColor plotConduit
Definition themetokens.h:56
QColor bannerInfoBg
Definition themetokens.h:50
QColor accentText
text painted on accent fills
Definition themetokens.h:36
QColor bannerErrorBg
Definition themetokens.h:48
QColor surfaceWindow
window / toolbar background
Definition themetokens.h:27
QColor plotAxis
Definition themetokens.h:54
QColor hintText
secondary/placeholder text (AA on surfaces)
Definition themetokens.h:31
QColor bannerInfoFg
Definition themetokens.h:50