Tkinter. Container Frame

Randall Hopper aa8vb at yahoo.com
Fri Oct 29 10:35:02 EDT 1999


Sergio Palomo:
 |I have a frame that I would like to act as a container of several
 |Toplevel windows.
 |With the below code I get to embed a Toplevel window into the frame, but
 |it does not include the tipical border and the minimize, and maximize
 |window buttons.
 |
 |self.workarea=Frame(self, bd=2,  container=1)
 |self.workarea.pack(fill=BOTH,expand=YES)
 |
 |newwin=Toplevel(use=self.workarea.winfo_id())
 |
 |#contents of new window.....
 |
 |My question if is there any way to make the Toplevels "float" inside the
 |frame. Thank you!

Sounds like you want something like MDI windows from MS Windows. :-)

Check the comp.lang.tcl FAQ and archives for references to MDI.  

Realize that this probably won't port to X/UNIX.  Unlike MSWindows, X gives
you the flexibility to swap in whatever window manager you want.  So unless
there's some back-door communication with this window manager, a child X
client really doesn't know how to draw or implement the native window
manager's decorations.

You could try to do your own window management of top level windows to
approximate MDI, but there are limitations to what you can do (clipping one
with another, etc.).

-- 
Randall Hopper
aa8vb at yahoo.com




More information about the Python-list mailing list