Merge pull request #95736 from nongvantinh/checkbox-states-colors
Allow changing the color for the Checkbox's checked and unchecked icons
This commit is contained in:
@ -328,6 +328,9 @@ void fill_default_theme(Ref<Theme> &theme, const Ref<Font> &default_font, const
|
||||
theme->set_constant("check_v_offset", "CheckBox", 0);
|
||||
theme->set_constant("outline_size", "CheckBox", 0);
|
||||
|
||||
theme->set_color("checkbox_checked_color", "CheckBox", Color(1, 1, 1));
|
||||
theme->set_color("checkbox_unchecked_color", "CheckBox", Color(1, 1, 1));
|
||||
|
||||
// CheckButton
|
||||
|
||||
Ref<StyleBox> cb_empty = memnew(StyleBoxEmpty);
|
||||
@ -365,6 +368,9 @@ void fill_default_theme(Ref<Theme> &theme, const Ref<Font> &default_font, const
|
||||
theme->set_constant("check_v_offset", "CheckButton", 0);
|
||||
theme->set_constant("outline_size", "CheckButton", 0);
|
||||
|
||||
theme->set_color("button_checked_color", "CheckButton", Color(1, 1, 1));
|
||||
theme->set_color("button_unchecked_color", "CheckButton", Color(1, 1, 1));
|
||||
|
||||
// Button variations
|
||||
|
||||
theme->set_type_variation(SceneStringName(FlatButton), "Button");
|
||||
|
||||
Reference in New Issue
Block a user