<rdar://problem/11025217> [Mac] Assertion failure in collectComplexTextRunsForCharact...
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 13 Mar 2012 23:57:32 +0000 (23:57 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 13 Mar 2012 23:57:32 +0000 (23:57 +0000)
commitd455d2e87cb9470590545c8c491bafece54eaf5f
tree566de9e20d62a5e0829c8eee426cd3b392a6ae9e
parent82b17874efc54670f4ff1b844719f766532ff753
<rdar://problem/11025217> [Mac] Assertion failure in collectComplexTextRunsForCharactersCoreText
https://bugs.webkit.org/show_bug.cgi?id=77044

Reviewed by Sam Weinig.

Source/WebCore:

Test: platform/mac/fast/text/core-text-fallback-to-unknown-font.html

Handle the case of Core Text choosing a fallback font that NSFontManager cannot find by name.

* platform/graphics/FontCache.h:
(FontCache): Made ComplexTextController a friend class.
* platform/graphics/mac/ComplexTextControllerCoreText.mm:
(WebCore::ComplexTextController::collectComplexTextRunsForCharactersCoreText): Removed the
failing assertion, which was not true, and added code to handle the case where a font
cannot be found by name by using the font as returned from Core Text.

LayoutTests:

* platform/mac/fast/text/core-text-fallback-to-unknown-font-expected.txt: Added.
* platform/mac/fast/text/core-text-fallback-to-unknown-font.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@110642 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/platform/mac/fast/text/core-text-fallback-to-unknown-font-expected.txt [new file with mode: 0644]
LayoutTests/platform/mac/fast/text/core-text-fallback-to-unknown-font.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/FontCache.h
Source/WebCore/platform/graphics/mac/ComplexTextControllerCoreText.mm