Purpose: Brief intro to Tk [Tk] is a [Tcl] [extension], written in [C], designed to give the user a relatively high level interface to his or her windowing environment. You can find the source code for Tk at http://sourceforge.net/projects/tktoolkit/ . On a Macintosh, Tk provides interfaces to the [MacOS] windowing system. On [Microsoft Windows] 95/98/NT/2000/2003/XP/Vista/..., Tk provides interfaces to the [Microsoft] windowing system. On the other platforms where Tk is available, Tk provides interfaces to the [X] window system using a Tk specific look and feel, designed initially to look uniquely Tk, then, in Tk 8.[[0-4]], updated to look very similar to [Motif], but not using the Motif libraries. Tk was written by [John Ousterhout], the creator of Tcl. A [PostScript] version of the paper introducing Tk to the world can be found at ftp://www.tcl.tk/pub/tcl/doc/tkUsenix91.ps . The PostScript for slides used by Dr. Ousterhout during various [USENIX] tutorials can be found at ftp://www.tcl.tk/pub/tcl/doc/tut.tar.Z . Tk allows you to create, manage, and manipulate '''[widget]s''', rectangular areas on the screen with various features, from which you can build quite powerful [GUI]s with little effort. Some examples of widget types are: * [button] (with text or image): executes a command when clicked * [label] (with text or image): shows info, can be updated from a variable * [text] widget: holds text in various fonts, colors, styles; can also hold embedded images and widgets; can wrap and/or be scrolled * [canvas]: holds graphic objects (including text, images, widgets) * [listbox]: holds text lines from which to select * [scrollbar]: controls the display within another widget through the slider and the 2 arrows at each end. * [scale]: horizontal or vertical, allows setting a numeric value ''[[Isn't [scale] rather similar to [scrollbar], though? Perhaps [menu] would be a better example if showing the breadth of the widget concept.]]'' For sample images, look at [Widgets in the initial Tk package]. [[However, listing the widgets says very little about what Tk ''is;'' every GUI toolbox has a set of built-in widgets. More interesting would be to explain the model for how GUIs are built and operated: the window hierarchy, [geometry managers] (part done below), events, [bind]ing scripts, [bindtags], …]] In Tk, the programmer only needs to specify how the widgets are arranged in a window (layout); the [geometry] of widgets is dynamical, so they respond automatically both to changes in layout and to user resizing of windows. ---- On the titular theme, "Tk" occasionally labels each of * the Tk language, which extends Tcl (that is, is a proper superset) * the Tk library, which is available for applications built in such languages as C, [Perl], and so on * the [wish] [interpreter] which instantiates a Tk console * ... ---- See [Beginning Tk] for more information. ---- There are many [online Tcl and Tk tutorials], perhaps starting with [an overview of tcl and tk]; [Tcl Tutor] is quite popular as a desktop computer aided instruction application. ---- Also of interest might be [Alternate toolkit bindings], [Common Tk Error Messages and Possible Explanations], [Alternate widget sets] ---- See [What is Tcl] for information about the initial language that formed a basis for Tk. ---- !!!!!! [Tk syntax help] - [Arts and crafts of Tcl-Tk programming] %| [Category Tutorial] |% !!!!!!