Next: An Extended Tk
Up: Tk: A User
Previous: Widgets and User
wm title . "hi!"
button .hello -text "Hello, World!" -command exit
This shell script, when run, presents the interface
- The window manager is told that the titlebar should read ``hi!''.
- A button widget, .hello, is created with the label
- The geometry manager pack is used to place .hello on
- When all commands have been read, wish enters an
- When the .hello button is pressed, the program terminates
(exit is executed).
CS488/688: Introduction to Interactive Computer Graphics
University of Waterloo
Computer Graphics Lab