So far I made my widgets using child widgets I created. The more nested they are, the more variables need to be transmitted, which can get tiresome. Therefore I wonder whether a widget can show the properties of one of it’s children in the properties of the widget itself.
Example: Let’s say I have a menu, that has a custom button widget in it. This button widget consists of a button and a custom text widget. That text widget only uses a single text block.
Right now, the text in the text block from the text widget is set by a variable in the text widget. The variable of the text widget inside the button widget gets set by another variable in the button widget. What I want is to set the variable of the text widget directly using the properties panel when editing the button widget inside the menu widget. Is that possible?
You can absolutely use a regular actor for this, especially if the menu needs extra functionality - like timelines, or handle other components or be 3d. The extra functionality of an actor manager can be handy at times.
You could utilise the HUD class for this. Especially considering how easy it is to access - since it’s a framework class.
And once a widget gets access to an actor or an object, you can bind its properties:
The downside is that you need to provide each widget with a hard reference - but that’s 1 variable rather than dozens or hundreds. Not really an issue for something like a main menu, though.