The Personal Web Pages of Chris X. EdwardsA Simplified Tk Reference |
Keyword: | toplevel |
Description: | Almost identical to the behavior of the frame command but it spawns a new window. This is good for message boxes and other subordinate program elements. |
Example: | proc somethinghappens {} { .b configure -state disabled toplevel .t -bg yellow label .t.l -text "Something happened!" button .t.b -text "Ok?" -command { destroy .t ; .b configure -state normal;} pack .t.l .t.b } button .b -text "Do something" -command somethinghappens pack .b |
Official Syntax: |
http://www.scriptics.com/man/tcl8.4/TkCmd/toplevel.htm |
Previous | Home | Next |
This page was created with only free, open-source, publicly licensed software.
This page was designed to be viewed with any browser on any system. | ||
Chris X. Edwards ~ January 2004 |