Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implements #4, a continuation of #18 for Godot 4. Many thanks to @Variable-ind for starting the work!
Tab containers now have settings with a "Make Floating" option. This is what makes panels into windows. To make windows into panels again, simply close the window. If the original tab container of the panel still exists when the window closes (meaning that it has more tabs and it did not get freed), the panel returns to that tab container. If it doesn't exist, it is being added to the first available tab container.
Based on my testing, it works well with the embed subwindows option set to both true or false. Windows and their data (position and size) are being stored in the layout, and thus are being remembered between sessions.
Probably the biggest issue with this is that child controls are being reparented to window nodes. Given how windows work in Godot, I don't think soft parenting is possible, especially now that we can have separate windows. But of course I may be wrong, so ideas are welcome!