Is this CenterContainer behaviour correct?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Maxpilot

Done the following (Godot 3, Windows 7):

Scene with CenterContainer, Size Flags H and V Fill and Expand, Anchor 0,0,1,1, Margin 0,0,0,0.
TextureRect as child, texture (standard “icon.png”) set to Expand/Scale on Expand, Size Flags H and V Fill and Expand, Anchor 0,0,1,1 and Margin 0,0,0,0.
When running, nothing is visible.

Done the same with VBoxContainer or HBoxContainer instead of CenterContainer: Icon is visible and stretches and shrinks with window.

Shouldn’t it be the same with CenterContainer?

Refreshing this topic, I have the same issue…
I try to build an interface with few v/h boxes and a central CenterContainer set to expand, so it consumes all the space remaining after other containers put in their controls, and then put the TextureRect inside the center container, and it gets the size of 0, and can’t get it to expand within the container otherwise than by manually setting its size.

jarek | 2020-01-16 22:09