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

Unified Diff: platform/graphics/FontFastPath.cpp

Issue 2241005: Update the list of characters to be deal with in complex code path Base URL: http://svn.webkit.org/repository/webkit/trunk/WebCore/
Patch Set: '' Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: platform/graphics/FontFastPath.cpp
===================================================================
--- platform/graphics/FontFastPath.cpp (revision 60058)
+++ platform/graphics/FontFastPath.cpp (working copy)
@@ -196,8 +196,15 @@
return s_codePath;
// Start from 0 since drawing and highlighting also measure the characters before run->from
+ // FIXME: Should use a UnicodeSet in ports where ICU is used. Note that we
+ // can't simply use UnicodeCharacter Property/class because some characters
+ // are not 'combining', but still need to go to the complex path.
for (int i = 0; i < run.length(); i++) {
const UChar c = run[i];
+ if (c < 0x02E5) // U+02E5 through U+02E9 (Modifier Letters : Tone letters)
+ continue;
+ if (c <= 0x02E9)
+ return Complex;
if (c < 0x300) // U+0300 through U+036F Combining diacritical marks
continue;
if (c <= 0x36F)
@@ -218,7 +225,7 @@
if (c <= 0x11FF)
return Complex;
- if (c < 0x1780) // U+1780 through U+18AF Khmer, Mongolian
+ if (c < 0x1700) // U+1700 through U+18AF Tagalog, Hanunoo, Buhid, Tagbanwa, Khmer, Mongolian
continue;
if (c <= 0x18AF)
return Complex;
@@ -228,6 +235,21 @@
if (c <= 0x194F)
return Complex;
+ if (c < 0x1980) // U+1980 through U+19DF New Tai Lue
+ continue;
+ if (c <= 0x19DF)
+ return Complex;
+
+ if (c < 0x1A00) // U+1A00 through U+1C4F Buginese, Balinese, Lepcha
+ continue;
+ if (c <= 0x1C4F)
+ return Complex;
+
+ if (c < 0x1DC0) // U+1DC0 through U+1DFF Comining diacritical mark supplement
+ continue;
+ if (c <= 0x1DFF)
+ return Complex;
+
if (c < 0x1E00) // U+1E00 through U+2000 characters with diacritics and stacked diacritics
continue;
if (c <= 0x2000)
@@ -238,6 +260,14 @@
if (c <= 0x20FF)
return Complex;
+ if (c < 0xA800) // U+A800 through U+ABFF : Nagri, Phags-pa, Saurashtra, Hangul Jamo Ext. A, Meetei Mayek
+ continue;
+ if (c <= 0xABFF)
+ return Complex;
+ if (c < 0xD7B0) // U+D7B0 through U+D7FF : Hangul Jamo Ext. B
+ continue;
+ if (c <= 0xD7FF)
+ return Complex;
if (c < 0xFE20) // U+FE20 through U+FE2F Combining half marks
continue;
if (c <= 0xFE2F)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698