Hirokazu Yamamoto added the comment:

Sorry for late repry. I couldn't apply Issue1522587's patch itself
because it was too old, so I tried only [xy]view{,_moveto,_scroll}
functions by applying patch partially. (partial.patch) And yes, it worked.

Added file: http://bugs.python.org/file8634/partial.patch

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1135>
__________________________________
Index: Lib/lib-tk/Tix.py
===================================================================
--- Lib/lib-tk/Tix.py	(revision 58625)
+++ Lib/lib-tk/Tix.py	(working copy)
@@ -1865,21 +1865,25 @@
     # def size dim index ?option value ...?
     # def unset x y
 
-    def xview(self):
-        return self._getdoubles(self.tk.call(self, 'xview'))
+    def xview(self, *what):
+        if not what:
+            return self._getdoubles(self.tk.call(self._w, 'xview'))
+        self.tk.call((self._w, 'xview') + what)
     def xview_moveto(self, fraction):
-        self.tk.call(self,'xview', 'moveto', fraction)
+        self.tk.call(self._w,'xview', 'moveto', fraction)
     def xview_scroll(self, count, what="units"):
-        "Scroll right (count>0) or left <count> of units|pages"
-        self.tk.call(self, 'xview', 'scroll', count, what)
+        "Scroll right (count>0) or left (count<0) of units|pages"
+        self.tk.call(self._w, 'xview', 'scroll', count, what)
 
-    def yview(self):
-        return self._getdoubles(self.tk.call(self, 'yview'))
+    def yview(self, *what):
+        if not what:
+            return self._getdoubles(self.tk.call(self._w, 'yview'))
+        self.tk.call((self._w, 'yview') + what)
     def yview_moveto(self, fraction):
-        self.tk.call(self,'ysview', 'moveto', fraction)
+        self.tk.call(self._w,'yview', 'moveto', fraction)
     def yview_scroll(self, count, what="units"):
-        "Scroll down (count>0) or up <count> of units|pages"
-        self.tk.call(self, 'yview', 'scroll', count, what)
+        "Scroll down (count>0) or up (count>0) of units|pages"
+        self.tk.call(self._w, 'yview', 'scroll', count, what)
 
 class ScrolledGrid(Grid):
     '''Scrolled Grid widgets'''
_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to