-
-
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
PR: Improve style of dockwidget tabbars (UI) #21133
Conversation
237aa79
to
cb95a9f
Compare
cb95a9f
to
cbf8625
Compare
cbf8625
to
a426358
Compare
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.
Thanks @ccordoba12 ! Checking on Windows and seems like is looking as previewed 👍
The only thing that I noticed is that the scroll buttons for the tabs are now bigger. Is that the wanted look, right?:
Before:
After:
Also, just in case, for me the scroll buttons for the pane tabs look like:
Edit: Remembered that there is a setting to change the tabs from horizontal to vertical and checking seems like the custom style here doesn't support it:
Also share that style with PanesTabBarStyleSheet.
a426358
to
b989378
Compare
f58efbc
to
e2c3033
Compare
That's because the PluginMainWidget layout depends now on tabs' orientation, so this option can't be applied on the fly anymore.
@dalthviz, thanks for the review! I think I fixed the errors you found, so please test again. I also made these additional changes:
|
Also, introduce a constant for this and remove hard-coded values
- That margin is not necessary anymore with the new dock tabbar style. - Also improve its placement in the IPython console.
0f84ef9
to
946904e
Compare
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.
Checking this again seems like the tab arrows are now a little bit too small
Ok, I adjusted that size to be similar to the one I'm seeing on Linux. But the nice thing is that it can be changed to be a bit bigger (which can't be done on Linux).
Below I left a comment in the places where I set those values, so please change them and let me know which ones work better for you.
@dalthviz, this should be ready, unless you have more comments about the code. |
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.
Thanks @ccordoba12 for all the work here! I left a question regarding the line commented as a hack but otherwise this LGTM 👍
# TODO: This is a hack! Remove it after migrating to the new API | ||
self.find_widget.layout().setContentsMargins( | ||
2 * MARGIN_SIZE, MARGIN_SIZE, 2 * MARGIN_SIZE, MARGIN_SIZE | ||
) | ||
|
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.
Why this was needed? Are there other changes that need to be done besides removing this line for the migration?
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.
Why this was needed?
Because in this PR I added a bottom margin to all migrated plugins here, so that their borders don't touch the bottom. And by doing that, it was not necessary to add a bottom margin to the Find/Replace widget, so I removed it here.
But since the editor is not migrated, we need to add that margin in the meantime (which is the change you highlighted here). Otherwise the Find/Replace widget would appear touching the bottom.
Are there other changes that need to be done besides removing this line for the migration?
Not from this PR, but I've been documenting other things that need to be removed after the migration with TODOs in spyder/plugins/editor/plugin.py
.
Description of Changes
Dark theme
Light theme
Issue(s) Resolved
Fixes spyder-ide/ux-improvements#4.
Affirmation
By submitting this Pull Request or typing my (user)name below,
I affirm the Developer Certificate of Origin
with respect to all commits and content included in this PR,
and understand I am releasing the same under Spyder's MIT (Expat) license.
I certify the above statement is true and correct: @ccordoba12