Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(828)

Issue 1397423004: Improve shaping segmentation for grapheme cluster based font fallback (Closed)

Created:
5 years, 2 months ago by drott
Modified:
5 years, 2 months ago
Reviewers:
eae, behdad
CC:
chromium-reviews, pdr+graphicswatchlist_chromium.org, drott+blinkwatch_chromium.org, Rik, blink-reviews-platform-graphics_chromium.org, dshwang, jbroman, Justin Novosad, danakj, krit, f(malita), blink-reviews, Stephen Chennney, rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Improve shaping segmentation for grapheme cluster based font fallback Previously our pre-shaping segmentation relied on GlyphPageTreeNode for several different criteria of text segmentation: the font to be used, upright orientation in vertical text, and small caps behavior. Also, the pre-shaping stage of script run resolution did not handle braces and created an extra vector of runs, instead of resolving script runs incrementally. As a preparation to this change, ScriptRunIterator, OrientationIterator, SmallCapsIterator and a RunSegmenter have been introduced to isolate the run segmentation. Using RunSegmenter, we can now shape font by font, iterating over the fonts using a newly introduced FontFallbackIterator. FontFallbackIterator takes care of providing the shaper with the available fonts, as specified by CSS, user preference and system fallback. The new approach is to let the shaper shape as much as possible of the current segment, then identify the .notdef sequences. The sequences of .notdef glyphs are added to a todo list, then shaped with the next available font. Bottom line, this fixes several issues we had with chosing base glyph and combining mark from different fonts, placing them incorrectly, etc. It also improves our script resolution to handle braces correctly. It allows us to close a number of bugs related to this area and should make using subsetted web fonts much more reliable. It also allows us to finally remove GlyphPageTreeNode and friends, the core parts of the simple font code path. BUG=504745 TEST=inspector-protocol/layout-fonts/unicode-range-combining-chars-fallback.html Committed: https://crrev.com/9f6a2b03ccb7091804f173b70b5facff7dffbd61 Cr-Commit-Position: refs/heads/master@{#355800}

Patch Set 1 #

Total comments: 19

Patch Set 2 : Review comments addressed #

Total comments: 2

Patch Set 3 : One more unsigned #

Patch Set 4 : Requesting rebaselines #

Patch Set 5 : TestExpectations adjustments #

Patch Set 6 : rebaseline updates #

Patch Set 7 : windows expectations updated #

Patch Set 8 : rebased #

Patch Set 9 : ImageOnlyFailure => Failure #

Patch Set 10 : Another attempt #

Patch Set 11 : rebased #

Patch Set 12 : Fallback to next while loading, unicode-range restrictions #

Patch Set 13 : Experimentally move non-AAT? font first #

Patch Set 14 : Rebase on top of updated font-face-unicode-range test and moved FontDataRange #

Patch Set 15 : fix additional fallback load triggers, contains harfbuzz compat decomp fix #

Patch Set 16 : hopefully last round of TestExpectations tweaks #

Patch Set 17 : a few more Win rebaselines #

Patch Set 18 : Rebased on top of updated HarfBuzz #

Patch Set 19 : merge TestExpectations with the HarfBuzz rebaselines #

Unified diffs Side-by-side diffs Delta from patch set Stats (+604 lines, -338 lines) Patch
M third_party/WebKit/LayoutTests/TestExpectations View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 6 chunks +79 lines, -10 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/FontDataRange.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/FontFallbackIterator.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +5 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/FontFallbackIterator.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 5 chunks +36 lines, -12 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/SimpleFontData.h View 1 1 chunk +0 lines, -1 line 0 comments Download
M third_party/WebKit/Source/platform/fonts/SimpleFontData.cpp View 1 chunk +0 lines, -27 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/shaping/HarfBuzzFace.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +5 lines, -1 line 0 comments Download
M third_party/WebKit/Source/platform/fonts/shaping/HarfBuzzFace.cpp View 1 2 3 4 5 6 7 8 9 10 11 4 chunks +11 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/shaping/HarfBuzzShaper.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +114 lines, -12 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/shaping/HarfBuzzShaper.cpp View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +353 lines, -270 lines 0 comments Download

Messages

Total messages: 111 (50 generated)
drott
5 years, 2 months ago (2015-10-14 07:15:22 UTC) #1
eae
This is awesome! https://codereview.chromium.org/1397423004/diff/1/third_party/WebKit/Source/platform/fonts/SimpleFontData.cpp File third_party/WebKit/Source/platform/fonts/SimpleFontData.cpp (left): https://codereview.chromium.org/1397423004/diff/1/third_party/WebKit/Source/platform/fonts/SimpleFontData.cpp#oldcode457 third_party/WebKit/Source/platform/fonts/SimpleFontData.cpp:457: if (!m_combiningCharacterSequenceSupport) This also means we ...
5 years, 2 months ago (2015-10-14 08:12:01 UTC) #3
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/1
5 years, 2 months ago (2015-10-14 08:36:50 UTC) #5
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/120333)
5 years, 2 months ago (2015-10-14 09:48:05 UTC) #7
eae
Thanks for making the suggested changes and for adding detailed comments! https://codereview.chromium.org/1397423004/diff/20001/third_party/WebKit/Source/platform/fonts/shaping/HarfBuzzShaper.cpp File third_party/WebKit/Source/platform/fonts/shaping/HarfBuzzShaper.cpp (right): ...
5 years, 2 months ago (2015-10-14 13:00:40 UTC) #8
eae
LGTM!
5 years, 2 months ago (2015-10-14 13:00:50 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/50001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/50001
5 years, 2 months ago (2015-10-14 13:23:00 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/50001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/50001
5 years, 2 months ago (2015-10-14 14:27:40 UTC) #15
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/126140)
5 years, 2 months ago (2015-10-14 14:52:10 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/70001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/70001
5 years, 2 months ago (2015-10-15 11:00:39 UTC) #20
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/126694)
5 years, 2 months ago (2015-10-15 12:26:58 UTC) #22
drott
rebaseline updates
5 years, 2 months ago (2015-10-15 13:44:48 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/90001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/90001
5 years, 2 months ago (2015-10-15 13:45:15 UTC) #26
drott
windows expectations updated
5 years, 2 months ago (2015-10-15 15:51:43 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/110001
5 years, 2 months ago (2015-10-15 15:52:00 UTC) #30
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/121134)
5 years, 2 months ago (2015-10-15 18:35:10 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/110001
5 years, 2 months ago (2015-10-15 19:56:22 UTC) #34
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/121297)
5 years, 2 months ago (2015-10-15 23:07:25 UTC) #36
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/110001
5 years, 2 months ago (2015-10-16 04:47:33 UTC) #38
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/109975)
5 years, 2 months ago (2015-10-16 04:52:23 UTC) #40
drott
rebased
5 years, 2 months ago (2015-10-16 06:40:12 UTC) #41
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/130001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/130001
5 years, 2 months ago (2015-10-16 06:41:00 UTC) #44
drott
ImageOnlyFailure => Failure
5 years, 2 months ago (2015-10-16 07:35:07 UTC) #45
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/150001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/150001
5 years, 2 months ago (2015-10-16 07:42:31 UTC) #48
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/127465)
5 years, 2 months ago (2015-10-16 08:28:04 UTC) #50
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/170001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/170001
5 years, 2 months ago (2015-10-19 08:44:32 UTC) #53
drott
rebased
5 years, 2 months ago (2015-10-19 09:37:21 UTC) #55
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/190001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/190001
5 years, 2 months ago (2015-10-19 09:38:00 UTC) #58
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/122286)
5 years, 2 months ago (2015-10-19 11:21:21 UTC) #60
drott
Fallback to next while loading, unicode-range restrictions
5 years, 2 months ago (2015-10-20 08:44:19 UTC) #61
drott
Fallback to next while loading, unicode-range restrictions
5 years, 2 months ago (2015-10-20 08:47:24 UTC) #63
behdad
lgtm
5 years, 2 months ago (2015-10-20 19:15:20 UTC) #64
drott
Rebase on top of updated font-face-unicode-range test and moved FontDataRange
5 years, 2 months ago (2015-10-20 19:59:36 UTC) #65
drott
Rebase on top of updated font-face-unicode-range test and moved FontDataRange
5 years, 2 months ago (2015-10-20 20:12:37 UTC) #67
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/290001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/290001
5 years, 2 months ago (2015-10-21 05:50:22 UTC) #69
commit-bot: I haz the power
Dry run: CLs for remote refs other than refs/pending/heads/master must contain NOTRY=true and NOPRESUBMIT=true in ...
5 years, 2 months ago (2015-10-21 05:50:25 UTC) #71
drott
Rebase on top of updated font-face-unicode-range test and moved FontDataRange
5 years, 2 months ago (2015-10-21 08:00:30 UTC) #73
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/310001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/310001
5 years, 2 months ago (2015-10-21 12:10:07 UTC) #75
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/123602)
5 years, 2 months ago (2015-10-21 13:01:52 UTC) #77
drott
fix additional fallback load triggers, contains harfbuzz compat decomp fix
5 years, 2 months ago (2015-10-22 08:28:01 UTC) #78
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/330001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/330001
5 years, 2 months ago (2015-10-22 08:28:48 UTC) #80
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/130018)
5 years, 2 months ago (2015-10-22 09:24:18 UTC) #82
drott
hopefully last round of TestExpectations tweaks
5 years, 2 months ago (2015-10-22 11:47:32 UTC) #83
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/350001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/350001
5 years, 2 months ago (2015-10-22 11:48:00 UTC) #85
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/129879)
5 years, 2 months ago (2015-10-22 13:06:13 UTC) #87
drott
a few more Win rebaselines
5 years, 2 months ago (2015-10-22 13:19:32 UTC) #88
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/370001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/370001
5 years, 2 months ago (2015-10-22 13:20:12 UTC) #90
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/129910)
5 years, 2 months ago (2015-10-22 14:32:36 UTC) #92
drott
Okay, I think this is ready now, together with https://codereview.chromium.org/1418533006/ and https://codereview.chromium.org/1416013004/#. It would be ...
5 years, 2 months ago (2015-10-22 15:05:20 UTC) #93
drott
Rebased on top of updated HarfBuzz
5 years, 2 months ago (2015-10-23 11:24:40 UTC) #94
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/390001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/390001
5 years, 2 months ago (2015-10-23 11:25:26 UTC) #96
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/130610)
5 years, 2 months ago (2015-10-23 12:26:42 UTC) #98
drott
merge TestExpectations with the HarfBuzz rebaselines
5 years, 2 months ago (2015-10-23 12:34:48 UTC) #99
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/410001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/410001
5 years, 2 months ago (2015-10-23 12:35:29 UTC) #101
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 2 months ago (2015-10-23 15:15:25 UTC) #103
eae
LGTM
5 years, 2 months ago (2015-10-23 16:24:04 UTC) #104
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1397423004/410001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1397423004/410001
5 years, 2 months ago (2015-10-23 16:25:25 UTC) #107
commit-bot: I haz the power
Committed patchset #19 (id:410001)
5 years, 2 months ago (2015-10-23 16:29:58 UTC) #108
drott
Hella Yout and Halleluja! \o/
5 years, 2 months ago (2015-10-23 16:30:45 UTC) #109
commit-bot: I haz the power
Patchset 19 (id:??) landed as https://crrev.com/9f6a2b03ccb7091804f173b70b5facff7dffbd61 Cr-Commit-Position: refs/heads/master@{#355800}
5 years, 2 months ago (2015-10-23 16:30:57 UTC) #110
Nico
5 years, 2 months ago (2015-10-24 16:18:03 UTC) #111
Message was sent while issue was closed.
I believe this caused some test failures. Filed
https://code.google.com/p/chromium/issues/detail?id=547390

Powered by Google App Engine
This is Rietveld 408576698