-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Enable Mixxx's HDPI scaling for all versions QT < 5.6 #1741
Conversation
We should be removing this hack, not re-enabling it. |
We can also use the preferences to set |
Which to me signals that Qt did not intend for applications to present this option to users. |
It is not that uncommon to deal with it inside the application |
Looking through those search results, I see lots of hacks for legacy Qt versions before the current API was introduced in Qt 5.6. Other search results look like hacks for specific devices and OS's and many are commented out. |
works as before, thx! |
There is an other use case for scaling, berry small screens: Can we merge this? |
No. Again, this hack should be removed. I don't think scaling should be exposed to users at all by applications, but if it is, the most appropriate way would be using Qt's scaling, not maintaining this elaborate hack for Qt4. |
Remember: It is for Qt < 5.6 and we have no usable scaling solution for ≥ 5.6. |
Going in circles discussing minimum Qt versions repeatedly on different PRs is not productive. If you want to propose supporting outdated systems, please take the discussion to Zulip. |
Even with a working automatic scaling solution, I think there are use cases where it's helpful to override:
|
Ok, so we need a preferences option for ≥ 5.6 as well. |
I also think it's best not to try to override OS settings with our own. For users with edge case screen sizes, they should be setting up their OS to their liking and Mixxx should respect those settings. If there are cases where the OS settings are truly broken, then I think it's ok to add new preferences as a workaround, with the expectation that we'd prefer to remove them once the OS is working correctly. We should only be doing things like setting "QApplication::setAttribute(Qt::AA_EnableHighDpiScaling)" if we detect the OS has highdpi enabled. |
IIUC this code already won't do anything on non-high DPI screens. I don't think there's a need to enable it conditionally. |
Btw could someone explain |
Using Qt's scaling scales the entire GUI. Keeping this big pile of hacks for Qt4 does not scale everything, for example positioning in QSS files or arrows on spinboxes. With Qt's scaling there should be no need for skin designers to test at different scale factors once we fix the scaling issue we identified in #1772. If you do want to test anyway, you can set the QT_SCREEN_SCALE_FACTORS environment variable. |
Echoing what @Be-ing said, when the OS is in charge of doing the scaling it should be completely transparent to the application. Everything should be expanded equally and it shouldn't require any extra work. There has been a lot of work in browsers and OSes for converting virtual numbers in CSS files like "10px" into physical pixel values that may be totally different. That does explain why a minimum skin size of 1300x768 (or whatever) may not fit on a HiDPI screen - those are virtual pixel values that may get multiplied. |
Ok, I understand the arguments not messing arround with the os/qt scaling, but I also see some convenient points and use cases to have scaling options in the preferences. Unlike in preferences Mixxx does not use the standard Os widgets in the skin it is here more comparable to a web side, where scaling is a major feature of the browser. How does the still enabled scaling of the library to this topic? Following the arguments to rely on the Os settings, this should also follow the Os text size settings. The latest discussion is however a bit off topic because in the current state this PR fixes only a regression for Ubuntu Xenial and other < Qt 5.6 distros. So I think we can merge this as it is, right? |
Again you are imagining a user who:
I am highly sceptical any such user exists. Even if they do, I think the best way to support them is to tell them to update their OS. The cost of maintaining this elaborate hack that touches every part of the skin code for the sake of someone who can't be bothered to update their OS is IMO not worth it. |
The case I imaging is not that exotic as it looks like from your latest post. I am imaging a user, who
I would like to stop maintaining the 2.1 branch after the 2.2 release. But unfortunately we cannot unconditionally recommend to update to Mixxx 2.2 without this PR because of this group of users. |
It might help to pick a horizon for ubuntu version support and stick to it. We could choose to match Ubuntu's schedule, which supports Xenial in maintenance mode until 2021 (https://www.ubuntu.com/info/release-end-of-life), or we could say that since 18.04 has been released (the new LTS) we can safely drop support for 16.04. This is a tough balance. It can take a lot of energy to support old releases, but Mixxx definitely has a substantial number of users on older, cheaper hardware with older OSes. Given our history of great compatibility with older machines, I'm ok with assuming this kind of edge-case user exists. I think if we come up with a standard support policy it could make these discussions easier. The two main metrics I'm thinking of that come up a lot are screen size and OS version support. If we can write down a policy on the wiki then that will also help our users know what we're committed to supporting. |
(In general, it's better to have written project policies than forcing everyone to rely on their memory of past discussions, or finding old email threads. I think it would be nice to have a goal of creating documents based on the output of the arguments that we have.) |
I agree, I would rather have a consistent policy than drain my energy on ad-hoc discussions repeatedly on different PRs. The discussion is here on Zulip. I have opened #1777 to elucidate the cost of merging this PR. |
So what hat to do here. from our latest discussions it turns out that Xenial is among the supported distros. Without it we loose the HiDpi capability. |
Ubuntu 16.04 users can still set the QT_DEVICE_PIXEL_RATIO environment variable with Qt 5.5. Or they can upgrade to 18.04. I do not think there is a need to merge this. |
Is that the case with all waveform renderers? |
Only GL and GLSL renderer are effected. The Spinny is always effected. |
Another PR in an unclear state. Please close or update it. |
I am in favor of closing this. Maintaining a legacy hack for a 4 year old OS for hypothetical users who we have no evidence of existing in the first place makes no sense to me. |
OK, since this seams to be an unwanted change we can close this. A more important change would be to remove the requirement to deal with environment variables. |
This brings back Mixxx's own scaling solution for Ubuntu Trusty and Xenial.
Discussed in #1521