So I'm trying to implement a UI manager that has 4 different UI docks(top, right, bottom, left) that can be used to display information. Each dock is a scene with a nine patch rect and a margin container, where the content I want to display is appended. The problem is when I add content, like a text box with overflow, the dock doesn't resize properly, specially horizontally. in this example, the box should stretch not only vertically but horizontally as well.
#Nine Patch Rect Proper resizing based on children
1 messages · Page 1 of 1 (latest)
Does the panel work correctly if you resize it in the editor?
Also, have you tried a PanelContainer with a StyleBoxTexture?
Yup it works if I manually resize it in the editor and I've also tried with a panel container and the result is the same
I think the problem is that I should programmatically change the rect size to fit the content, which I am not doing at the moment.
I think you shouldn't have to do that but if that works...