From wenbinliu1985 at gmail.com Wed Sep 1 16:32:33 2010 From: wenbinliu1985 at gmail.com (=?GB2312?B?wfXOxLHy?=) Date: Wed, 1 Sep 2010 22:32:33 +0800 Subject: [Tkinter-discuss] Tkinter in interactive mode locks when run from subprocess Message-ID: Hi, In Windows, I made an interactive window by C#, which creates a remote python subprocess to do the interpreting. Communication is done via standard IO redirection. The idea is that the python session is an actual process separate from the GUI, which has some advantages, like I can have multiple such shells in my application, and I can kill them without worrying that my C# app will crash. This all works really, I will also launch C# apps. So I was quite happy, untill I tried doing some plotting with Tkinter. The problem is that the process becomes unresponsive when I do something(more details below) I don't know much about creating subprocess and redirecting standard IO of subprocess and how they are different from a normal process. So can anyone offer some help as to what the problem might be? Thanks in advance, Kaster To get to the details: I use a textbox component of C# to receive the command and then run it as a normal Python console - When I start with command "import Tkinter" -work well,and then command "r = Tkinter.Tk()" problem is arose, a small window pops up, and then whichever command I run in the textbox is not working. I think may be something block the input so that the command cannot transfer to the subprocess of python, but I don't know how to resolve the problem. -------------- next part -------------- An HTML attachment was scrubbed... URL: From charras at me.com Thu Sep 2 05:58:53 2010 From: charras at me.com (Guido Carballo-Guerrero) Date: Wed, 01 Sep 2010 21:58:53 -0600 Subject: [Tkinter-discuss] python 3.1 - tkinter 8.4 - no tile? (Kevin Walzer) In-Reply-To: References: Message-ID: Yes Kevin, I know Snow come with Tk/Tcl 8.5, but for some reason if one install Python with the dmg installer from Python/Download installer, for some reason ttk doesn't use Tcl/Tk 8.5, but 8.4 instead. To make Python use 8.5 one have to compile the source code, with the following lines: $ ./configure --enable-universalsdk --enable-framework $ make $ make frameworkinstall Maybe I'm missing something, but that's how is for me. Guido On Sep 1, 2010, at 4:00 AM, tkinter-discuss-request at python.org wrote: > Send Tkinter-discuss mailing list submissions to > tkinter-discuss at python.org > > To subscribe or unsubscribe via the World Wide Web, visit > http://mail.python.org/mailman/listinfo/tkinter-discuss > or, via email, send a message with subject or body 'help' to > tkinter-discuss-request at python.org > > You can reach the person managing the list at > tkinter-discuss-owner at python.org > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Tkinter-discuss digest..." > Today's Topics: > > 1. Re: python 3.1 - tkinter 8.4 - no tile? (Kevin Walzer) > > From: Kevin Walzer > Date: August 31, 2010 6:25:14 AM GMT-06:00 > To: tkinter-discuss at python.org > Subject: Re: [Tkinter-discuss] python 3.1 - tkinter 8.4 - no tile? > Reply-To: kw at codebykevin.com > > > On 8/31/10 12:15 AM, Guido Carballo-Guerrero wrote: > >> >> I don't understand as well, why the Mac Os x Installer Disk Image don't >> come already with Tk/Tcl 8.5, specially since the Windows installer >> already comes with all that ready, but well. I would even suggest that >> Python should come with ttk. >> >> Those anybody knows what Python doesn't comes already with ttk? Why the >> Mac installer doesn't have Tk/Tcl as part of the installation? > > ttk is standard, I believe, in 3.1, and perhaps 2.7? (Someone correct me here.) > > The Mac installer doesn't include Tcl/Tk because the Mac already ships Tcl/Tk, both 8.5 and 8.4 on Snow Leopard. > > --Kevin > > -- > Kevin Walzer > Code by Kevin > http://www.codebykevin.com > > > > _______________________________________________ > Tkinter-discuss mailing list > Tkinter-discuss at python.org > http://mail.python.org/mailman/listinfo/tkinter-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From kw at codebykevin.com Thu Sep 2 13:49:33 2010 From: kw at codebykevin.com (Kevin Walzer) Date: Thu, 02 Sep 2010 07:49:33 -0400 Subject: [Tkinter-discuss] python 3.1 - tkinter 8.4 - no tile? (Kevin Walzer) In-Reply-To: References: Message-ID: <4C7F8F4D.7020603@codebykevin.com> On 9/1/10 11:58 PM, Guido Carballo-Guerrero wrote: > Yes Kevin, I know Snow come with Tk/Tcl 8.5, but for some reason if one > install Python with the dmg installer from Python/Download installer, > for some reason ttk doesn't use Tcl/Tk 8.5, but 8.4 instead. That's true if you use the Python.org installer. The Python installed with OSX links to 8.5. > > To make Python use 8.5 one have to compile the source code, with the > following lines: > > $ ./configure --enable-universalsdk --enable-framework > $ make > $ make frameworkinstall > > Also true. That's basically how I built mine. Building from source isn't hard. --Kevin -- Kevin Walzer Code by Kevin http://www.codebykevin.com From davecortesi at gmail.com Thu Sep 2 15:34:20 2010 From: davecortesi at gmail.com (David Cortesi) Date: Thu, 2 Sep 2010 15:34:20 +0200 Subject: [Tkinter-discuss] python 3.1 - tkinter 8.4 - no tile? In-Reply-To: <4C7CF4AA.7000004@codebykevin.com> References: <4C7CF4AA.7000004@codebykevin.com> Message-ID: Kevin wrote, > On 9/1/10 11:58 PM, Guido Carballo-Guerrero wrote: > >> Yes Kevin, I know Snow come with Tk/Tcl 8.5, but for some reason if one >> install Python with the dmg installer from Python/Download installer, >> for some reason ttk doesn't use Tcl/Tk 8.5, but 8.4 instead. >> > > That's true if you use the Python.org installer. The Python installed with > OSX links to 8.5. > The Python distributed with OSX is 2.x. If you want to use Python 3.x and install it from the python.org dmg, the same problem arises (the issue that began this thread). Apparently, all versions for OSX must be installed by compiling from source if Tk is to be used. -------------- next part -------------- An HTML attachment was scrubbed... URL: From kw at codebykevin.com Thu Sep 2 15:41:36 2010 From: kw at codebykevin.com (Kevin Walzer) Date: Thu, 02 Sep 2010 09:41:36 -0400 Subject: [Tkinter-discuss] python 3.1 - tkinter 8.4 - no tile? In-Reply-To: References: <4C7CF4AA.7000004@codebykevin.com> Message-ID: <4C7FA990.3080805@codebykevin.com> > The Python distributed with OSX is 2.x. If you want to use Python 3.x and > install it from the python.org dmg, the same problem > arises (the issue that began > this thread). Apparently, all versions for OSX must be installed by > compiling > from source if Tk is to be used. Also true. Apple ships Tk 8.4 mainly for backwards compatibility, and the MacPython maintainers target this version for Tkinter to link to, also for backwards compatibility. I believe ActiveState's Python distribution supports 8.5 on the Mac, by the way. --Kevin -- Kevin Walzer Code by Kevin http://www.codebykevin.com From sridharr at activestate.com Wed Sep 15 05:49:08 2010 From: sridharr at activestate.com (Sridhar Ratnakumar) Date: Tue, 14 Sep 2010 20:49:08 -0700 Subject: [Tkinter-discuss] python 3.1 - tkinter 8.4 - no tile? In-Reply-To: <4C7FA990.3080805@codebykevin.com> References: <4C7CF4AA.7000004@codebykevin.com> <4C7FA990.3080805@codebykevin.com> Message-ID: <4C904234.30805@activestate.com> On 9/2/2010 6:41 AM, Kevin Walzer wrote: > I believe ActiveState's Python distribution supports 8.5 on the Mac, > by the way. Yes, ActivePython 2.6 and 2.7 already does. A new release of ActivePython 3.1 w/ Tcl/Tk 8.5, Mac 64-bit and PyPM is to be expected next week (we have an internal beta build if anyone wants to try it out). -srid From Emmanuel.Devred at dfo-mpo.gc.ca Tue Sep 21 21:22:28 2010 From: Emmanuel.Devred at dfo-mpo.gc.ca (Devred, Emmanuel) Date: Tue, 21 Sep 2010 16:22:28 -0300 Subject: [Tkinter-discuss] (no subject) Message-ID: <3C5CD1F121AC514597A04EE5FDAD3CA0047575D0@marbioexc02.mar.dfo-mpo.ca> Hello, I am a total beginner with python and tkinter and I am having a hard time getting my program working, I think the problem come from passing variables. I would like to have a menu that would with three main buttons, the first one (LUT) let me chosse between two files, the second button (rrs) opens a browser to choose a file and the third button would run a program (or function) that makes some computation between the two files open with button 1 and button 2, Here is what I have written from Tkinter import * from tkFileDialog import askopenfilename import numpy as np class openfile(): def __init__(self, yn): if yn == 0 : self.lut = np.loadtxt("C:\python26\LUTnpdi_chile",dtype=np.float,skiprows=1) if yn == 1 : self.lut = np.loadtxt("C:\python26\LUTnpdi_nwa",dtype=np.float,skiprows=1) if yn == 2 : filename = askopenfilename(filetypes=[("allfiles","*"),("pythonfiles","*.py")]) if yn == 2 : self.lut = np.loadtxt(filename,dtype=np.float,skiprows=1) Class rrs_file(self,rrs): filename = askopenfilename(filetypes=[("allfiles","*"),("pythonfiles","*.py")]) rrs = np.loadtxt(filename,dtype=np.float,skiprows=1) def make_comp(): result = self.lut[1,2] * rrs[1,2] print result def callback(): print "called the callback!" root = Tk() # create a menu menu = Menu(root) root.config(menu=menu) filemenu = Menu(menu) menu.add_cascade(label="LUT", menu=filemenu) filemenu.add_command(label="East Pacific", command=lambda:openfile(0)) filemenu.add_command(label="NW Atlantic", command=lambda:openfile(1)) image_menu = Menu(menu) menu.add_cascade(label="Rrs", command=rrs_file) run_menu = Menu(menu) menu.add_cascade(label="Run", command = make_comp) quitmenu = Menu(menu) menu.add_cascade(label="Quit", command=root.destroy) #x = openfile(2) mainloop() I can not figure out how to pass get the lut and rrs parameters that I have defined in the class objects? I need help !!! Thank you very much in advance. Emmanuel -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgulfirat at gmail.com Wed Sep 22 21:53:23 2010 From: ozgulfirat at gmail.com (Firat Ozgul) Date: Wed, 22 Sep 2010 22:53:23 +0300 Subject: [Tkinter-discuss] (no subject) In-Reply-To: <3C5CD1F121AC514597A04EE5FDAD3CA0047575D0@marbioexc02.mar.dfo-mpo.ca> References: <3C5CD1F121AC514597A04EE5FDAD3CA0047575D0@marbioexc02.mar.dfo-mpo.ca> Message-ID: Hello, I modified your code to make it work: http://paste-it.net/public/m46ae5d/ Certainly, to be able to re-write the code, I made some assumptions and guesses about your original intentions. Just check the code to see if it is close to what you want. Firat 2010/9/21 Devred, Emmanuel > Hello, > I am a total beginner with python and tkinter and I am having a hard time > getting my program working, I think the problem come from passing variables. > > I would like to have a menu that would with three main buttons, the first > one (LUT) let me chosse between two files, the second button (rrs) opens a > browser to choose a file and the third button would run a program (or > function) that makes some computation between the two files open with button > 1 and button 2, > > Here is what I have written > > from Tkinter import * > from tkFileDialog import askopenfilename > import numpy as np > > class openfile(): > def __init__(self, yn): > if yn == 0 : self.lut = > np.loadtxt("C:\python26\LUTnpdi_chile",dtype=np.float,skiprows=1) > if yn == 1 : self.lut = > np.loadtxt("C:\python26\LUTnpdi_nwa",dtype=np.float,skiprows=1) > if yn == 2 : filename = > askopenfilename(filetypes=[("allfiles","*"),("pythonfiles","*.py")]) > if yn == 2 : self.lut = > np.loadtxt(filename,dtype=np.float,skiprows=1) > > Class rrs_file(self,rrs): > filename = > askopenfilename(filetypes=[("allfiles","*"),("pythonfiles","*.py")]) > rrs = np.loadtxt(filename,dtype=np.float,skiprows=1) > > def make_comp(): > result = self.lut[1,2] * rrs[1,2] > print result > > def callback(): > print "called the callback!" > > root = Tk() > > # create a menu > menu = Menu(root) > root.config(menu=menu) > > filemenu = Menu(menu) > menu.add_cascade(label="LUT", menu=filemenu) > filemenu.add_command(label="East Pacific", command=lambda:openfile(0)) > filemenu.add_command(label="NW Atlantic", command=lambda:openfile(1)) > > image_menu = Menu(menu) > menu.add_cascade(label="Rrs", command=rrs_file) > > run_menu = Menu(menu) > menu.add_cascade(label="Run", command = make_comp) > > quitmenu = Menu(menu) > menu.add_cascade(label="Quit", command=root.destroy) > > #x = openfile(2) > > mainloop() > > I can not figure out how to pass get the lut and rrs parameters that I have > defined in the class objects? > > I need help !!! > > Thank you very much in advance. > > Emmanuel > > _______________________________________________ > Tkinter-discuss mailing list > Tkinter-discuss at python.org > http://mail.python.org/mailman/listinfo/tkinter-discuss > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From helengrives at hotmail.com Thu Sep 23 08:55:03 2010 From: helengrives at hotmail.com (=?utf-8?b?SMOobGVu?= Grives) Date: Thu, 23 Sep 2010 06:55:03 +0000 (UTC) Subject: [Tkinter-discuss] tkinter module Message-ID: Hi, I'm a newbie in programming (2 weeks) and I use a windows vista 32 computer. I've currently installed the phyton - 3.2.a2.msi file. Previciously I used versions 2.7 and 3.0 and 3.1.2. But no one gets the tkinter module to start. All the previous releases are uninstalled. However I don't know how to get around this problem quickly. My goal is to go back to the last 3.1.2 version and get it to work properly. I hope you have any suggestions that are not too difficult without a lot of knowledge. From ozgulfirat at gmail.com Thu Sep 23 09:48:19 2010 From: ozgulfirat at gmail.com (Firat Ozgul) Date: Thu, 23 Sep 2010 10:48:19 +0300 Subject: [Tkinter-discuss] tkinter module In-Reply-To: References: Message-ID: Hello, Until Python's 3.0 version, the name of the Tkinter module was "Tkinter". Therefore we used to import this module as: >>> import Tkinter Starting from Python 3.0, the name of this module is "tkinter". So you should issue the following command to import the module: >>> import tkinter Normally, Tkinter module is part of the Windows Python installer. You do not need to install anything special to make Tkinter work under Windows. Just tell us what the output of this command in your system is: >>> import sys >>> sys.version 2010/9/23 H?len Grives > Hi, > > I'm a newbie in programming (2 weeks) and I use a windows vista 32 > computer. > I've currently installed the phyton - 3.2.a2.msi file. Previciously I used > versions 2.7 and 3.0 and 3.1.2. But no one gets the tkinter module to > start. All > the previous releases are uninstalled. However I don't know how to get > around > this problem quickly. My goal is to go back to the last 3.1.2 version and > get it > to work properly. I hope you have any suggestions that are not too > difficult > without a lot of knowledge. > > _______________________________________________ > Tkinter-discuss mailing list > Tkinter-discuss at python.org > http://mail.python.org/mailman/listinfo/tkinter-discuss > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Vasilis.Vlachoudis at cern.ch Thu Sep 30 09:30:27 2010 From: Vasilis.Vlachoudis at cern.ch (Vasilis Vlachoudis) Date: Thu, 30 Sep 2010 09:30:27 +0200 Subject: [Tkinter-discuss] Correct order for dialog display Message-ID: <4CA43C93.4030103@cern.ch> Dear all, In my application I have several custom made Toplevel windows when they close they remember their position and size, so the next time to open them using with the same geometry. Therefore in the show method I have the following sequence def show(self): self.deiconify() self.geometry("%dx%d+%d+%d", self.width, self.height, self.x, self.y) self.wait_visibility() In my linux Fedora-13, Ubuntu 10.04 etc.. works Ok. However on Mac, Fedora-13 through a virtual machine (VirtualBox) or over the network the geometry card seems to be ignored. The window appears to be where the window manager likes with size whatever Tk likes If I change the order like self.wait_visibility() self.geometry("...") then it works on all systems, BUT first it displays the window where the window manager likes with the standard size that Tk calculates AND THEN it move&resize to the correct position. On fast machines is not a problem, but on slow machines or X11 over the network it becomes annoying. So my question is: if I want to position and resize a Toplevel window (before it is shown), so when it is displayed to have the dimensions/position that I choose, what is the correct order of commands to use in order to work in all systems? Thanks in advance Vasilis From klappnase at web.de Thu Sep 30 11:38:54 2010 From: klappnase at web.de (Michael Lange) Date: Thu, 30 Sep 2010 11:38:54 +0200 Subject: [Tkinter-discuss] Correct order for dialog display In-Reply-To: <4CA43C93.4030103@cern.ch> References: <4CA43C93.4030103@cern.ch> Message-ID: <20100930113854.b3b439b6.klappnase@web.de> Hi, Thus spoketh Vasilis Vlachoudis unto us on Thu, 30 Sep 2010 09:30:27 +0200: > Dear all, > > In my application I have several custom made Toplevel windows when they > close they remember their position and size, so the next time to open > them using with the same geometry. > > Therefore in the show method I have the following sequence > > def show(self): > self.deiconify() > self.geometry("%dx%d+%d+%d", self.width, self.height, self.x, > self.y) > self.wait_visibility() > You might try to change your func like this: def show(self): self.withdraw() self.geometry("%dx%d+%d+%d", self.width, self.height, self.x,self.y) self.update_idletasks() self.deiconify() This way you should be able to avoid the ugly visible resizing, at least I have used this successfully on X, I don't have any experience with VirtualBox, though. I hope this helps Michael .-.. .. ...- . .-.. --- -. --. .- -. -.. .--. .-. --- ... .--. . .-. The only solution is ... a balance of power. We arm our side with exactly that much more. A balance of power -- the trickiest, most difficult, dirtiest game of them all. But the only one that preserves both sides. -- Kirk, "A Private Little War", stardate 4211.8 From Vasilis.Vlachoudis at cern.ch Thu Sep 30 16:11:22 2010 From: Vasilis.Vlachoudis at cern.ch (Vasilis Vlachoudis) Date: Thu, 30 Sep 2010 16:11:22 +0200 Subject: [Tkinter-discuss] Correct order for dialog display In-Reply-To: <20100930113854.b3b439b6.klappnase@web.de> References: <4CA43C93.4030103@cern.ch> <20100930113854.b3b439b6.klappnase@web.de> Message-ID: <4CA49A8A.9040803@cern.ch> Thank you Michael for the suggestion, I don't understand why you are using the withdraw() before. Now on my linux, it pops up the window (with Tk dimensions) then it remove it and then it displays it correctly with my dimensions. Cheers Vasilis On 09/30/10 11:38, Michael Lange wrote: > Hi, > > Thus spoketh Vasilis Vlachoudis > unto us on Thu, 30 Sep 2010 09:30:27 +0200: > >> Dear all, >> >> In my application I have several custom made Toplevel windows when they >> close they remember their position and size, so the next time to open >> them using with the same geometry. >> >> Therefore in the show method I have the following sequence >> >> def show(self): >> self.deiconify() >> self.geometry("%dx%d+%d+%d", self.width, self.height, self.x, >> self.y) >> self.wait_visibility() >> > You might try to change your func like this: > > def show(self): > self.withdraw() > self.geometry("%dx%d+%d+%d", self.width, self.height, self.x,self.y) > self.update_idletasks() > self.deiconify() > > This way you should be able to avoid the ugly visible resizing, at least > I have used this successfully on X, I don't have any experience with > VirtualBox, though. > > I hope this helps > > Michael > > > .-.. .. ...- . .-.. --- -. --. .- -. -.. .--. .-. --- ... .--. . .-. > > The only solution is ... a balance of power. We arm our side with exactly > that much more. A balance of power -- the trickiest, most difficult, > dirtiest game of them all. But the only one that preserves both sides. > -- Kirk, "A Private Little War", stardate 4211.8 > _______________________________________________ > Tkinter-discuss mailing list > Tkinter-discuss at python.org > http://mail.python.org/mailman/listinfo/tkinter-discuss -- ------------------------------------------------------- Vasilis Vlachoudis Dep. EN-STI-EET Web: home.cern.ch/bnv Tel: +41-22-7679851 Fax: +41-22-7669644 ------------------------------------------------------- From bob at greschke.com Thu Sep 30 17:06:49 2010 From: bob at greschke.com (Bob Greschke) Date: Thu, 30 Sep 2010 11:06:49 -0400 Subject: [Tkinter-discuss] Correct order for dialog display In-Reply-To: <4CA49A8A.9040803@cern.ch> References: <4CA43C93.4030103@cern.ch> <20100930113854.b3b439b6.klappnase@web.de> <4CA49A8A.9040803@cern.ch> Message-ID: <020AB37D-E1F2-4FD0-B81D-F6EC0C2C0434@greschke.com> The .withdraw() should be right after the statement that creates the Toplevel window. Creating it, then making the call to this def show() is giving the system time to make the window visible. If the Toplevel() and the .withdraw() are together the window doesn't show up until the .deiconify(). On 2010-09-30, at 10:11, Vasilis Vlachoudis wrote: > Thank you Michael for the suggestion, > > I don't understand why you are using the withdraw() before. > Now on my linux, it pops up the window (with Tk dimensions) then it remove it and then it displays it correctly with my dimensions. > > Cheers > Vasilis > > > On 09/30/10 11:38, Michael Lange wrote: >> Hi, >> >> Thus spoketh Vasilis Vlachoudis >> unto us on Thu, 30 Sep 2010 09:30:27 +0200: >> >>> Dear all, >>> >>> In my application I have several custom made Toplevel windows when they >>> close they remember their position and size, so the next time to open >>> them using with the same geometry. >>> >>> Therefore in the show method I have the following sequence >>> >>> def show(self): >>> self.deiconify() >>> self.geometry("%dx%d+%d+%d", self.width, self.height, self.x, >>> self.y) >>> self.wait_visibility() >>> >> You might try to change your func like this: >> >> def show(self): >> self.withdraw() >> self.geometry("%dx%d+%d+%d", self.width, self.height, self.x,self.y) >> self.update_idletasks() >> self.deiconify() >> >> This way you should be able to avoid the ugly visible resizing, at least >> I have used this successfully on X, I don't have any experience with >> VirtualBox, though. >> >> I hope this helps >> >> Michael >> >> >> .-.. .. ...- . .-.. --- -. --. .- -. -.. .--. .-. --- ... .--. . .-. >> >> The only solution is ... a balance of power. We arm our side with exactly >> that much more. A balance of power -- the trickiest, most difficult, >> dirtiest game of them all. But the only one that preserves both sides. >> -- Kirk, "A Private Little War", stardate 4211.8 >> _______________________________________________ >> Tkinter-discuss mailing list >> Tkinter-discuss at python.org >> http://mail.python.org/mailman/listinfo/tkinter-discuss > > -- > ------------------------------------------------------- > Vasilis Vlachoudis > Dep. EN-STI-EET > Web: home.cern.ch/bnv > Tel: +41-22-7679851 > Fax: +41-22-7669644 > ------------------------------------------------------- > > _______________________________________________ > Tkinter-discuss mailing list > Tkinter-discuss at python.org > http://mail.python.org/mailman/listinfo/tkinter-discuss > From klappnase at web.de Thu Sep 30 18:17:28 2010 From: klappnase at web.de (Michael Lange) Date: Thu, 30 Sep 2010 18:17:28 +0200 Subject: [Tkinter-discuss] Correct order for dialog display In-Reply-To: <020AB37D-E1F2-4FD0-B81D-F6EC0C2C0434@greschke.com> References: <4CA43C93.4030103@cern.ch> <20100930113854.b3b439b6.klappnase@web.de> <4CA49A8A.9040803@cern.ch> <020AB37D-E1F2-4FD0-B81D-F6EC0C2C0434@greschke.com> Message-ID: <20100930181728.e4bf57c9.klappnase@web.de> Hi, Thus spoketh Bob Greschke unto us on Thu, 30 Sep 2010 11:06:49 -0400: > The .withdraw() should be right after the statement that creates the > Toplevel window. Creating it, then making the call to this def show() > is giving the system time to make the window visible. If the Toplevel > () and the .withdraw() are together the window doesn't show up until > the .deiconify(). > This does actuallly not happen here (with IceWm), unless update_idletasks () or update() are called somewhere in between, maybe it's Wm dependent behavior? Anyway, in real world code you are surely right, withdraw() should be called right after window creation. regards Michael .-.. .. ...- . .-.. --- -. --. .- -. -.. .--. .-. --- ... .--. . .-. Too much of anything, even love, isn't necessarily a good thing. -- Kirk, "The Trouble with Tribbles", stardate 4525.6 From lionkimbro at gmail.com Thu Sep 30 20:47:46 2010 From: lionkimbro at gmail.com (Lion Kimbro) Date: Thu, 30 Sep 2010 11:47:46 -0700 Subject: [Tkinter-discuss] Visual (8-bit!) tkinter Cheatsheets Message-ID: Hi all, For many reasons, but mainly just for fun, I made some tkinter documentation in pixel graphics. I'd like to share what I made, here it is..! [image: grid_layout.png][image: button.png] It's pretty exhausting work, making letters pixel by pixel, but I like the results (assuming you can even see them.) If I receive encouragement and interesting criticism, I think I'll be motivated to make a few more. {:)}= I think next, I want to document row & column configuration on the Grid, and perhaps how Images work. Please feel free to share these however you like. Take care, Lion (If the images don't go through the mail, here are two URLs to them: http://twitpic.com/2t4n9p/full http://twitpic.com/2t4n9q/full ) -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: button.png Type: image/png Size: 4287 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: grid_layout.png Type: image/png Size: 5995 bytes Desc: not available URL: From barry.griffin at hiq.se Thu Sep 30 21:02:42 2010 From: barry.griffin at hiq.se (Baz79) Date: Thu, 30 Sep 2010 12:02:42 -0700 (PDT) Subject: [Tkinter-discuss] Callback when insertion cursor moves Message-ID: <29851368.post@talk.nabble.com> Hi there, I have two text widgets. I have managed to program these so that they can be scrolled by the same scroll bars. However, if I move the cursor position in one widget, how can I get it to also move in the other widget? Thanks for your help, Barry -- View this message in context: http://old.nabble.com/Callback-when-insertion-cursor-moves-tp29851368p29851368.html Sent from the Python - tkinter-discuss mailing list archive at Nabble.com. From barry.griffin at hiq.se Thu Sep 30 22:51:51 2010 From: barry.griffin at hiq.se (Baz79) Date: Thu, 30 Sep 2010 13:51:51 -0700 (PDT) Subject: [Tkinter-discuss] How do I delete the current line in a Text widget Message-ID: <29852273.post@talk.nabble.com> What arguments should delete() take in order to delete the current line? Thanks, Barry -- View this message in context: http://old.nabble.com/How-do-I-delete-the-current-line-in-a-Text-widget-tp29852273p29852273.html Sent from the Python - tkinter-discuss mailing list archive at Nabble.com.