summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Lib/lib-tk/Tkinter.py2
-rw-r--r--Misc/NEWS2
2 files changed, 3 insertions, 1 deletions
diff --git a/Lib/lib-tk/Tkinter.py b/Lib/lib-tk/Tkinter.py
index de2873fc3c..31a2fc36d2 100644
--- a/Lib/lib-tk/Tkinter.py
+++ b/Lib/lib-tk/Tkinter.py
@@ -3005,7 +3005,7 @@ class Text(Widget):
return self.tk.call(self._w, "image", "names")
def index(self, index):
"""Return the index in the form line.char for INDEX."""
- return self.tk.call(self._w, 'index', index)
+ return str(self.tk.call(self._w, 'index', index))
def insert(self, index, chars, *args):
"""Insert CHARS before the characters at INDEX. An additional
tag can be given in ARGS. Additional CHARS and tags can follow in ARGS."""
diff --git a/Misc/NEWS b/Misc/NEWS
index b83c73169c..99e385a0eb 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -109,6 +109,8 @@ Core and builtins
Library
-------
+- Issue #4342: Always convert Text.index result to string.
+
- Issue 3248: Allow placing ScrolledText in a PanedWindow.
- Issue #4084: Fix max, min, max_mag and min_mag Decimal methods to