summaryrefslogtreecommitdiff
path: root/editor/editor_inspector.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_inspector.cpp')
-rw-r--r--editor/editor_inspector.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp
index cfce37ea1b..e6c4c14830 100644
--- a/editor/editor_inspector.cpp
+++ b/editor/editor_inspector.cpp
@@ -1182,15 +1182,19 @@ void EditorInspectorSection::_notification(int p_what) {
Size2 size = get_size();
Point2 offset;
+ Rect2 rect;
offset.y = font->get_height(font_size);
if (arrow.is_valid()) {
offset.y = MAX(offset.y, arrow->get_height());
}
offset.y += get_theme_constant("vseparation", "Tree");
- offset.x += get_theme_constant("inspector_margin", "Editor");
-
- Rect2 rect(offset, size - offset);
+ if (is_layout_rtl()) {
+ rect = Rect2(offset, size - offset - Vector2(get_theme_constant("inspector_margin", "Editor"), 0));
+ } else {
+ offset.x += get_theme_constant("inspector_margin", "Editor");
+ rect = Rect2(offset, size - offset);
+ }
//set children
for (int i = 0; i < get_child_count(); i++) {