Hacker News new | ask | show | jobs
by KronisLV 629 days ago
Off: https://blog.aktsbot.in/img/stem-darkening-off.png

On: https://blog.aktsbot.in/img/stem-darkening-on.png

Personally, I never had issues with fonts on any OS that much except when I connected my M1 MacBook to a 1080p monitor, then it felt like the fonts had no anti-aliasing at all.

3 comments

That’s because MacOS got rid of subpixel antialiasing sometime after launching Retina screens, which makes non-hiDPI screens have quite awful font rendering.

I sometimes switch to a bitmap font like Fixedsys Excelsior or GNU Unifont when using MacOS with a low-resolution monitor to compensate (with antialiasing off so the bitmap font looks crisp).

Also, JetBrains Mono somehow looks good on lowres screens even though it’s not a bitmap font, it seems to not blur as much as other fonts when it gets antialiased.

Subpixel antialiasing is going to be problematic anyway on newer displays that don't necessarily feature a plain RGBRGB (or similar) subpixel arrangement. For example, many OLED screens use RGBG/BGRG or even more complex "PenTile" subpixels.
> Subpixel antialiasing is going to be problematic anyway on newer displays that don't necessarily feature a plain RGBRGB (or similar) subpixel arrangement.

This will then mean making the subpixel anti-aliasing algorithm aware of different subpixel layouts. And this ought to be done anyway, because most anti-aliasing is usually at least somewhat hardware-aware. In my opinion, regardless of how subpixels are laid out, more resolution is always better.

There was a quick option to change subpixel layout way-back-when in Linux (GNOME 2.x series), eg. a quick search gave me a screenshot at this page: https://askubuntu.com/questions/88528/how-to-switch-on-sub-p...

Today it seems it's hidden as a dconf option:

  $ dconf read /org/gnome/desktop/interface/font-antialiasing
  'rgba'
But this is an issue that applies to VA panels as well (cheaper than IPS, worse viewing angles, but better contrast ratio), and I have a 27" 4k VA screen that works just fine with it turned on in Linux — text is so much clearer with it on than off, and attaching a MacBook to a 4k screen at 27" or 32" IPS makes me hate MacOS for killing subpixel rendering off.

As for "retina" resolutions, I've tried 24" at 4K as soon as it came out (with that Dell monitor that required 2 DP 1.1 connections for 60Hz IIRC), and turning subpixel rendering off made text and lines jagged — that was ~190 ppi at a normal viewing distance with vision corrected to better than 20/20 (which is what I usually have — can't really work without glasses anyway, and worse correction leaves me with headaches). For the record, 5k at 27" and 6k at 32" is roughly ~216 ppi, so not much better than ~190 ppi: subpixel rendering probably achieves 2x the increase in text clarity for those not sensitive to colour fringing (I am not).

So, subpixel rendering is really not an issue on any displays, but Apple will happily tell you what's the limit of your vision and upsell you on their monitors.

Fontconfig on Linux has an option to set the subpixel layout, though currently only rgb, but, vrgb and vbgr are supported. Maybe this could be extended for OLED monitors
For this Windows had ClearType tuner since before PenTile existed.
The “sometime” happened in macOS Big Sur. Prior to that in Mojave and Catalina, you could enable it back by twiddling a hidden preference with the word “legacy” in it. It somehow was worse than what you got in High Sierra and prior anyway.
Subpixel antialiasing is kind of overrated anyway. On screens that are low enough DPI to benefit from it, it can cause color fringing (especially for people with astigmatism) that is worse than the blur from grayscale antialiasing.
I disagree: I am not susceptible to colour fringing, and I can tell if subpixel rendering is on or off on 24" 4k screens (~190 ppi) at a regular or even further viewing distance (~70cm/27") — I specifically got that display hoping for subpixel rendering to be turned off.

Haven't tried Apple's big "retina" screens but considering they are ~215 ppi, pretty confident 10% increase in PPI wouldn't make a difference that subpixel rendering does. Laptop screens have higher resolution, but haven't really paid attention to whether M1 Air 13" or 4K 14" X1 Carbon work for me without subpixel rendering (I prefer to be docked).

Before anyone jumps on "you've got incredible vision": I wear either glasses or contacts, and with that my vision corrects to better than 20/20 — slightly lower correction induces headaches for me. Without glasses, I'd probably be happy with 640x480 on 32" so they are kind of a must. :)

On medium-DPI screens, I find that subpixel antialiasing make fonts significantly less blurry than grayscale antialiasing without causing obvious color fringing. On actual low-DPI screens, bitmap fonts are IMO the only really usable option. (YMMV, but I have mild astigmatism and use glasses.)
They don't sell anything without hiDPI for quite some time now (a decade?). Making their software look good on obsolete screens is understandably not a priority for them. And if you are happy to plug in something that old, you are kind of signaling that you don't really care about what things look like anyway. So, why bother to make that look good?
> They don't sell anything without hiDPI for quite some time now (a decade?). Making their software look good on obsolete screens is understandably not a priority for them. And if you are happy to plug in something that old, you are kind of signaling that you don't really care about what things look like anyway.

My apologies for buying 1080p monitors that had no issues with neither my Linux, nor my Windows computers, I guess. I can understand that they might not care about what I care about (supporting the hardware that I have, rather than going out of my way to buy a new monitor just because of a new computer deciding not to work with it well), I'd argue that maybe that's even fine because it's their device and ecosystem, but jeez, that tone is super uncalled for.

As an aside, I use the M1 MacBook at a scaled resolution of 1440x900 because anything finer is hard for me to see. That's a visible PPI of around ~130 because of the 13.3 inch screen. A 1080p monitor of 21.5 inch diagonal size would have a physical PPI of around ~100, so that's around 80% of the pixel density. That's not to say that the panel on the MacBook is not much nicer, but rather that with software anti-aliasing it could definitely be okay. Somehow I don't want to buy a new monitor just for the weekends when I visit the countryside.

Reality distortion field is strong with this one.

I have a perfectly good normie dpi 25x16 display which is extra crisp on windows. On macOS I had to install betterdisplay just to make it not miserably bad; it’s just plain bad now. As far as I can tell Apple removed the feature because of greed and laziness.

There are plenty of non-hiDPI screens from other vendors on the market, especially “large” screens that are “medium” in price. In an office you’re not always free to order a screen from any vendor you want (due to their framework agreements), unless of course you’re paying for that hardware privately.

I care about how things look, and have spent more time than I want to admit configuring MacOS apps to look good on the screens available to me. I just don’t care enough to buy an expensive office screen with my own cash if my employer can’t provide one.

I was talking about Apple. Apple stopped selling non hiDpi screens some time last decade. T
So in a nutshell:

Apple specifically wants that you cannot use non-apple displays by artificially worsening the experience for the user while strengthening the illusion that Apple's hardware looks better - even though the only reason it does is because Apple themselves made sure to make other displays look unnecessarily bad.

It's hilarious there are people that actually think this is totally okay and not just plain anti-competitive with just enough plausible deniability to get away with it

Well, in a word, no.

In a few more words: not at all, not even slightly.

To explain briefly:

> Apple specifically wants that you cannot use non-apple displays

No. Apple does not make or sell or offer non-HD displays and has not done for over a decade. Apple mainly sells phones and laptops with built-in hiDPI screens. Desktop computers that use external screens are a small part of its range, and it sells its own very high-quality screens for those.

Because font antialiasing is pointless on a hiDPI screen, and it only offers hiDPI screens, it removed antialiasing from its OSes.

However, the kit does still support old screens and you are free to use them. The antialiasing feature is gone, but to my (not very strong) eyesight it doesn't matter and stuff looks fine.

> artificially worsening the experience for the user

No. This is paranoia.

> It's hilarious there are people that actually think this is totally okay

People think it's okay because your interpretation is paranoid.

> not just plain anti-competitive

How is REMOVING features anti-competitive? In what universe does taking something out of your products hurt your competition? That is absurd.

> you don't really care about what things look like anyway.

That statement has no connection to the premise.

There are multiple reasons to use an old screen besides the mentioned reason of not caring for x.

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

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

BetterDisplay HiDPI feature (available on the free version) much improves font rendering on external displays: https://github.com/waydabber/BetterDisplay

This helped me a lot, I was about to ditch my external monitor because of blurriness.