Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

MacOS have always had the best font rendering on HiDPI screens and also the worst on Low-DPI.

Windows is historically very good on Low-DPI but they also managed to be great on HiDPI.

Linux, well, it depends on so much things … you can achieve good on both but you’d better be ok with integer scaling and not have multiple displays with different DPI.



Macs used to have good font rendering on Low-DPI displays (I would say the best, but I suppose that’s a matter of opinion)

Then Mojave switched to Metal and removed subpixel AA, and now it’s the worst.

Thread from when it happened: https://news.ycombinator.com/item?id=17476873


It's funny to read that thread (from 6 years ago, wow time flies) and see complaints that a lot of people have low-dpi external displays. But I think some of the rebuttal comments in that article rang true even then, and certainly do now: if you are spending money on an Apple laptop or workstation, Apple is going to expect you to spend money on hi-dpi external monitors.


I'll reiterate a comment I made elsewhere in this thread. With my vision corrected, 4k at 24" (~190ppi) needs subpixel rendering for crisp fonts. I would expect 5k at 27" or 6k at 32" (both around ~215ppi) would be the same, so my only option for comfortable external use with a Mac is really 8k at 32". I know that I am an outlier as I get my vision corrected with glasses/contacts to better than 20/20 (outside that 5%-95% group I guess), but I was perfectly well served by subpixel rendering (and continue to be).

Luckily, Mac is only for work, and it is passable with 32" at 4k, but I can use Linux everywhere else for much nicer fonts. Unluckily, work is 8+h :)


Sounds like you need to get a new job where you can use Linux. (For reference, I'm typing this at work, on a Linux laptop.)


Maybe :)


Yeah, the issue is that 6 years ago your only option for a highdpi monitor with the correct scale (e.g. for 27'' it needs to be 5k, not 4k) would be the iMac or the XDR display that costs over $5k...

Now that Apple sells their own (very decent) monitor at somewhat more affordable price it makes sense to use it as an external display, I agree.


> MacOS have always had the best font rendering on HiDPI screens and also the worst on Low-DPI.

No it hasn't.

Maybe to you "always" means "since 2014" but if so that means you are very young and you should not generalise from that.

I've been using Macs since 1988 and Mac OS X since 2001 and it used to be great on SD screens. I used to use Safari on Windows XP because its font rendering was so much better than the built-in Windows Truetype renderer.

This change is new and recent.

It is absolutely not "always".


You can have displays with different DPI on Linux and achieve good font rendering. But it requires the latest versions of your favourite DE (like GNOME 45+ and KDE 6.x) and you'd need to give up X11 (which does not support mixed DPI very well).


X11 handles mixed DPI fine. Monitor configuration GUI for DE don't support the required option however both X and nvidia-settings do


X11 quite literally doesn't have the notion of DPI, there is only a single coordinate space. Xrandr is per-output and not per-window.


I'm literally sitting at a station with 3 monitors 2 high DPI and 1 low DPI wherein UI elements of a window moved from one monitor to the other are identically sized and this was the case when all 3 monitors were different sizes and DPI as well.

In this case the UI is scaled up by an integer factor on all screens so as to look nice on the highest DPI screen. It is scaled down from the higher resolution by a decimal factor that could be but needn't be an integer. If the factor is proportional to the difference in DPI the result is UI elements being sized precisely the same size across different size and dpi monitors.

All monitors share a singular scaling factor and DPI. Apps thus need to support high DPI but needn't do anything smart to support scaling because it happens outside of the apps remit.

This can be achieved again with xrandr --scale OR in the nvidia-settings GUI by setting viewport in to a higher resolution than viewport out. No the result isn't blurry.


First thing first, the X11 protocol is not aware of DPI. Period. And that has implications. You can apply all sorts of hackish solutions on top of it but (1) the solutions will most likely be out-of-band (not pure X11) and involve DBus/envvars/Xft.dpi, and (2) per-output.

Out-of-band solutions are effectively bandaids and they unnecessarily increase development difficulty of GUI programs on Linux, since developers now have to be aware of the various side channels (fragmentation!) that communicate the DPI scale.

This is why SDL2 for the longest period did not support HiDPI on X11, but does on Wayland, MacOS, and Windows. A COSMIC dev just recently made a complaint about XSettings too! [0] You can't just ignore those problems, "Linux is hard to develop for, blah blah fragmentation blah blah" I am sure you have heard of.

Another thing. Per-output HiDPI is fine when all your programs support high DPI, but it's unworkable if you want to mix LoDPI and HiDPI applications in a single screen, i.e. if an application has better user experience if it is upscaled and blurry (!), you are SOL unless you want to apply scaling to your entire desktop.

You also lose the opportunity to implement some neat features like temporarily scaling up a window if it is being magnified or screenshot. (The idea's been floating about in the KDE community)

Finally, we can argue for days, but the HiDPI page on Arch wiki already says a lot when a good 90% of the article is about acheiving good DPI scaling on X11 [1]. Even the Wayland sections have an XWayland subsection in them...

[0]: https://tech.lgbt/@drakulix/113029499719670970

[1]: https://wiki.archlinux.org/title/HiDPI#Xorg


Scaling is a built in feature of X for over 20 years intended for this use case no bandaids of any sort or awareness by the applications of differing DPI.

From the perspective of apps there is only one DPI with all scaling down handled by X at a layer below the apps level. There really aren't any lodpi apps on a modern X system only Wayland has issues scaling X apps correctly. Gtk Apps not updated this decade can handle scaling up by integer factors and because X scales the lower dpi monitor down to the appropriate size the app doesn't need to handle anything else.

Its very odd for folks to argue that my mixed DPI system using only basic boring old xorg.conf somehow doesn't exist. I mean would you like to come to my apartment and open a few different apps?

Its in a way ironic that between pure X, pure Wayland, and Wayland + xwayland only the last can't handle mixed DPI.


> There really aren't any lodpi apps on a modern X system only Wayland has issues scaling X apps correctly.

The problem starts at XWayland, not Wayland. And XWayland is just your typical X server with all its X intricacies.

Only if we can somehow communicate our intended scale to the X clients through XWayland... oh, we can't!

> Its very odd for folks to argue that my mixed DPI system using only basic boring old xorg.conf somehow doesn't exist.

You keep on confusing per-window and per-output DPI. I can only assume you are feigning ignorance at this point. Good luck with attitude.

I still have a couple GTK2 apps installed that doesn't support HiDPI, those are best used upscaled but... they can't. Those apps are unable to communicate to the server they are rendered at 1x (rather, the server doesn't have the notion of per-window scales at all).


The desirable quantity is the result not the mechanics specifically that one can simply open windows on any display and move them between monitors without worrying about scaling. Ideally an element on one ought to be the same number of mm should you pull out a ruler.

This is easily achievable on X11 and its easily done with Wayland.

You mentioned not being able to do scaling per window. Well only with xwayland do you ever need to do so. You need it to be smarter than it is and so scaling on xwayland sucks in a way that isn't a factor in X or Wayland.

Since Wayland is dependant on xwayland for unsupported apps and mixed DPI + xwayland sucks effectively only Wayland sucks at mixed DPI.


Sigh.

> The desirable quantity is the result not the mechanics specifically that one can simply open windows on any display and move them between monitors without worrying about scaling.

Then next time don't bring up compatibility when you talk about the benefits of staying on X11. :) You are breaking the legacy programs anyway by forcing LoDPI programs to remain un-upscaled and therefore unusable on HiDPI displays.

> Well only with xwayland do you ever need to do so.

I am sorry, but the problem I mentioned exists as well on a pure X11 setup.

And the "solution" for this problem, on this setup, is to scale up the entire desktop (blurriness everywhere) which is decidedly worse than XWayland where only a single window is affected, assuming your other HiDPI-aware programs run natively on Wayland (which, from my experience, is pretty much true -- after all, HiDPI programs most likely are still actively developed).

The only other viable choice on a pure-X11 setup is a non-solution: just live with the tiny UI whenever you are using HiDPI-unaware programs.

Either you bring up documentation showing people that X11 has something akin to Wayland's buffer_scale event, or consider this discussion finished. It is tiring to talk to a brick wall.


>The only other viable choice on a pure-X11 setup is a non-solution: just live with the tiny UI whenever you are using HiDPI-unaware programs.

What programs? Something from 2003? There are a plethora of X only apps but a microscopic number at this point that aren't suitable for hidpi.

> blurriness everywhere

Nope I'm sorry I have a machine on my desk which disagrees


>Nope I'm sorry I have a machine on my desk which disagrees

I said Mixed DPI. You don't have a low DPI program running next to a high DPI program on your desktop right now, do you?

See, that's why I said you have been feigning ignorance.

And I don't blame you, ignorance is bliss! :D


Please try to read this honestly I promise I'm not screwing with you or misunderstanding.

Outside of this conversation mixed DPI for about 20 years has meant having more than one output of substantially differing DPI most commonly 4K + 1080p.

X11

Under X11 the idea of low DPI applications doesn't exist because broadly speaking every toolkit under the sun supporting integer scaling to deal with this common case about 15 years ago. Individual apps further cannot not support viewport scaling either because it happens at a layer out of scope of the application.

To test I did a search for gtk2 and loaded up fsv a gtk2 port of file system visualizer copyright 1999. It and the QT6 apps released last month I have all appear correctly scaled across high and low and high dpi monitors. The bugaboo of "low dpi apps" just flat out doesn't exist. Read that again if it doesn't make sense.

Wayland

Now leaving the Kindom of X the specter of low DPI apps appears. Suddenly instead of a unified identically scaled virtual space we have little isolated X kingdoms sprinkled inside of wayland space like pimples on a dogs ass. Because we are no longer playing at scaling in them down outside the apps purview the app must now explicitly support scaling and behold the only low DPI apps on the Linux ecosystem hath appeared!

ONLY WAYLAND HAS LOW DPI APPS

Worse its users mostly gnome users smugly assume that X users suffer from problems only they have but worse.

Remember GTK2 app from 1999 on 4K monitor, QT6 app from 2024 on 1080p monitor no manual adjustment perfect scaling. Put them side by side on the 4K perfect scaling. No farking about with anything ever.


Does it have anything to do with DPI? I thought basically the state is Windows rules, MacOS and Linux suck on non-integer scaling ratios. For integer nobody has problems AFAIK.


X has supported scaling forever. Integer scale up everything scale down the lower DPI monitor or monitors.

xrandr --scale, xorg.conf, or nvidia-settings GUI and save to xorg config




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: