Changeset 216874 in webkit
- Timestamp:
- May 15, 2017 1:16:51 PM (7 years ago)
- Location:
- trunk
- Files:
-
- 4 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r216861 r216874 1 2017-05-15 Myles C. Maxfield <mmaxfield@apple.com> 2 3 Unicode characters which can't be rendered in any font are invisible 4 https://bugs.webkit.org/show_bug.cgi?id=171942 5 <rdar://problem/32054234> 6 7 Reviewed by Tim Horton. 8 9 * fast/text/default-ignorable-expected.html: Added. 10 * fast/text/default-ignorable.html: Added. 11 * fast/text/unknown-char-notdef-expected-mismatch.html: Added. 12 * fast/text/unknown-char-notdef.html: Added. 13 1 14 2017-05-15 Zalan Bujtas <zalan@apple.com> 2 15 -
trunk/LayoutTests/platform/mac/fast/text/softbank-emoji-expected.txt
r185175 r216874 6 6 RenderBlock {DIV} at (0,0) size 784x230 7 7 RenderBlock {DIV} at (0,0) size 784x115 8 RenderText {#text} at (0,0) size 112x1159 text run at (0,0) width 112: "\x{E001} a \x{E001}"8 RenderText {#text} at (0,0) size 238x115 9 text run at (0,0) width 238: "\x{E001} a \x{E001}" 10 10 RenderBlock {DIV} at (0,115) size 784x115 11 RenderText {#text} at (0,0) size 0x11512 text run at (0,0) width 0: "\x{E001}"11 RenderText {#text} at (0,0) size 64x115 12 text run at (0,0) width 64: "\x{E001}" -
trunk/Source/WebCore/ChangeLog
r216868 r216874 1 2017-05-15 Myles C. Maxfield <mmaxfield@apple.com> 2 3 Unicode characters which can't be rendered in any font are invisible 4 https://bugs.webkit.org/show_bug.cgi?id=171942 5 <rdar://problem/32054234> 6 7 Reviewed by Tim Horton. 8 9 There are some Unicode characters which don't have any font on the system which can render them. 10 These characters should be drawn as the .notdef "tofu." This is for security and usability, as 11 well as what Firefox and Chrome do. However, we still shouldn't draw characters with the 12 Default_Ignorable_Code_Point property, because this is what CoreText does. 13 14 This behavior is also what the Unicode spec recommends: In UTR #36 Unicode Security Considerations: 15 http://www.unicode.org/reports/tr36/#Recommendations_General 16 "If there is no available glyph for a character, never show a simple "?" or omit the character." 17 18 Also relevant is the Unicode Standard section 5.3 Unknown and MIssing Characters, starting at page 19 marked 203 in the following: http://www.unicode.org/versions/Unicode9.0.0/ch05.pdf 20 21 Tests: fast/text/default-ignorable.html 22 fast/text/unknown-char-notdef.html 23 24 * platform/graphics/WidthIterator.cpp: 25 (WebCore::characterMustDrawSomething): 26 1 27 2017-05-15 Timothy Horton <timothy_horton@apple.com> 2 28 -
trunk/Source/WebCore/platform/graphics/WidthIterator.cpp
r211738 r216874 163 163 } 164 164 165 static bool characterMustDrawSomething(UChar32 character) 166 { 167 // u_hasBinaryProperty(character, UCHAR_EMOJI) would be better to use, but many OSes which 168 // WebKit runs on only have ICU version 55.1 or earlier. UCHAR_EMOJI was added in ICU 57. 169 return character >= 0x1F900 && character <= 0x1F9FF; 165 static inline bool characterMustDrawSomething(UChar32 character) 166 { 167 return !u_hasBinaryProperty(character, UCHAR_DEFAULT_IGNORABLE_CODE_POINT); 170 168 } 171 169
Note: See TracChangeset
for help on using the changeset viewer.