snuq/Snu-Photo-Manager

Linux - HiDPI screen text is unreadable, widgets too small

Opened this issue · 8 comments

Gave Snu a try on Linux Mint 19.1. on a Dell 5530. Screen resolution is 3840x2160. I ran the tarball version from the executable download section. Unfortunately everything on the screen is way tool small to read.
image
If I set KIVY_METRICS_DENSITY=2 it scales some of the UI but not all of it:
image

snuq commented

Can you set the button size and text size percentages to 200? Does the interface look appropriate then?
Ill look into the code and see if I can implement a more graceful solution tho, thanks for the report.

Thanks for the speedy reply!

To try your suggestion I had to set KIVY_METRICS_DENSITY=2 and launch SNU. This was the only way I could actually read the settings well enough to figure out which ones to change. On making the change, things were then way too big. Restarting seemed to fix this and things generally looked OK.

The result is the main UI looks generally better. On start the "file browser" at the left is almost completely collapsed. Easy to fix by stretching it out but it reverts to collapsed on restart. Also, the button text overflows the button if it is not extended to its maximum.

Also, if KIVY_METRICS_DENSITY is removed from the environment variables the settings window is now again quite small yet larger than the first time I ran it without making the changes you suggested.

The original purpose of the issue report appears to be resolved with your suggestion. Feel free to close it if you wish.

snuq commented

Hmm, something is definitely weird here tho... I tested it out on a 4k screen in windows, and it looks perfect with the same settings as on 1080.
Does the main interface of the app look half-sized as well, or just the settings screen?

HiDPI screens and linux are fun. I suspect this could be related to how Linux handles HiDPI or reports it to Kivy but I'm not sure.

I just booted from linux into Win10, same resolution as on linux and confirmed that Snu "just works". However, I noticed that Windows has scaling set 250% by default on my set up. I disabled that and things look closer to what I'm seeing on linux but not quite the same. So, it could be a combination of things.

snuq commented

Can you run this app and give me a screenshot:
http://www.snuq.com/temp/screenresolution.tar.gz
It should tell me if kivy is giving an incorrect value for the window size (I'm pretty sure thats the root of the issue).
Sorry for the size of such a simple app, it seems kivy has included all the libraries that I put into the photo manager, geez.

Hah, yeah, it's... big. No problem. Mind sharing the source?

Cropped so you can read it:
image

Full screen:
image

snuq commented

Huh. I am now at a loss, those values are what they should be... I really have no idea why snu photo manager isnt scaling right on your setup...

The app source code is super simple:

from kivy.app import App
from kivy.uix.label import Label
from kivy.core.window import Window
Window.maximize()

class TestLabel(Label):
    def on_size(self, *_):
        self.text = 'Width: '+str(Window.width)+', Height: '+str(Window.height)+', DPI: '+str(Window.dpi)

class Test(App):
    def build(self):
        return TestLabel()

if __name__ == '__main__':
    Test().run()

Yep, about as simple as it gets!

Thanks for checking!