From: Guido van Rossum Date: Thu, 16 May 1996 17:53:48 +0000 (+0000) Subject: Made Place.info == Pack.info X-Git-Tag: v1.4b1~186 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=63e39ae933e415ed228dfed3b13514e6b513a2a9;p=python Made Place.info == Pack.info --- diff --git a/Lib/lib-tk/Tkinter.py b/Lib/lib-tk/Tkinter.py index ae5aca4433..0a538092d6 100644 --- a/Lib/lib-tk/Tkinter.py +++ b/Lib/lib-tk/Tkinter.py @@ -704,7 +704,16 @@ class Place: self.tk.call('place', 'forget', self._w) place_forget = forget def info(self): - return self.tk.call('place', 'info', self._w) + words = self.tk.splitlist( + self.tk.call('place', 'info', self._w)) + dict = {} + for i in range(0, len(words), 2): + key = words[i][1:] + value = words[i+1] + if value[:1] == '.': + value = self._nametowidget(value) + dict[key] = value + return dict place_info = info def slaves(self): return map(self._nametowidget, diff --git a/Lib/tkinter/Tkinter.py b/Lib/tkinter/Tkinter.py index ae5aca4433..0a538092d6 100755 --- a/Lib/tkinter/Tkinter.py +++ b/Lib/tkinter/Tkinter.py @@ -704,7 +704,16 @@ class Place: self.tk.call('place', 'forget', self._w) place_forget = forget def info(self): - return self.tk.call('place', 'info', self._w) + words = self.tk.splitlist( + self.tk.call('place', 'info', self._w)) + dict = {} + for i in range(0, len(words), 2): + key = words[i][1:] + value = words[i+1] + if value[:1] == '.': + value = self._nametowidget(value) + dict[key] = value + return dict place_info = info def slaves(self): return map(self._nametowidget,