diff options
Diffstat (limited to 'editor/property_editor.cpp')
-rw-r--r-- | editor/property_editor.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/editor/property_editor.cpp b/editor/property_editor.cpp index 81bd450484..ed90c8c4b2 100644 --- a/editor/property_editor.cpp +++ b/editor/property_editor.cpp @@ -1889,7 +1889,7 @@ CustomPropertyEditor::CustomPropertyEditor() { text_edit = memnew(TextEdit); add_child(text_edit); - text_edit->set_area_as_parent_rect(5); + text_edit->set_anchors_and_margins_preset(Control::PRESET_WIDE, Control::PRESET_MODE_MINSIZE, 5); text_edit->set_margin(MARGIN_BOTTOM, -30); text_edit->hide(); @@ -1948,12 +1948,12 @@ CustomPropertyEditor::CustomPropertyEditor() { spinbox = memnew(SpinBox); add_child(spinbox); - spinbox->set_area_as_parent_rect(5); + spinbox->set_anchors_and_margins_preset(Control::PRESET_WIDE, Control::PRESET_MODE_MINSIZE, 5); spinbox->connect("value_changed", this, "_range_modified"); slider = memnew(HSlider); add_child(slider); - slider->set_area_as_parent_rect(5); + slider->set_anchors_and_margins_preset(Control::PRESET_WIDE, Control::PRESET_MODE_MINSIZE, 5); slider->connect("value_changed", this, "_range_modified"); create_dialog = NULL; |