Bug 157153 - No subpixel smoothing in LO 7.6 (regression)
Summary: No subpixel smoothing in LO 7.6 (regression)
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.6.0.3 release
Hardware: x86-64 (AMD64) Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-09-08 11:06 UTC by anixxsus
Modified: 2024-05-25 09:20 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments
Skia is off, sheet smoothing is greyscale only. (26.17 KB, image/png)
2023-09-09 01:20 UTC, anixxsus
Details
Dialog. Skia is off, font is good (24.41 KB, image/png)
2023-09-09 01:22 UTC, anixxsus
Details
Skia is on. Font on sheet is OK, but font in menu is smeared (28.64 KB, image/png)
2023-09-09 01:27 UTC, anixxsus
Details
Skia is on. Dialog. (26.65 KB, image/png)
2023-09-09 01:28 UTC, anixxsus
Details
Scale: 50%. Skia is off. Text on sheet is barely readable due to greyscale smoothing. (30.47 KB, image/png)
2023-09-09 01:33 UTC, anixxsus
Details
Example file (10.42 KB, application/vnd.oasis.opendocument.spreadsheet)
2023-09-26 07:36 UTC, Buovjaga
Details

Note You need to log in before you can comment on or make changes to this bug.
Description anixxsus 2023-09-08 11:06:35 UTC
Description:
I have just updated from LibreOffice 7.3 to LO 7.6.0.3.

I was stunned that all my Calc tables are just not readable (I have scale setting below 100% so to see greater area). The problem is absense of subpixel hinting, only greyscae is enabled. Skia is off both before and after the update, as it makes things worse (not only the fonts on the sheet but also in the interface become bad).


Steps to Reproduce:
Open any sheet with text

Actual Results:
Small text is unreadable, big text looks awful

Expected Results:
At least as good as on version 7.3


Reproducible: Always


User Profile Reset: No

Additional Info:
Version: 7.6.0.3 (X86_64) / LibreOffice Community
Build ID: 69edd8b8ebc41d00b4de3915dc82f8f0fc3b6265
CPU threads: 4; OS: Windows 10.0 Build 22000; UI render: default; VCL: win
Locale: ru-RU (ru_RU); UI: ru-RU
Calc: CL threaded
Comment 1 anixxsus 2023-09-08 11:55:41 UTC
I want to add that the fonts in the interface are perfect, the problem is only with the fonts on the sheet.

If Skia is enabled, the font on the sheet becomes better and subpixelrendering gets enabled, but at the same time it gets disabled in dialogs and also the font in menus becomes worse.

So, without skia: sheet-no subpixel, dialogs-subpixel
With skia: sheet-subpixel, dialogs-no subpixel
Comment 2 Rafael Lima 2023-09-08 18:36:36 UTC
Can you share a screenshot of the problem?

What fonts are you using?
Comment 3 anixxsus 2023-09-09 01:20:27 UTC
Created attachment 189447 [details]
Skia is off, sheet smoothing is greyscale only.

Skia is off, sheet smoothing is greyscale only. Font:Tahoma. Interface font is perfect.
Comment 4 anixxsus 2023-09-09 01:22:22 UTC
Created attachment 189448 [details]
Dialog. Skia is off, font is good
Comment 5 anixxsus 2023-09-09 01:27:09 UTC
Created attachment 189450 [details]
Skia is on. Font on sheet is OK, but font in menu is smeared

Skia is on. Font on sheet is OK, but font in menu is smeared. Font in input fields and line numbers is greyscale-only. The buttons have visual defects (dots in right-bottom corner).
Comment 6 anixxsus 2023-09-09 01:28:50 UTC
Created attachment 189451 [details]
Skia is on. Dialog.

Skia is on. Font in dialog is greyscale-only, absolutely awful.
Comment 7 anixxsus 2023-09-09 01:33:13 UTC
Created attachment 189452 [details]
Scale: 50%. Skia is off. Text on sheet is barely readable due to greyscale smoothing.
Comment 8 Buovjaga 2023-09-26 07:36:29 UTC
Created attachment 189823 [details]
Example file

As we don't have the document seen in the screenshots, I added a couple of words from it while setting zoom level to 75% and style to Tahoma 10pt. Comparing different versions between 7.3 and 24.2, I see differences, but nothing that I would call better than the other.
Comment 9 anixxsus 2023-09-26 08:48:15 UTC
The difference is in greyscale smoothing versus subpixel smoothing. In the newer versions there is simply no subpixel smoothing. It is switched off.
Comment 10 Stéphane Guillou (stragu) 2023-09-27 23:13:31 UTC
anixxsus, are you maybe able to test versions 7.4 and 7.5 as well to figure out when it all started?
Comment 11 anixxsus 2023-09-28 04:11:46 UTC
It started in version 7.4. It was announced that font rendering was changed.

Somewhat paradoxically they used the term "subpixel font rendering" to mean something different (an close to opposite) of what this term usually means. This is the post that announces this controversial change using this confusing terminology:
https://adamfontenot.com/post/libreoffice_7.4_has_a_new_approach_to_text_rendering

What they did, they made the font lines positioning not to strictly align with pixels (which was the previous behavior) which helps to avoid some bad situations where some letters fuse (like r and n in "rn" looking like "m"). But it makes the fonts more blurry. Plus, they disabled the subpixel font smoothing, that is using subpixels to increase horizontal resolution thrice (which is standard terminology).

In the post linked above it is evident that the new rendering overall looks much worse, but some issues with letter fusing as in "rn" are indeed solved.

My suggestion to solve the issue in our current situation is either add an option to revert the behavior to pre-7.4 version, or the following.

* Sheet font rendering with Skia is good now, it uses subpixel smoothing

* But using Skia makes fonts in dialogs and menus look bad and the buttons of the theme corrupted (garbage pixels in the bottom right corners of buttons)

A solution could be to use Skia for sheet rendering but render everything else without Skia. This solves all the issues.
Comment 12 Adam Fontenot 2023-09-28 11:58:01 UTC
(In reply to anixxsus from comment #11)
> Somewhat paradoxically they used the term "subpixel font rendering" to mean
> something different (an close to opposite) of what this term usually means.
> This is the post that announces this controversial change using this
> confusing terminology:
> https://adamfontenot.com/post/libreoffice_7.
> 4_has_a_new_approach_to_text_rendering

Hi, I wrote the linked blog post. For clarification I'm not affiliated with TDF nor did I write the code for this change. I was simply enthusiastic about it and couldn't find any discussion elsewhere.

I'm a little confused about your complaint regarding terminology. To clarify, "sub-pixel rendering" usually refers to sub-pixel anti-aliasing, which you are calling "subpixel font smoothing". [1] This is unrelated to the change in 7.4, which involves subpixel font *positioning*. This is when anti-aliasing capabilities (whether RGB or grayscale) are used to align glyphs more precisely with their true location as specified by the font metrics, rather than locking them to a single position relative to the screen pixels.

But I don't want to bicker about terminology, since it's not relevant to this report.

> But it makes the fonts more blurry.

It's possible that enabling sub-pixel positioning could make some fonts slightly more blurry, but I don't believe this is expected to be true in the general case. The extremely heavy hinting that Tahoma uses could be the source of some issues.

> Plus, they disabled the subpixel font
> smoothing, that is using subpixels to increase horizontal resolution thrice
> (which is standard terminology).

This indicates to me that the issue you are facing was probably not an intentional change in 7.4 and may not be related to the sub-pixel positioning change at all. That's because my platform (which doesn't use Skia) continues to display sub-pixel anti-aliasing (this is actually visible in the blog post's screenshots).

I wonder if your issue could be caused by a change in anti-aliasing behavior at small rendering sizes. You might check Options -> LibreOffice -> View, and decrease the value for the minimum screen font anti-aliasing (the default seems to be 8 pixels). Do you see sub-pixel anti-aliasing when you change your zoom level to 100% or 150%? Just a guess.

> In the post linked above it is evident that the new rendering overall looks
> much worse, but some issues with letter fusing as in "rn" are indeed solved.

I strongly disagree, of course. :-)


[1] I believe Microsoft uses the language of "smoothing" when describing their ClearType feature, which may have led to this confusion. Most experts writing in this space (as well as Wikipedia) call it sub-pixel rendering or sub-pixel anti-aliasing. Personally, I don't like using the "rendering" term (and mention this in the blog post) precisely because it's irritatingly ambiguous.