Window and Popup nodes

I would like to know how to use (in Editor) the Window and Popup node.

It seems you cannot select them, you cannot resize them with the mouse.
But worse, any nodes I place as child nodes are not even visible and not selectable.

Is there a complete different workflow for these nodes?

Please, help me out.

Thanks

Windows and Popups are derived from Viewport, which means nodes under them are drawn within these viewports instead of the main viewport (aka main window, aka get_tree().root) .

The following shows how you can edit the size/position of the window and add other nodes within a Window.

Depending on the display/window/subwindows/embed_subwindows option, the window is either embedded within the main window, or a separate native window. Checkout out the documentation to see all available window flags.

2 Likes

Hi altamkp,

thank you for your quick reply.

Design of child nodes should be done all via inspector, right?
However it’s not the most productive way…

And speaking about the label in your example, is only visible if you write a text in it or if you apply some style.

I was trying to create a modal popup with a tab container and child nodes in it.
A kind of (modal) popup for some settings. I needed to jump from the scene hierarchy to the inspector without any “visual”. Again it seems to me that it is not the most easy way to design it.

Perhaps my modal popup is not the good case for this type of node?

Design of child nodes should be done all via inspector, right?

Yes, I suggest you work on all the UI (control) nodes in a separate scene, save that and put it under the Window/Popup node and adjust the size accordingly.

I was trying to create a modal popup with a tab container and child nodes in it.

If by modal you mean reusable component, that scene is definitely the right way to do it.

2 Likes

I came to the same solution of yours by saving the tab container branch as a scene.

Ok, this is a much better workflow.

By modal window I mean the usual window that pops up over the main window and disables the interaction with the main window (which with your window node is possible with ‘Exclusive’ and ‘Popup Window’ flags).

Thank you.