summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2017-05-23 10:45:34 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2017-05-23 10:45:34 (GMT)
commitce84448c05bb61135f0cebd1a812f3e4496f62bd (patch)
treedd1461ac3b7b2b52c1a274c95cf3d2e580406797
parentb8bd50957127f5889bdae3f560c27549662de478 (diff)
downloadtk-ce84448c05bb61135f0cebd1a812f3e4496f62bd.zip
tk-ce84448c05bb61135f0cebd1a812f3e4496f62bd.tar.gz
tk-ce84448c05bb61135f0cebd1a812f3e4496f62bd.tar.bz2
Fix test-case font-44.1: It looks like XftPatternAddDouble(... XFT_PIXEL_SIZE ..) doesn't take scaling into account, so we have to do our own scaling.
-rw-r--r--unix/tkUnixRFont.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/unix/tkUnixRFont.c b/unix/tkUnixRFont.c
index a08b95f..cce59a8 100644
--- a/unix/tkUnixRFont.c
+++ b/unix/tkUnixRFont.c
@@ -447,7 +447,7 @@ TkpGetFontFromAttributes(
if (faPtr->size > 0.0) {
XftPatternAddDouble(pattern, XFT_SIZE, faPtr->size);
} else if (faPtr->size < 0.0) {
- XftPatternAddDouble(pattern, XFT_PIXEL_SIZE, -faPtr->size);
+ XftPatternAddDouble(pattern, XFT_SIZE, TkFontGetPoints(tkwin, faPtr->size));
} else {
XftPatternAddDouble(pattern, XFT_SIZE, 12.0);
}