What's HTk?
HTk is an encapsulation of the graphical user interface
toolkit and library Tcl/Tk for the functional
programming language Haskell. It allows the creation
of high-quality graphical user interfaces within Haskell in a
typed, abstract, and portable manner, as HTk is
known to run under Linux, Solaris, FreeBSD, Windows 98, Windows 2k, and
will probably run under many other POSIX systems as well.
Features include
- abstract event handling,
- support of nearly all of Tk's features:
- the usual GUI elements such as buttons, menus, list
boxes, &c;
- canvasses to draw on;
- text widgets for hypertext and forms;
- a toolkit of useful interface elements and dialog
windows,
- support for Tix,
the Tk Interace eXtension, with features such as
notebooks and paned windows.
HTk is easy to use; for example, here is the infamous
incrementing button example:
module Main where
import HTk
main :: IO ()
main =
do main <- initHTk []
b <- newButton main [text "*"]
pack b []
cl <- clicked b
let count :: Int-> Event ()
count n =
do cl >>> (b # text n)
count (n+1)
spawnEvent (count 1)
finishHTk
Download and Documentation
Here, you can
System requirements
You'll need the following software to run HTk:
- The Glasgow Haskell
Compiler, Version 5.02.3 or later;
- Tcl/Tk
(Version 8.0 or later; 8.1.1 or later for Windows) or
Tix;
- An operating system on which these two run, such as
- Windows 98 or 2000 or similar, or
- Linux, FreeBSD or Solaris (other POSIX-systems may work as well)
Problems and Troubleshooting
If you have trouble with HTk, please do not hesitate to get
in touch with us (see below). We will try to help, but we can only
fix problems that we know about.
We keep a list of known problems here.
Current Status
Currently, HTk is "orphanware" - while still being used
and e.g. ported to later versions of the GHC if it is not too
much trouble, it is not actively developed, and new releases are
sparse. Its future prospects are uncertain. Use at your own peril.
Contact and Authors
If you have any questions or request, please get in touch with us
at uniform@informatik.uni-bremen.de.
The principal designer of HTk was Einar Karlsen, based on
GoferTk. The event handling is due to George Russell. Andree
Lüdtke, together with Christoph Lüth, ported HTk to its
present form.
Christoph Lueth
Last modified: Wed Mar 22 16:11:08 CET 2006