Egui::WidgetStyle
Inherits Reference < Object
Per-widget style overrides. All fields are nilable; nil means
"take the value from the app theme". #merge_over applies the
non-nil fields onto a copy of the theme's Style:
ui.add(Egui::Button.new("OK").style do |s| s.background = Egui::Color32.rgb(180, 40, 40) s.text_color = Egui::Color32.rgb(255, 255, 255) end)
An overridden widget keeps its overrides when the theme is swapped; every field left nil follows the new theme automatically.
Constructors
Instance methods
The box fill of button-like widgets — ONE CSS-like key. It is flat
across states (inline-style semantics); per-state values live in
class rules (button:hover { … }), resolved by
Widget#background_color, not by a Style slot.
The box fill of button-like widgets — ONE CSS-like key. It is flat
across states (inline-style semantics); per-state values live in
class rules (button:hover { … }), resolved by
Widget#background_color, not by a Style slot.
Named font family override (see Style#font_family); nil keeps
the theme's family.
Effective style = the theme's Style with every non-nil override applied. Returns a copy; the theme is never mutated.
Accent: progress bar fill, slider handle, selection.