Version 0 of wm title

Updated 2002-03-26 11:41:09

Subcommand of wm to query or set the title of a toplevel window. For editor-like apps, it is convenient to put the current file name into the title bar:

 wm title $w $filename

or, combined with the app name (Windows look & feel):

 wm title $w "$filename - $appname"

You can even retrieve the filename from there with regexp, avoiding a global variable:

 regexp "(.+) - $appname" [wm title $w] -> filename ;# RS

Tk syntax help - Category Command