Hello,
I need a UMG widget that acts just like a vertical or horizontal box that can be sorted at runtime, more generally, the slots can be rearranged at runtime. It appears I need to do this in Slate with C++, which is fine, I just have some questions about Slate and UMG to help be understand how it works under the hood.
From what I can tell slate, and by extension UMG widgets are constructed when the widget is created or added to the viewport. The structure does not change again after that. I’ve observed this in the VerticalBox.cpp file. RebuildWidget() is called on construction and not again, it creates a SVerticalBox and returns it.
In order to rearrange slots at runtime it appears I may have to rebuild the widget at runtime. But this doesn’t appear to be a practice commonly used in Slate. I assume this is for performance reasons.
So is this the best way to approach the problem? Or am I misunderstanding Slate? If this is the way to do it, how do I force the widget to rebuild at any time other than construction?
Thanks.