godot
godot copied to clipboard
Editor preview of the contents of a TabContainer is incorrect for every tab except the first one
Godot version
v4.0.stable.official [92bee43ad]
System information
Linux
Issue description
Creating a tabbed interface for options, the Y position for elements inside the Audio tab (second tab) appear to be incorrect in comparison to the Graphics tab (first tab).
Compare:

That said, at runtime these appear to be in the correct positions.
Compare:

Steps to reproduce
A minimum scene tree:
Control
TabContainer
Control
Label
Control
Label
Where the labels have the same position according to Layout/Transform.
74653_demonstrator.zip should be a minimal reproduction.
Yeah, and I'm pretty sure this was reported already, but I can't find it. So we can keep this one for now.
Still happens in 4.1.1 stable .
need to change current tab value to correct tab to trigger sort_children
The minimal project is empty. There are no scenes.
Here is an MRP:
Steps:
- Open control.tscn.
- Use the toggle visibility button in the Scene dock to show the ColorRect or the TextureRect.
- The ColorRect doesn't show at all, and the TextureRect appears at the wrong position and scale.
- Use the TabContainer's current tab property in the Inspector to see what they should look like.
- After that, they will be correct when changing visibility, so close and reopen the scene to reproduce again.