Hi,
How to emphasise the difference between types of controls of the same class (UI) with the use of palettes or styles but these controls have different roles? (similar like using bootstrap with webapps)
For example. Some buttons should stand out more (primary, secondary, warning etc).
Kind of similar like: https://github.com/supercollider/supercollider/issues/3598
I found that SuperCollider has some style support. Some example code based on the current documentation:
‘’’
(
p = QPalette().button_(Color.yellow);
v = View(bounds: 400@400).layout_(VLayout()).front;
v.layout.add(TextView());
v.layout.add(PopUpMenu().items_({1.0.rand}!10));
v.layout.add(Button().string_(“hi”));
v.layout.add(Button().string_(“hi hi”).palette_(QPalette.dark));
v.layout.add(Button().palette_(p).states_([[“Color on”], [“Color off”]]));
v.layout.add(Button().palette_(p).states_([[“Color 2”], [“Color 1”]])); // fourth button
)
p.button_(Color.red); // set the style or override the colors of the fourt buton
QPalette.cheatsheet
QtGUI.palette = QPalette.dark
QtGUI.palette = QPalette.light
QtGUI.palette = QPalette.new
QtGUI.availableStyles
QtGUI.style = “fusion”
QtGUI.style = “windows”
QtGUI.style = “macintosh”
GUI skins however that seems not supported with combination with styles and palettes.
‘’’
Is it possible to refine button style based on a current available when it’s a warning or primary button?
With kind regards,
Marinus