You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the problem or limitation you are having in your project
In an effort to get the bottom panel to have more functionality like regular docks do, for #4565 and #7156.
I was trying to make the Bottom Panel use a TabBar instead of an HBoxContainer of buttons, but I realized the bottom panel needs to be collapsible and be able to have no tabs selected.
The plan is to first make it use TabBar since there is a plugin API change for add_bottom_panel_item.
Then it will be changed to use a TabContainer once it gets some other features like #2250 and godotengine/godot#82468.
However, if we don't want Bottom Panel to use TabBar or break the current API, then the needed functionality can be implemented in different ways instead.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
TabBar and TabContainer would have an optional setting that allows no tabs to be selected. When a selected tab is clicked, it deselects.
Only the tab header would be shown when there are no tabs selected.
This will let the Bottom Panel shrink with clip_tabs for #7156 and situations with lots of bottom panel items. It will also allow the tabs to be rearranged with drag_to_rearrange_enabled (only within Bottom Panel at first).
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
TabBar would have a allow_deselection (or toggle_tabs?) field that when enabled allows no tabs to be selected.
When clicking on the current tab, current_tab gets set to -1.
The tab_changed signal should be emitted when this happens.
For TabContainer, when current_tab is -1 hide all child's content.
If this enhancement will not be used often, can it be worked around with a few lines of script?
Not really, you would have to re-implement TabBar.
Is there a reason why this should be core and not an add-on in the asset library?
It's for the editor.
The text was updated successfully, but these errors were encountered:
Describe the project you are working on
Godot Editor
Describe the problem or limitation you are having in your project
In an effort to get the bottom panel to have more functionality like regular docks do, for #4565 and #7156.
I was trying to make the Bottom Panel use a
TabBar
instead of anHBoxContainer
of buttons, but I realized the bottom panel needs to be collapsible and be able to have no tabs selected.The plan is to first make it use
TabBar
since there is a plugin API change foradd_bottom_panel_item
.Then it will be changed to use a
TabContainer
once it gets some other features like #2250 and godotengine/godot#82468.However, if we don't want Bottom Panel to use
TabBar
or break the current API, then the needed functionality can be implemented in different ways instead.Describe the feature / enhancement and how it helps to overcome the problem or limitation
TabBar
andTabContainer
would have an optional setting that allows no tabs to be selected. When a selected tab is clicked, it deselects.Only the tab header would be shown when there are no tabs selected.
This will let the Bottom Panel shrink with
clip_tabs
for #7156 and situations with lots of bottom panel items. It will also allow the tabs to be rearranged withdrag_to_rearrange_enabled
(only within Bottom Panel at first).Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
TabBar
would have aallow_deselection
(ortoggle_tabs
?) field that when enabled allows no tabs to be selected.When clicking on the current tab,
current_tab
gets set to -1.The
tab_changed
signal should be emitted when this happens.For
TabContainer
, whencurrent_tab
is -1 hide all child's content.If this enhancement will not be used often, can it be worked around with a few lines of script?
Not really, you would have to re-implement
TabBar
.Is there a reason why this should be core and not an add-on in the asset library?
It's for the editor.
The text was updated successfully, but these errors were encountered: