summaryrefslogtreecommitdiffstats
path: root/Lib/lib-tk
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2001-09-05 19:29:56 (GMT)
committerGuido van Rossum <guido@python.org>2001-09-05 19:29:56 (GMT)
commit09f1ad854237542315ec86151aa56b143e54d1d2 (patch)
tree8ccb87de3f30e3c1cdb403bb0eb81f5e162da1aa /Lib/lib-tk
parentbb5a465ca91dea3a162c9bd11995d1edd2363598 (diff)
downloadcpython-09f1ad854237542315ec86151aa56b143e54d1d2.zip
cpython-09f1ad854237542315ec86151aa56b143e54d1d2.tar.gz
cpython-09f1ad854237542315ec86151aa56b143e54d1d2.tar.bz2
class Listbox: add itemcget, to satisfy SF patch #457713.
Fix up docstring for itemconfigure.
Diffstat (limited to 'Lib/lib-tk')
-rw-r--r--Lib/lib-tk/Tkinter.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/Lib/lib-tk/Tkinter.py b/Lib/lib-tk/Tkinter.py
index a5a18c4..2b04ee0 100644
--- a/Lib/lib-tk/Tkinter.py
+++ b/Lib/lib-tk/Tkinter.py
@@ -2363,8 +2363,12 @@ class Listbox(Widget):
def yview_scroll(self, number, what):
"""Shift the y-view according to NUMBER which is measured in "units" or "pages" (WHAT)."""
self.tk.call(self._w, 'yview', 'scroll', number, what)
+ def itemcget(self, index, option):
+ """Return the resource value for an ITEM and an OPTION."""
+ return self.tk.call(
+ (self._w, 'itemcget') + (index, '-'+option))
def itemconfigure(self, index, cnf=None, **kw):
- """Configure resources of an item.
+ """Configure resources of an ITEM.
The values for resources are specified as keyword arguments.
To get an overview about the allowed keyword arguments