222.16 KB, image/png
224.98 KB, image/png
ensure that subpixel text is disabled for Skia's Cairo font host so that font rendering matches our font metrics
2.34 KB, patch
|Details | Diff | Splinter Review|
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:47.0) Gecko/20100101 Firefox/47.0 Build ID: 20160126143540 Steps to reproduce: I've switched skia instead of cairo in gfx.canvas.azure.backends and gfx.content.azure.backends. Actual results: Fonts get rendered in a weird way: both on pages and FF UI. Most noticeable is that spacing between letters is often uneven. But also it looks like some parts of some letters is shifted to be 'between' pixels making them render only partly. I'm attaching screenshots with skia and cairo on same FF instance. Expected results: Fonts should be rendered properly with cairo enabled
OS: Unspecified → Linux
Hardware: Unspecified → x86_64
Correction: Expected results: Fonts should be rendered properly with _skia_ enabled
The way Skia renders Freetype fonts with subpixel positioning depends on adding in the subpixel offsets before the metrics are then snapped to integral values. Since Cairo does not internally do this offsetting before snapping, our metrics and Skia's would disagree if we enabled it for Cairo. Thus, we have to disable subpixel text for Cairo/Freetype fonts until such time as we can revise our font metric code to not exclusively depend on Cairo.
Assignee: nobody → lsalzman
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Attachment #8723352 - Flags: review?(mchang)
Attachment #8723352 - Flags: review?(mchang) → review+
Comment on attachment 8723352 [details] [diff] [review] ensure that subpixel text is disabled for Skia's Cairo font host so that font rendering matches our font metrics Approval Request Comment [Feature/regressing bug #]: bug 1230357 (46+) [User impact if declined]: If people have enabled Skia content on Linux, they would notice a regression in font positioning. While Skia content is not enabled by default, some people are using it already instead of Cairo. [Describe test coverage new/current, TreeHerder]: mochitest, reftest [Risks and why]: Basically none, since this patch only makes us render fonts on Linux + Skia as we did before bug 1230357 [String/UUID change made/needed]: None
Attachment #8723352 - Flags: approval-mozilla-aurora?
Comment on attachment 8723352 [details] [diff] [review] ensure that subpixel text is disabled for Skia's Cairo font host so that font rendering matches our font metrics Fix for a regression from 46, ok to uplift.
Attachment #8723352 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
This bug is verified fixed on: - 46.0b6-build1 (20160328182534), - 47.0a2 (2016-03-30), - 48.0a1 (2016-03-30), using Ubuntu 14.04 x64 and Ubuntu 12.04 x64.
You need to log in before you can comment on or make changes to this bug.