Version 7 of The list of Tk widgets

Updated 2009-05-26 14:53:46 by LGT

Here is a script to display each widget available in Tk. It made the assumption that all widgets begin with a lowercase letter.

 #
 # the dynamic list of Tk widgets
 # 

 puts " Tk version [package require Tk]"
 puts " ----"

 set tkCommands [lsort [info commands "::tk::\[a-z\]*"]] 

 foreach cmd $tkCommands { 
         puts [string range $cmd 6 end]
 }

 exit 

It gives :

 Tk version 8.5.7
 ----
 button
 canvas
 checkbutton
 entry
 frame
 label
 labelframe
 listbox
 mc
 mcmax
 mcmaxamp
 menubutton
 message
 panedwindow
 radiobutton
 scale
 scrollbar
 spinbox
 text
 toplevel

Category TK