You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I can confirm this on v4.1.beta.custom_build 3aaa787 (Linux). Note that it appears pretty flaky: if you resize the editor window after changing type, the control's size will change back to its original size. The exact size that appears temporarily can also vary, and undo/redo can mess it up too.
Also, this doesn't occur with all controls – for instance, switching from Control to HSlider won't exhibit this issue.
I tried looking into this issue but couldn't figure out what causes it. Here are some of the things I found in case someone finds them helpful:
Selecting the same type of node when switching, e.g. from a Control node to a Control node, produces the same issue, it gets resized to a different size.
There's this function gets called during the resize:
While the if branch would return the global viewport's size, which correspond to the original control node's size (1152x648). During resizes the else branch is always taken. parent_rect = get_viewport()->get_visible_rect(); always returns (1348x649), which seems to correspond to a Subviewport, child of a Window node, not sure how those are related to our Control node. This last size is the one we can see being the base size when changing the type of the node in the editor.
Godot version
v4.0.3.stable.official [5222a99]
System information
Windows 10 - Godot v4.0.3stable
Issue description
If a root
Control
node's type is changed to aControl
subtype, its size will change as well.Steps to reproduce
User Interface
sceneVBoxContainer
Minimal reproduction project
N/A
The text was updated successfully, but these errors were encountered: