n4n0GH / hello

the complete KDE theme
219 stars 26 forks source link

[BUG] Small buttons are too big on a 123DPI screen when used with small titlebar. Regular sizes seem to be to big in general. #42

Closed ghost closed 4 years ago

ghost commented 4 years ago

Describe the bug See title. The simplest fix would be to be able to specify button size and titlebar height in pixels, and not as preset. My system DPI are set by specifying panel dimensions in xorg.conf.d. No scaling/fractional scaling settings within KDE system settings.

/etc/X11/xorg.conf.d/20-monitor.conf

Section "Monitor" Identifier "DisplayPort-0" DisplaySize 526.85 296.35 # In millimeters EndSection

The monitor used is an Agon AG241QX 24'' 2560x1440.

Additional files Titlebars

n4n0GH commented 4 years ago

So first of all, this is behaviour I was aiming for; the pixel dimensions are exactly the same on macOS Mojave, where the buttons are 24px in width and height. Since macOS uses a scaling method to "shrink" the rendered view, the buttons will appear as 12px instead. I might have to actually move to a direct number input instead of a dropdown selector so this can be fine-tuned on other DPI settings. I really don't wanna though because inputs are ugly. But oh well if it can't be helped.

ghost commented 4 years ago

Thanks a lot! I really appreciate it.

n4n0GH commented 4 years ago

Can you pull the newest version (see 6393828) and check if that works on your DPI settings?

ghost commented 4 years ago

Works nearly perfectly, but also introduced a bug with font rendering. When resizing the window, the titlebar font suddenly renders correctly. Can you pixellize corner radius and titlebar height (regular still seems to big) settings aswell?

Titlebar_font_rendering_error

Titlebars2

n4n0GH commented 4 years ago

Can you pixellize corner radius and titlebar height (regular still seems to big) settings aswell?

Yes, absolutely. Was going to do that once you confirmed that the button stuff worked out for you. Thanks for checking it out so far.

n4n0GH commented 4 years ago

@Kiffmet Please try again with b7bfcc3

ghost commented 4 years ago

Titlebar margin doesn't seem to work correctly. When setting it to 1px, I get a titlebar size that corresponds to the previous "small" setting, but nearly all of the titlebar is the "resize window" handle. The handle for moving the window is 1px in size. When setting the titlebar margin to 8px, I get the following result:

Screenshot_20191206_154638

Window corner rounding seems to work fine.

n4n0GH commented 4 years ago

I'm unable to reproduce your issue. No matter my settings, the resize handle is only formed when hovering over or on the outside of the window.

ghost commented 4 years ago

I can confirm that it works as intended when I remove my 20-monitor.conf. If you start your xserver with the "-dpi 124" option, you should be able to reproduce the issue. Edit your ssdm.conf/lightdm.conf or the appropriate file for your display manager for that. The funny thing is, that the titlebar did not do that, when it was still using presets, maybe that's a useful hint for you.

n4n0GH commented 4 years ago

The funny thing is, that the titlebar did not do that, when it was still using presets, maybe that's a useful hint for you.

That's odd indeed, seeing how I just changed the source of the number being used in some functions. I need to check out if the type was different before (it's using qreal now). Then again I also didn't change the way the "?" icon was drawn from how Breeze does it and it still bugged out #3 :^)

Also thanks for the hint how to debug for hidpi myself. Will try that out on a seperate machine I'll be setting up for cross checks.

n4n0GH commented 4 years ago

Closing this as I most likely won't be working on this any further (see 5f57998e).