-
Notifications
You must be signed in to change notification settings - Fork 286
UI Feature: Custom Titlebar #1913
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
chchwy
reviewed
Jun 3, 2025
chchwy
reviewed
Jun 3, 2025
chchwy
reviewed
Jun 3, 2025
chchwy
reviewed
Jun 3, 2025
chchwy
reviewed
Jun 3, 2025
chchwy
reviewed
Jun 3, 2025
chchwy
reviewed
Jun 3, 2025
As the menu items are not able to switch between normal/active state currently
The example here is that if we use it's min layout size, then it will override the min size of for example the toolbox.
9b0951f
to
053a5ee
Compare
chchwy
reviewed
Jun 5, 2025
Apart from the context menu, I don't have further questions. This PR looks good to me. |
Because it might be overkill to have.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What started out as an experiment, has now become a full blown feature. I present to you, our own custom title bar.
A custom title bar gives us more control of the sizing of our widgets, especially in floating mode, as Qt will otherwise favor the OS min dimensions. Normally I wouldn't see this as a problem but the resizing system is Qt is so quirky sometimes that I experience that there are not enough handles to take control of the sizing properly.
With our new custom title bar, this is no longer the case. We are in full control of what we want to show, how it should be sized and what it should look like.
What our current one looks like on each respective platform:
The new one:
The title bar has been built using the standard palette which should make sure that it looks correct on all platforms. I've designed some new icons as well, a normal one, an active one and the same in dark variations.
The most prominent changes can be seen on macOS, especially the dark mode titlebar which was previously shown in a terrible gradient... the icons were not high DPI either.
For the other platforms, the change should be minor. On windows the title bar looks nearly identical except for the icons of course. When I tested the build on Peppermint OS, previously the title bar was more embedded into the widget, where as with the new one the title bar background is as prominent as the other platforms. Personally I think it looks fine that way but I am also not daily driving a Linux distribution. What do you think?
When the title bar becomes too narrow to show both the title and the buttons, it will favor the title and hide the buttons. The buttons can however still be accessed by right-clicking. Although in the right-click menu, there's no animation currently when hovering the items, so it uses the active representation instead.
Visual highlights:

Builds to try:


