Changeset 192372 in webkit
- Timestamp:
- Nov 12, 2015, 11:37:53 AM (10 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r192369 r192372 1 2015-11-12 Myles C. Maxfield <mmaxfield@apple.com> 2 3 [Cocoa] Font fallback is not language-sensitive 4 https://bugs.webkit.org/show_bug.cgi?id=147390 5 6 Reviewed by Dean Jackson. 7 8 This patch adds a mismatch test to make sure a codepoint gets rendered differently given two different langs. 9 10 * fast/text/fallback-language-han-2-expected-mismatch.html: Added. 11 * fast/text/fallback-language-han-2.html: Added. 12 * platform/efl/TestExpectations: 13 * platform/gtk/TestExpectations: 14 * platform/mac/TestExpectations: 15 * platform/win/TestExpectations: 16 1 17 2015-11-11 Jon Honeycutt <jhoneycutt@apple.com> 2 18 -
trunk/LayoutTests/platform/efl/TestExpectations
r191552 r192372 2357 2357 # This test hardcodes the result of a platform-dependent font lookup algorithm. 2358 2358 fast/text/fallback-language-han.html [ Skip ] 2359 fast/text/fallback-language-han-2.html [ Skip ] 2359 2360 2360 2361 # This test uses an MPEG-4 video -
trunk/LayoutTests/platform/gtk/TestExpectations
r192365 r192372 2560 2560 # This test hardcodes the result of a platform-dependent font lookup algorithm. 2561 2561 fast/text/fallback-language-han.html [ Skip ] 2562 fast/text/fallback-language-han-2.html [ Skip ] 2562 2563 2563 2564 # This test uses an MPEG-4 video -
trunk/LayoutTests/platform/mac/TestExpectations
r192279 r192372 1270 1270 # Language-specific font fallback is disabled on certain versions of OS X 1271 1271 webkit.org/b/147390 [ Mavericks Yosemite ElCapitan ] fast/text/fallback-language-han.html [ ImageOnlyFailure ] 1272 webkit.org/b/147390 [ Mavericks Yosemite ElCapitan ] fast/text/fallback-language-han-2.html [ ImageOnlyFailure ] 1272 1273 1273 1274 # This test relies on iOS-specific font fallback. -
trunk/LayoutTests/platform/win/TestExpectations
r192365 r192372 3189 3189 # This test hardcodes the result of a platform-dependent font lookup algorithm. 3190 3190 fast/text/fallback-language-han.html [ Skip ] 3191 fast/text/fallback-language-han-2.html [ Skip ] 3191 3192 3192 3193 # Changing system language is not supported. -
trunk/Source/WebCore/ChangeLog
r192369 r192372 1 2015-11-12 Myles C. Maxfield <mmaxfield@apple.com> 2 3 [Cocoa] Font fallback is not language-sensitive 4 https://bugs.webkit.org/show_bug.cgi?id=147390 5 6 Reviewed by Dean Jackson. 7 8 This re-applies r190754 in a somewhat more performant way. 9 10 Test: fast/text/fallback-language-han-2.html 11 12 * platform/graphics/Font.cpp: 13 (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey): 14 (WebCore::CharacterFallbackMapKey::operator==): 15 (WebCore::CharacterFallbackMapKeyHash::hash): 16 (WebCore::Font::systemFallbackFontForCharacter): 17 * platform/graphics/cocoa/FontCacheCoreText.cpp: 18 (WebCore::FontCache::systemFallbackForCharacters): 19 1 20 2015-11-11 Jon Honeycutt <jhoneycutt@apple.com> 2 21 -
trunk/Source/WebCore/platform/graphics/Font.cpp
r191871 r192372 395 395 } 396 396 397 CharacterFallbackMapKey(UChar32 character, bool isForPlatformFont) 398 : character(character) 397 CharacterFallbackMapKey(const AtomicString& locale, UChar32 character, bool isForPlatformFont) 398 : locale(locale) 399 , character(character) 399 400 , isForPlatformFont(isForPlatformFont) 400 401 { … … 410 411 bool operator==(const CharacterFallbackMapKey& other) const 411 412 { 412 return character == other.character && isForPlatformFont == other.isForPlatformFont;413 return locale == other.locale && character == other.character && isForPlatformFont == other.isForPlatformFont; 413 414 } 414 415 … … 418 419 friend struct CharacterFallbackMapKeyHash; 419 420 421 AtomicString locale; 420 422 UChar32 character { 0 }; 421 423 bool isForPlatformFont { false }; … … 425 427 static unsigned hash(const CharacterFallbackMapKey& key) 426 428 { 427 return WTF::pairIntHash(key.character, key.isForPlatformFont); 429 IntegerHasher hasher; 430 hasher.add(key.character); 431 hasher.add(key.isForPlatformFont); 432 hasher.add(key.locale.isNull() ? 0 : key.locale.impl()->existingHash()); 433 return hasher.hash(); 428 434 } 429 435 … … 456 462 } 457 463 458 auto key = CharacterFallbackMapKey( character, isForPlatformFont);464 auto key = CharacterFallbackMapKey(description.locale(), character, isForPlatformFont); 459 465 auto characterAddResult = fontAddResult.iterator->value.add(WTF::move(key), nullptr); 460 466
Note:
See TracChangeset
for help on using the changeset viewer.