From d655fc8fed8326104013e5d3cc4545c769ecd398 Mon Sep 17 00:00:00 2001 From: Haoyu Qiu Date: Wed, 29 May 2024 09:06:06 +0800 Subject: [PATCH] Add range hint for ViewportContainer.stretch_shrink --- scene/gui/viewport_container.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scene/gui/viewport_container.cpp b/scene/gui/viewport_container.cpp index 96b0fdd9bf6..9ef9d55d997 100644 --- a/scene/gui/viewport_container.cpp +++ b/scene/gui/viewport_container.cpp @@ -204,7 +204,7 @@ void ViewportContainer::_bind_methods() { ClassDB::bind_method(D_METHOD("get_stretch_shrink"), &ViewportContainer::get_stretch_shrink); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "stretch"), "set_stretch", "is_stretch_enabled"); - ADD_PROPERTY(PropertyInfo(Variant::INT, "stretch_shrink"), "set_stretch_shrink", "get_stretch_shrink"); + ADD_PROPERTY(PropertyInfo(Variant::INT, "stretch_shrink", PROPERTY_HINT_RANGE, "1,32,1,or_greater"), "set_stretch_shrink", "get_stretch_shrink"); } ViewportContainer::ViewportContainer() {