[Python-checkins] cpython (merge 3.5 -> 3.6): Issue #25464: Fixed HList.header_exists() in tkinter.tix module by addin

serhiy.storchaka python-checkins at python.org
Mon Oct 24 16:50:21 EDT 2016


https://hg.python.org/cpython/rev/523aecdb8d5f
changeset:   104681:523aecdb8d5f
branch:      3.6
parent:      104677:ee476248a74a
parent:      104680:e928afbcc18a
user:        Serhiy Storchaka <storchaka at gmail.com>
date:        Mon Oct 24 23:49:10 2016 +0300
summary:
  Issue #25464: Fixed HList.header_exists() in tkinter.tix module by addin
a workaround to Tix library bug.

files:
  Lib/tkinter/tix.py |  6 +++++-
  Misc/NEWS          |  3 +++
  2 files changed, 8 insertions(+), 1 deletions(-)


diff --git a/Lib/tkinter/tix.py b/Lib/tkinter/tix.py
--- a/Lib/tkinter/tix.py
+++ b/Lib/tkinter/tix.py
@@ -926,7 +926,11 @@
         return self.tk.call(self._w, 'header', 'cget', col, opt)
 
     def header_exists(self,  col):
-        return self.tk.call(self._w, 'header', 'exists', col)
+        # A workaround to Tix library bug (issue #25464).
+        # The documented command is "exists", but only erroneous "exist" is
+        # accepted.
+        return self.tk.getboolean(self.tk.call(self._w, 'header', 'exist', col))
+    header_exist = header_exists
 
     def header_delete(self, col):
         self.tk.call(self._w, 'header', 'delete', col)
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -23,6 +23,9 @@
 Library
 -------
 
+- Issue #25464: Fixed HList.header_exists() in tkinter.tix module by addin
+  a workaround to Tix library bug.
+
 - Issue #28488: shutil.make_archive() no longer adds entry "./" to ZIP archive.
 
 - Issue #25953: re.sub() now raises an error for invalid numerical group

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list