Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 24037f7

Browse files
author
Fredrik Lundh
committed
-- don't mess up in winfo_visualsavailable if the system only
supports a single visual (closes bug #110603)
1 parent 289ad8f commit 24037f7

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

Lib/lib-tk/Tkinter.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -774,6 +774,8 @@ def winfo_visualsavailable(self, includeids=0):
774774
data = self.tk.split(
775775
self.tk.call('winfo', 'visualsavailable', self._w,
776776
includeids and 'includeids' or None))
777+
if type(data) is StringType:
778+
data = [self.tk.split(data)]
777779
return map(self.__winfo_parseitem, data)
778780
def __winfo_parseitem(self, t):
779781
"""Internal function."""

0 commit comments

Comments
 (0)