Turns out that 'winfo id' returns the id as a hex string, with 0x prefix.

The int() function (aliased to getint()) doesn't handle that, so we must
use self.tk.getint() again...
This commit is contained in:
Guido van Rossum 1998-06-19 04:35:45 +00:00
parent 268824e089
commit cef4c844df
1 changed files with 1 additions and 1 deletions

View File

@ -332,7 +332,7 @@ class Misc:
return getint(
self.tk.call('winfo', 'height', self._w))
def winfo_id(self):
return getint(
return self.tk.getint(
self.tk.call('winfo', 'id', self._w))
def winfo_interps(self, displayof=0):
args = ('winfo', 'interps') + self._displayof(displayof)