mirror of
https://github.com/godotengine/godot.git
synced 2024-11-10 14:12:51 +00:00
Fix popup windows content margins
This commit is contained in:
parent
705b7a0b0b
commit
71b300d9ac
@ -393,7 +393,7 @@ EditorThemeManager::ThemeConfiguration EditorThemeManager::_create_theme_config(
|
||||
config.base_margin = config.base_spacing;
|
||||
config.increased_margin = config.base_spacing + config.extra_spacing;
|
||||
config.separation_margin = (config.base_spacing + config.extra_spacing / 2) * EDSCALE;
|
||||
config.popup_margin = config.base_margin * 3 * EDSCALE;
|
||||
config.popup_margin = config.base_margin * 2.4 * EDSCALE;
|
||||
// Make sure content doesn't stick to window decorations; this can be fixed in future with layout changes.
|
||||
config.window_border_margin = MAX(1, config.base_margin * 2);
|
||||
config.top_bar_separation = config.base_margin * 2 * EDSCALE;
|
||||
@ -633,6 +633,7 @@ void EditorThemeManager::_create_shared_styles(const Ref<EditorTheme> &p_theme,
|
||||
p_config.dialog_style = p_config.base_style->duplicate();
|
||||
p_config.dialog_style->set_corner_radius(CORNER_TOP_LEFT, 0);
|
||||
p_config.dialog_style->set_corner_radius(CORNER_TOP_RIGHT, 0);
|
||||
p_config.dialog_style->set_content_margin_all(p_config.popup_margin);
|
||||
// Prevent visible line between window title and body.
|
||||
p_config.dialog_style->set_expand_margin(SIDE_BOTTOM, 2 * EDSCALE);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user