Re: Current state of DPI settings under X
Pekka Paalanen <[email protected]>
| Newsgroups | gmane.linux.xdg.devel |
|---|---|
| Message-ID | <20170726120040.747eeb66@eldfell> |
On Wed, 26 Jul 2017 11:09:44 +0300 Vladimir Kudrya <[email protected]> wrote: > Imagine a situation: a laptop that is used by itself, or docked at place > A, or docked at place B, frequently moving around. > > In each case there are different display(s) and each configuration has a > comfortable DPI setting (not necessarily matched with physical DPI). Hi, sounds more like scaling factor than DPI, but yes, that is a good and valid goal. > I apply xrandr configuration with needed DPI, some set of programs > conform to this. I publish DPI to xrdb, another set of apps is affected, > finally I configure fontconfig to affect the rest. > > I successfully automated the whole process recently > (https://github.com/Vladimir-csp/rerandr3), it does the job more or > less. But I feel the strong urge to choose 2 sets of apps out of these > 3, declare their behavior as buggy and submit some bug reports, no > matter how futile they may be. I think Thiago is right. Wayland - putting the compositor in charge of scaling, knowing how and if apps scale themselves, and automatically compensating the scale difference - at least offers the framework to solve those things. How well it works depends on the Wayland compositor (DE) you choose. Xwayland still has awkward issues with scaling people are trying to fix, but I believe it is likely it will never become as good as native Wayland apps can, particularly in mixed-dpi setups. You are lucky if you can manage with a single global scaling factor at any time. :-) Thanks, pq > 2017-07-26 09:52, Pekka Paalanen пишет: > > On Tue, 25 Jul 2017 21:15:31 +0300 > > Vladimir Kudrya <[email protected]> wrote: > > > >> Hi all! > >> > >> I would like to know the current 'proper' way of setting DPI in X (if > >> there is any). > >> I see conflicting information on the topic, and different applications > >> seem to have different source of this setting. I currently counted 3 of > >> them: > >> - fontconfig > >> - xrdb > >> - randr > >> > >> Different versions of gtk2 seem to either demand or ignore dpi setting > >> in xrdb. > >> And there is also this recent change that gives xdpyinfo the ability to > >> state different DPI for different outputs simultaneously: > >> https://lists.x.org/archives/xorg-devel/2017-April/053430.html > >> > >> Is there any DE- and toolkit-agnostic approach for letting applications > >> know the proper DPI and/or notifying them that DPI has changed? > > Hi, > > > > rather than asking "how to set the DPI", why do you want to set the > > DPI, what do you hope to accomplish? > > > > Are you looking for making fonts physically the same size on different > > monitors? > > > > Are you trying to cope with HiDPI monitors? > > > > Are you trying to make physical measurement units in applications > > correspond to real physical dimensions on the screen? > > > > Even these are fairly low-level questions and would need an explanation > > on what you are really trying to make to work. Some goals are false to > > begin with, some are reasonable but technically hard, and some have > > existing solutions depending on software. > > > > In general, DPI is a mess, and very often the actual DPI number is > > not even what one should be concerned with. > > > > > > Thanks, > > pq > > _______________________________________________ > xdg mailing list > [email protected] > https://lists.freedesktop.org/mailman/listinfo/xdg _______________________________________________ xdg mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/xdg
signature.asc
(application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEJQjwWQChkWOYOIONI1/ltBGqqqcFAll4WjgACgkQI1/ltBGq qqcldBAAm74F9wpU2zjcd4SP/yfEBErnaI0YtqbHU5n4pqcTs89ya2RctFF9bclQ BuIJocIUsxwM0bliy2f7xLSLuscXRA5eMOKiGfMp8L+XfYhP1hA8R2nr9F+ddR/U u2xIBABkoLxlrZ2Wj4wEXWF6kFcWxK0V8V1w8Bz0Re72iJJEwTeUlmD7XMqfB453 K9uf2cZoyKKQyCqxHYVhO/fsUAPmrWuLq/PwK8PIbEX1VtdATNiGaIpHZOt4n/6y Z3mdH7EBXjY1P4yE1m1apsgjJecvuAAdUG2rxSVC3dCPgnQfnb0njKTzoFcHMyEs 3F7Ul/HfF17Iv0Ak/TIaQVsq8PUdEEBHauiE3uv8t9fQxJ/DVQ3mqAbge7tIMoMa /EEuNBleYuToDdUcUQ/QSiw0pJKHB5WG0kOn5VmgyjPP+i/cB69biS9vff8ZJFhE Mb3SucYPSed9wG5FYiSzG6GMtPUIWq1NIvnFkeOT/PAoSTnOBFIFpnDzs/vS08ap wzsFJfHNVRCtbo5205E38wj443kpNFP7qLkjezsBjzBCCwBJTYyGLd97s2hK/07Y Tn8e5nBjWcyGMUtLFzON7ePrMKURUBRfFLOprwLKqunrz/rTSx/eywuwkzuOsMxX cLA40+gXDQUkHj/+b6QpKvoTlK1fUJvIvUxLM2ZFExE2A+156AI= =dTrQ -----END PGP SIGNATURE-----