diff options
author | Jiang Jiang <jiang.jiang@nokia.com> | 2010-09-03 13:49:33 (GMT) |
---|---|---|
committer | Jiang Jiang <jiang.jiang@nokia.com> | 2010-09-10 13:51:56 (GMT) |
commit | f2f6330d915cbe3d0989ad280738ed0a6954cd35 (patch) | |
tree | f92f2fd2ae59ef883a06d230d80763293c988903 /src/gui/text/qfontengine_mac.mm | |
parent | 1e8e290fb5d9b0d059711b9e53ea588872a59c57 (diff) | |
download | Qt-f2f6330d915cbe3d0989ad280738ed0a6954cd35.zip Qt-f2f6330d915cbe3d0989ad280738ed0a6954cd35.tar.gz Qt-f2f6330d915cbe3d0989ad280738ed0a6954cd35.tar.bz2 |
Fix Core Text font loading for certain Mac Fonts
Font names enumerated by Core Text cannot be found by
ATSFontFamilyFindFromName because ATS is expecting native names
instead of the names returned by Core Text. This patch get rid
of ATS font matching code in Cocoa code path to simplify the code,
avoid deprecation warnings (in the future) and fix this issue.
Task-number: QTBUG-11145
Reviewed-by: Eskil
Diffstat (limited to 'src/gui/text/qfontengine_mac.mm')
-rw-r--r-- | src/gui/text/qfontengine_mac.mm | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/gui/text/qfontengine_mac.mm b/src/gui/text/qfontengine_mac.mm index 1ca6ec3..894de44 100644 --- a/src/gui/text/qfontengine_mac.mm +++ b/src/gui/text/qfontengine_mac.mm @@ -143,7 +143,7 @@ void qmacfontengine_gamma_correct(QImage *image) #if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5 -QCoreTextFontEngineMulti::QCoreTextFontEngineMulti(const ATSFontFamilyRef &, const ATSFontRef &atsFontRef, const QFontDef &fontDef, bool kerning) +QCoreTextFontEngineMulti::QCoreTextFontEngineMulti(const QCFString &name, const QFontDef &fontDef, bool kerning) : QFontEngineMulti(0) { this->fontDef = fontDef; @@ -159,9 +159,6 @@ QCoreTextFontEngineMulti::QCoreTextFontEngineMulti(const ATSFontFamilyRef &, con break; } - QCFString name; - ATSFontGetName(atsFontRef, kATSOptionFlagsDefault, &name); - transform = CGAffineTransformIdentity; if (fontDef.stretch != 100) { transform = CGAffineTransformMakeScale(float(fontDef.stretch) / float(100), 1); |