Hi folks,
This seems like a simple thing to do, but I’m stumped as to why it’s not working.
I want to make a sliced textbox background, with text in front, followed by two buttons. This is the mockup. The buttons should retain aspect and pack to the right, but as they gain height they should increase in size. The text box should fill the remaining room.
I added a horizontal layout group as a parent to all of them, and the buttons instantly expanded to fill the whole thing.
This vid does something very similar successfully. It does that by adding a layout element to its “button” and setting flexible width to 0. I do that and there’s no change, the buttons stay huge.
The layout properties readout in the inspector for the two buttons show huge preferred width: 6900, at a horizontal resolution of 491. The sprite is only 69x69. Is that value pixels, or something else?
The text box object is a sliced image with a stretch-anchored child text object. Its preferred width in the layout properties readout is only 52. The text object is set to best fit, overflow/truncate, but fiddling with these don’t seem to change anything.
Toggling Expand Width on the parent horizontal group layout doesn’t change anything.
I’m on beta 21 but get the same behaviour loading the scene in beta 20.
Any pointers on where I’m going wrong?