WebCore:
Reviewed by Darin Adler.
- fix <rdar://problem/
5631507> Text doesn't wrap properly at Tamil version of Wikipedia
Test: fast/text/international/complex-character-based-fallback.html
* platform/graphics/Font.cpp:
(WebCore::Font::glyphDataForCharacter): Added a forceSmallCaps argument
that forces this function to use the small caps font. It is used for
combining marks that need to combine with a small cap.
* platform/graphics/Font.h:
* platform/win/UniscribeController.cpp:
(WebCore::UniscribeController::advance): Changed to split the string
into runs of characters that will be rendered using the same FontData.
This is done by calling glyphDataForCharacter() for each cahracter to
find the FontData it should be rendered with.
(WebCore::UniscribeController::itemizeShapeAndPlace): Added a fontData
argument that is passed on to shapeAndPlaceItem() instead of the
smallCaps argument.
(WebCore::UniscribeController::shapeAndPlaceItem): Added a fontData
argument and removed the font fallback logic from this function, as
it is now expected to be called with an item all of whose characters
can be rendered with the given fontData.
* platform/win/UniscribeController.h:
LayoutTests:
Reviewed by Darin Adler.
- test for <rdar://problem/
5631507> Text doesn't wrap properly at Tamil version of Wikipedia
* fast/text/international/complex-character-based-fallback.html: Added.
* platform/mac-leopard/fast/text/international/complex-character-based-fallback-expected.checksum: Added.
* platform/mac-leopard/fast/text/international/complex-character-based-fallback-expected.png: Added.
* platform/mac/fast/text/international/complex-character-based-fallback-expected.txt: Added.
* platform/win/fast/text: Added.
* platform/win/fast/text/international: Added.
* platform/win/fast/text/international/complex-character-based-fallback-expected.checksum: Added.
* platform/win/fast/text/international/complex-character-based-fallback-expected.png: Added.
* platform/win/fast/text/international/complex-character-based-fallback-expected.txt: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@28621
268f45cc-cd09-0410-ab3c-
d52691b4dbfc