diff options
author | Herbert Dürr <hdu@apache.org> | 2014-01-28 13:31:31 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-01-28 15:19:34 +0000 |
commit | 3e99ab21d389e12b5fca3ef6828a8cded49489ec (patch) | |
tree | 59ac94d1daefe76c67b39063272a2bf55bc99a4c | |
parent | f244845c89ac72bfd4b878a88a3b5c131df71d3f (diff) |
Resolves: #i124121# prevent italic emulation with ITALIC_DONTKNOW fonts
(cherry picked from commit a8cd1fab9a17df6179c31e1a73816f1bcd627a9b)
Conflicts:
vcl/aqua/source/gdi/ctfonts.cxx
Change-Id: Ib2893a0ce119ac56ac7091fd18a652fe990e82ec
-rw-r--r-- | vcl/quartz/ctfonts.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/vcl/quartz/ctfonts.cxx b/vcl/quartz/ctfonts.cxx index ea4cdadf6510..fffd680a14ac 100644 --- a/vcl/quartz/ctfonts.cxx +++ b/vcl/quartz/ctfonts.cxx @@ -74,7 +74,9 @@ CoreTextStyle::CoreTextStyle( const FontSelectPattern& rFSD ) CFDictionarySetValue( mpStyleDict, kCTVerticalFormsAttributeName, pCFVertBool ); // fake bold - if ((pReqFont->GetWeight() >= WEIGHT_BOLD) && (mpFontData->GetWeight() < WEIGHT_SEMIBOLD)) + if ( (pReqFont->GetWeight() >= WEIGHT_BOLD) && + ((mpFontData->GetWeight() < WEIGHT_SEMIBOLD) && + (mpFontData->GetWeight() != WEIGHT_DONTKNOW)) ) { int nStroke = -10.0; CFNumberRef rStroke = CFNumberCreate(NULL, kCFNumberSInt32Type, &nStroke); @@ -83,7 +85,7 @@ CoreTextStyle::CoreTextStyle( const FontSelectPattern& rFSD ) // fake italic if (((pReqFont->GetSlant() == ITALIC_NORMAL) || (pReqFont->GetSlant() == ITALIC_OBLIQUE)) - && !((mpFontData->GetSlant() == ITALIC_NORMAL) || (mpFontData->GetSlant() == ITALIC_OBLIQUE))) + && (mpFontData->GetSlant() == ITALIC_NONE)) { aMatrix = CGAffineTransformConcat(aMatrix, CGAffineTransformMake(1, 0, toRadian(120), 1, 0, 0)); } |