summaryrefslogtreecommitdiffstats
path: root/unix
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2016-12-30 22:20:00 (GMT)
committerfvogel <fvogelnew1@free.fr>2016-12-30 22:20:00 (GMT)
commitaec9ede5b3da6947ff19211dab99b56bb5379305 (patch)
tree4a6958521807d8c72bbe8a5e25d32cc3630bef03 /unix
parent531e91677e137dc0d6109374daef5cc802bf7c7d (diff)
downloadtk-aec9ede5b3da6947ff19211dab99b56bb5379305.zip
tk-aec9ede5b3da6947ff19211dab99b56bb5379305.tar.gz
tk-aec9ede5b3da6947ff19211dab99b56bb5379305.tar.bz2
Do everything the other way round. Leave things how they were on OS X (revert [a076cf64] and [42e0339e]), and fix TkpDrawCharsInContext() on Win and Linux in case these platforms at some point of time decide to define TK_LAYOUT_WITH_BASE_CHUNKS and TK_DRAW_IN_CONTEXT to true
Diffstat (limited to 'unix')
-rw-r--r--unix/tkUnixFont.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/unix/tkUnixFont.c b/unix/tkUnixFont.c
index 4a466f1..0c663a3 100644
--- a/unix/tkUnixFont.c
+++ b/unix/tkUnixFont.c
@@ -1414,10 +1414,13 @@ TkpDrawCharsInContext(
* whole (not just the range) string when
* drawing. */
{
+ int widthUntilStart;
+
(void) numBytes; /*unused*/
+ Tk_MeasureChars(tkfont, source, rangeStart, -1, 0, &widthUntilStart);
Tk_DrawChars(display, drawable, gc, tkfont, source + rangeStart,
- rangeLength, x, y);
+ rangeLength, x+widthUntilStart, y);
}
/*