Commit Graph

4 Commits

Author SHA1 Message Date
Kacper Donat
bf856a1076 Gui: Make StyleParameterManager::resolve return optional result
This changes the resolve method of style parameter manager to return
optional intead of definitive result. In reality tokens may not be
defioned correctly and optionals provide a good way to nicely handle
defaults.
2025-08-12 22:04:23 +02:00
Kacper Donat
8072dcac34 Gui: Rename StyleParameters::Length to StyleParameters::Numeric
This change gives a better name to the parameter type that is used to
store numeric values. Before it was called length, but it can store
other quantities as well so the name is no longer fitting.
2025-08-12 21:25:41 +02:00
Kacper Donat
7e97d7fe5e Gui: StyleParameters - use Base::Color instead of QColor
If possible we should prefer using our own classess instead of ones
coming from frameworks. This changes Style Parameters to use Base::Color
class instead of QColor. Calculations are still done using QColor but
the data is always exposed as Base::Color.
2025-08-12 21:25:41 +02:00
Kacper Donat
8d3f41059f Gui: Add ThemeTokenManager class to contain theme parameters
This class aims to implement Design Token idea into FreeCAD themes. It
allows themes to use generic variables with generic values so we could
use one qss theme and change the style based on values from preference
packs.
2025-07-07 00:07:31 +02:00