-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add option to toggle toolbars visibility #2426
Conversation
@ccordoba12, @Nodd what would the expected behavior be after a shutdown? I think it makes sense to "toggle" as in, if 5 toolbars were on then the toggle will make those (and only those 5) visible/invisible. My question is... what should be done on startup if all toolbars are invisible? should I keep track of the last set of toolbars that was visible before the disable? or should we just grey out the toggle visibility option if all toolbars are off after a start? |
Comments @spyder-ide/core-developers ?
|
Yeah we could keep track of the current/previously visible toolbars, and toggle would bring back the previous known state, that seems intuitive. |
👍 |
@@ -192,7 +192,9 @@ def is_ubuntu(): | |||
'use_custom_margin': True, | |||
'custom_margin': 0, | |||
'show_internal_console_if_traceback': True, | |||
'check_updates_on_startup': True | |||
'check_updates_on_startup': True, | |||
'last_visible_toolbars': [], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This options is transient, so there's no need to add to it here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I keep forgetting that!
Ok, first review done. |
I have to add some docstrings still but I fixed all of your comments and now instead of toggling, it uses a trigger (like |
@ccordoba12 updated docstrings! |
@@ -484,6 +485,7 @@ def is_ubuntu(): | |||
'_/save current layout': "Shift+Alt+S", | |||
'_/toggle default layout': "Shift+Alt+Home", | |||
'_/layout preferences': "Shift+Alt+P", | |||
'_/show toolbars': "Alt+Shift+T", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@goanpeca, can you confirm that this working for you? I remember you told me there was some problem with this change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I checked, it works
Add option to toggle toolbars visibility
Related to #2353
Description
Adds a toggle toolbars visibility button on view menu. Visibility on (action checked) visibility off (action unchecekd).
The last visible toolbars are updated only when using the toggle action.
Todo
Ctrl+Shift+T
)