Add bulk change guards to successive theme overrides in Editor and GUI
This commit is contained in:
@ -42,12 +42,19 @@ const String EditorAbout::META_TEXT_TO_COPY = "text_to_copy";
|
||||
void EditorAbout::_theme_changed() {
|
||||
const Ref<Font> font = get_theme_font(SNAME("source"), EditorStringName(EditorFonts));
|
||||
const int font_size = get_theme_font_size(SNAME("source_size"), EditorStringName(EditorFonts));
|
||||
|
||||
_tpl_text->begin_bulk_theme_override();
|
||||
_tpl_text->add_theme_font_override("normal_font", font);
|
||||
_tpl_text->add_theme_font_size_override("normal_font_size", font_size);
|
||||
_tpl_text->add_theme_constant_override("line_separation", 4 * EDSCALE);
|
||||
_tpl_text->end_bulk_theme_override();
|
||||
|
||||
_license_text->begin_bulk_theme_override();
|
||||
_license_text->add_theme_font_override("normal_font", font);
|
||||
_license_text->add_theme_font_size_override("normal_font_size", font_size);
|
||||
_license_text->add_theme_constant_override("line_separation", 4 * EDSCALE);
|
||||
_license_text->end_bulk_theme_override();
|
||||
|
||||
_logo->set_texture(get_editor_theme_icon(SNAME("Logo")));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user