[Webkit-unassigned] [Bug 176995] New: [Harfbuzz] Material icons not rendered correctly when using the web font
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Sep 15 05:31:04 PDT 2017
https://bugs.webkit.org/show_bug.cgi?id=176995
Bug ID: 176995
Summary: [Harfbuzz] Material icons not rendered correctly when
using the web font
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Keywords: Gtk
Severity: Normal
Priority: P2
Component: Platform
Assignee: webkit-unassigned at lists.webkit.org
Reporter: cgarcia at igalia.com
CC: bugs-noreply at webkitgtk.org, mcatanzaro at igalia.com
You can see it here:
https://material.io/icons/
Only a few of them are correctly rendered and some others are wrong. We only render correctly the ones that doesn't have an underscore in its name (or that start with a number like 3d_rotation. In the cases where the name before the underscore is also an icon, we render that icon instead, that's why some of them are wrong. This is happening because the underscore is causing the HarfbuffShaper to split the text in 3 runs, one for the word before the underscore, another one for the underscore and another one for the word after the underscore. So, we end up trying to shape the 3 runs independently and we fail when the icon doesn't exist, or when it exists but it's not the one we are looking for. The cause of this is that the underscore has a different script (Common) than the rest of characters (Latin) which is a condition in HarfbuffShaper to create a different run. The unicode spec says that characters with Common script should be handled differently, but we are just ignoring it. The spec proposes to use an heuristic based on simply inheriting the script of the previous character which should work in most of the cases. We could take a more conservative approach and do that only if both character are ASCII. We should also consider handling other cases mentioned by the spec like brackets and quotation marks, but that belongs to a different bug/commit.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20170915/f415d648/attachment.html>
More information about the webkit-unassigned
mailing list