-
-
Notifications
You must be signed in to change notification settings - Fork 620
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]: use_xft = true
breaks window sizing
#1528
Comments
Currently it breaks everything lua based on my machine brndnmtthws/conky#1528 Still manually use it for the main config though
Currently it breaks everything lua based on my machine brndnmtthws/conky#1528 Still manually use it for the main config though
My guess was that font size (glyph width) gets used for window width calculation somehow, but that's not the case. Closing for now as I can't reproduce (Openbox) with:
Not sure if I'm missing something, but Reopen the issue if you still have it and add which WM you're using. |
Nvm, reopening the issue, you can close it if it's fixed. Try it with minimal example so we can tell whether something else is at play as well (templates?). |
I believe I found what causes this. In configure event handler there's this: int mw = surface->dpi_scale(maximum_width.get(*state));
if (text_width > mw && mw > 0) { text_width = mw; } I don't think expected width in pixels should be affected by DPI. So even though it doesn't affect
int display_output_x11::dpi_scale(int value) {
#if defined(BUILD_XFT)
if (use_xft.get(*state) && xft_dpi > 0) {
return (value * xft_dpi + (value > 0 ? 48 : -48)) / 96;
} else {
return value;
}
#else /* defined(BUILD_XFT) */
return value;
#endif /* defined(BUILD_XFT) */
} There's a few things that might be improved:
... and there I was, eagerly closing issues 😨 |
Let me know if the issue needs to be reopened. I believe the linked PR fixes it. |
What happened?
Window sizing is smaller when
use_xft = true
is set then when it is not, if a window is a forced size with min_width and max_width being the same then the window size will be slightly smaller then that.This first image is with
use_xft=true
the colored temperature shape should be centeredThis second shot is showing everything working properly with it disabled
Issue is seen running a few day old version of conky from git on openSUSE Tumbleweed
Version
git
Which OS/distro are you seeing the problem on?
Linux (other)
Conky config
Stack trace
No response
Relevant log output
No response
The text was updated successfully, but these errors were encountered: