Make inspector spacing more themable #93435
Merged
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.
Some tweaks to make it easier to establish visual hierarchy in the inspector:
EditorInspectorCategory/styles/bg
into account when calculatingEditorInspectorCategory
min height to allow independent padding inside of it. It was only controllable throughTree
v_separation, making it impossible to set independently from all of the trees in the editorEditorInspector
main vbox separation to theming to allow space between inspector categories and sectionsEditorInspectorSection
themable (space between the arrow and the text)floor()
they were 1px shy, you can notice if you look real close at those category sections on the left picture)Note: when using vertical separation there's double separation below some node categories (like Node and Node3D) because there's a 0-height vbox hidden in there (not yet sure what it's for, probably some warning). I think VBoxContainer shouldn't do separation between 0-size controls, this is perhaps something to fix in a future PR
I also want to make section backgrounds themable to support rounded corners but they are drawn immediately through
draw_rect
because they're using different alphas depending on the nesting level. Maybe I should generate 5-6 stylebox variations for different levels. Something for a future PR as well