summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuilherme Polo <ggpolo@gmail.com>2009-08-18 13:23:08 (GMT)
committerGuilherme Polo <ggpolo@gmail.com>2009-08-18 13:23:08 (GMT)
commitd3e6e4bb8ff2a88afd6d2cc09dd199defbef36a4 (patch)
tree63c0c28b8fe7712d4c1d10e0b13a75111472108e
parent9132916efb4df3b9da05361d9c65212df954ca9d (diff)
downloadcpython-d3e6e4bb8ff2a88afd6d2cc09dd199defbef36a4.zip
cpython-d3e6e4bb8ff2a88afd6d2cc09dd199defbef36a4.tar.gz
cpython-d3e6e4bb8ff2a88afd6d2cc09dd199defbef36a4.tar.bz2
Issue #1119673: Do not override Tkinter.Text methods when creating a ScrolledText.
-rw-r--r--Lib/lib-tk/ScrolledText.py5
-rw-r--r--Misc/NEWS3
2 files changed, 7 insertions, 1 deletions
diff --git a/Lib/lib-tk/ScrolledText.py b/Lib/lib-tk/ScrolledText.py
index 8076bc4..a1ef79c 100644
--- a/Lib/lib-tk/ScrolledText.py
+++ b/Lib/lib-tk/ScrolledText.py
@@ -27,8 +27,11 @@ class ScrolledText(Text):
self.pack(side=LEFT, fill=BOTH, expand=True)
self.vbar['command'] = self.yview
- # Copy geometry methods of self.frame -- hack!
+ # Copy geometry methods of self.frame without overriding Text
+ # methods -- hack!
+ text_meths = vars(Text).keys()
methods = vars(Pack).keys() + vars(Grid).keys() + vars(Place).keys()
+ methods = set(methods).difference(text_meths)
for m in methods:
if m[0] != '_' and m != 'config' and m != 'configure':
diff --git a/Misc/NEWS b/Misc/NEWS
index 4b28be2..ca3c5e8 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -359,6 +359,9 @@ Core and Builtins
Library
-------
+- Issue #1119673: Do not override Tkinter.Text methods when creating a
+ ScrolledText.
+
- Issue #6665: Fix fnmatch to properly match filenames with newlines in them.
- Issue #1135: Add the XView and YView mix-ins to avoid duplicating