summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Lillqvist <tml@collabora.com>2018-01-23 15:04:00 +0200
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2018-01-24 16:54:35 +0100
commit3aeda82b09253d20d234d50b39e76977031f2102 (patch)
tree0205344889cd4a05f762bca5079551ec97146daa
parent987a50f3a70cf6ece9245b9a3e6d353c15cb1fdf (diff)
tdf#69254: Tweak mapping from CoreText weight to our FontWeight a bit
Make the mapping of light weights more likely to hit different enum values for slightly different weights. We want to be able to distinguish between for instance Overpass Light (with weight -0.4) and Overpass ExtraLight (with weight -0.5). Change-Id: If83fbce68149b267a49ef9bcb6624d8790de7c56 Reviewed-on: https://gerrit.libreoffice.org/48426 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
-rw-r--r--vcl/quartz/ctfonts.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/quartz/ctfonts.cxx b/vcl/quartz/ctfonts.cxx
index c31dcc329e2b..ebb7066be9d8 100644
--- a/vcl/quartz/ctfonts.cxx
+++ b/vcl/quartz/ctfonts.cxx
@@ -397,7 +397,7 @@ FontAttributes DevFontFromCTFontDescriptor( CTFontDescriptorRef pFD, bool* bFont
}
else if( fWeight < 0 )
{
- nInt = rint(WEIGHT_NORMAL + fWeight * ((WEIGHT_NORMAL - WEIGHT_THIN)/0.9));
+ nInt = rint(WEIGHT_NORMAL + fWeight * ((WEIGHT_NORMAL - WEIGHT_THIN)/0.8));
if( nInt < WEIGHT_THIN )
{
nInt = WEIGHT_THIN;