How to currectly get the size of user widget?

Hi, everyone:

I want to get the size of my widget in its own preconstruct event for preview layout, I have tried:

but it only works when the anchor of this widget is top-left, I can only get the offset if the anchor is “top-fill”.
I have tried

but this only works at runtime.

Is anyone can tell me how to get the size of an widget in its own PreConstruct evenet? Thank a lot for your time.

Hi, everyone, I have found out what I need, it quite simple, just add a delay node before get the size from cached geometry:

In PreConstructEvent::


If you want to get the runtime size in widget tick, you can:


Hope that helps.

1 Like

This works in blueprint too. Helps me preview how my widget will look in editor.