-
-
Notifications
You must be signed in to change notification settings - Fork 622
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
[Bug]: conky pixel unit isn't scaled by screen DPI #1925
Comments
Ah: the problem seems to be as follows. Between this build and the last (or perhaps the one before last) the handling of (The config I posted lacks those variables: I have them in a separate lua file - or a file that differs across the two PCs at issue.) It seems to me that either the behaviour should be reverted or else users should be made aware of the change. |
It's impossible to make a consistent looking configs if #1877 and #1862 fixed this partially. I just created #1926 as I found another place where It's a bit confusing because we're not using units like |
I made the name of the PR clear (which is referenced in release notes), besides that I'm not sure how we can make it clearer that the behavior changed. Closing this as wontfix because I don't see it as a bug and the introduced changes make conky behave correctly (more in line how other software (e.g. browsers) works). |
Thank you for the responses. So, now and henceforth DPI scaling will not affect I'll go with the 'wontfix' interpretation (as we might call it). Given that situation, I proceed to the following.
You could add a conspicuous comment to the release that made the change. That way, users like me how installed that release (which was either the most recent one or the one before that) will not get a nasty surprise. |
Release notes are generated from PRs. The bug fix PR that changed behavior did say that max width no longer uses DPI in the title, so it was in the release notes. |
My mistake. Apologies. |
I was under the impression browsers changed the size of the logical pixel, just like conky used to do. |
@zygfryd You're right. The exact name for the scaling factor used is Device Pixel Ratio (dPR). Though it's almost a standard practice for websites to set This was necessary because old phones (iPhone) had to make websites smaller to fit the screen, so they reported incorrect screen dimensions to websites/browsers to achieve this effect. Logical dimensions were introduced in order to make (mostly) images behave correctly on different DPI screens. Anywho, I was planning on adding a way of handling different units which would default to something like "logical pixels" if no unit was specified. I see how current behavior could be confusing. While I do believe |
That actually just scales your app 1:1 to the viewport in logical pixels. On a phone it'll mean you'll be working with widths in the 300-400px range, not the physical 1000px+ range. Otherwise the usual method of width breakpoints for responsive design wouldn't work.
Glad to see that. From a user's perspective, it'd be ideal for a conky config to work like it used to in 1.19, that is regardless of monitor density the conky window takes the same, scaled, amount of logical space. Desktop scaling is a decision the user makes and shouldn't be worked around, but respected. If the user wants to work around it, then conky might give the option of overriding the scaling factor it obtains from X11 or Wayland. |
I started work on this, but adding proper units touches a lot of code, and I'll have to write tests. I'm mostly done, just have to update all previous pixel |
Can you try git clone -b revert/dpi-changes git@github.com:brndnmtthws/conky.git test_conky
cmake -S test_conky -B test_conky/build
cmake --build test_conky/build
# run with
./test_conky/build/src/conky <options> |
Rendering looks good: text, bars and graphs seem to be the same size as in 1.19.8. |
#1949 was merged and reverted removal of DPI scaling. I'll implement units as I manage, but this fixes the issue in the meantime.
#1952 was merged and fixes width growth with content.
This is the only thing that's left unaddressed. @zygfryd please check out main and let me know whether the issue is still present. If so, I created a separate branch for testing |
Turns out I was using X11 output on Wayland this whole time.
Couldn't find it, forgot to push it perhaps? |
Yes, pushed now. |
Left alignment results in 3x reserved space (tested by maximizing a window), right alignment results in no reserved space. |
Can we do an intermediate 1.21.3 release with the dpi reverts applied in order to fix the scaling issues in the meantime? |
Thank you for testing it, I appreciate it. Can you just lmk what your DPI is (
I think version bump was merged, it will be released soon. You can build from source in the meantime. |
192 |
I just tested 1.21.3 and now my custom cairo lua conky widgets seem to scale properly. |
Should've been. It's possible some change was missed though because I spread those changes through several commits. |
I fixed it and tested it in the above PR. |
What happened?
I built the latest release and installed it on two computers. On one computer, which has DPI in no sense, all was fine. On the other computer, which has a HiDPI screen and DPI scaling set to times-two, the right-hand half of my Conky is missing. In the previous GitHub release I did not have the problem.
Screenshot:
I have Linux Mint 21.3 Cinnamon.
Version
1.21.1-pre-256ffdb7
Which OS/distro are you seeing the problem on?
Linux (other)
Conky config
Stack trace
No response
Relevant log output
EDITED.
The text was updated successfully, but these errors were encountered: