diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-06-11 11:56:53 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-11 11:56:53 +0200 |
commit | 8d5bb06ae001d6aac9454490ca2f80a580495499 (patch) | |
tree | b76c0227b26b4acd750b55c1d7b30d57b47b6dfe /editor/editor_inspector.cpp | |
parent | bc75ef5ad091d93ce29868df4a8956c403e5c63b (diff) | |
parent | ecda25b050a40e7b4b17f735bc7aec4c584f88c9 (diff) |
Merge pull request #29515 from Calinou/editor-inspector-checkbox-hseparation
Add a margin to "checkable" property checkboxes in the editor inspector
Diffstat (limited to 'editor/editor_inspector.cpp')
-rw-r--r-- | editor/editor_inspector.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp index ecb9ea5f35..e4ddf44bc4 100644 --- a/editor/editor_inspector.cpp +++ b/editor/editor_inspector.cpp @@ -66,7 +66,7 @@ Size2 EditorProperty::get_minimum_size() const { if (checkable) { Ref<Texture> check = get_icon("checked", "CheckBox"); - ms.width += check->get_width() + get_constant("hseparator", "Tree"); + ms.width += check->get_width() + get_constant("hseparation", "CheckBox") + get_constant("hseparator", "Tree"); } if (bottom_editor != NULL && bottom_editor->is_visible()) { @@ -228,8 +228,7 @@ void EditorProperty::_notification(int p_what) { } check_rect = Rect2(ofs, ((size.height - checkbox->get_height()) / 2), checkbox->get_width(), checkbox->get_height()); draw_texture(checkbox, check_rect.position, color2); - ofs += get_constant("hseparator", "Tree"); - ofs += checkbox->get_width(); + ofs += get_constant("hseparator", "Tree") + checkbox->get_width() + get_constant("hseparation", "CheckBox"); text_limit -= ofs; } else { check_rect = Rect2(); |