diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-05-18 22:13:11 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-05-18 22:13:11 (GMT) |
commit | 4f50c7029e01320a12dc647ce7606cf8bc9abe4b (patch) | |
tree | 7a358401b3a740b3b436aeaa28d28d401ddf5a60 /generic | |
parent | 7f88ead86800c2b727d5d8c89c970a9506f92372 (diff) | |
parent | 5204a77ccd7306b8ed7c3c264c88171f68180efd (diff) | |
download | tk-4f50c7029e01320a12dc647ce7606cf8bc9abe4b.zip tk-4f50c7029e01320a12dc647ce7606cf8bc9abe4b.tar.gz tk-4f50c7029e01320a12dc647ce7606cf8bc9abe4b.tar.bz2 |
Merge 8.6
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tkFont.c | 4 | ||||
-rw-r--r-- | generic/tkSelect.c | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/generic/tkFont.c b/generic/tkFont.c index 916c48b..34f8921 100644 --- a/generic/tkFont.c +++ b/generic/tkFont.c @@ -2738,8 +2738,8 @@ Tk_CharBbox( x += chunkPtr->x; } if (widthPtr != NULL) { - Tk_MeasureChars(tkfont, end, Tcl_UtfNext(end) - end, - -1, 0, &w); + int ch; + Tk_MeasureChars(tkfont, end, TkUtfToUniChar(end, &ch), -1, 0, &w); } goto check; } diff --git a/generic/tkSelect.c b/generic/tkSelect.c index ded8a11..9fd3970 100644 --- a/generic/tkSelect.c +++ b/generic/tkSelect.c @@ -1401,11 +1401,12 @@ HandleTclCommand( cmdInfoPtr->charOffset += Tcl_NumUtfChars(string, -1); cmdInfoPtr->buffer[0] = '\0'; } else { + Tcl_UniChar ch = 0; p = string; string += count; numChars = 0; while (p < string) { - p = Tcl_UtfNext(p); + p += Tcl_UtfToUniChar(p, &ch); numChars++; } cmdInfoPtr->charOffset += numChars; |