Michael's Tcl/Tk Extensions

SourceForge  Powered by SourceForge

There are many extensions to the Tcl/Tk language available, and some of the popular ones like TclX or [incr Tcl] provide similar functionality like these here. Anyway, the packages below are compact and fast, and they work with Tcl 8.0 and higher. Where possible they have been stubs-enabled. The packages are used in several small- to middle-size software projects, some of them running in a production environment.

 mkGeneric 1.3

mkGeneric is a collection of new Tcl commands of general type. There is nothing spectacular about it, but it is lean and fast. It provides useful new math functions, a number of list commands, new loop types, an option parser, commands for sophisticated exception handling , encryption routines and some other things.

mkGeneric Manual
mkGeneric Download

 mkClasses 1.0

mkClasses is a collection of new Tcl commands that provides a(nother) way of object oriented programming with Tcl. With mkClasses, classes and methods can be defined, and objects can be created with private and class-common variables. In addition, classes can inherit the functionality of other classes.

mkClasses Manual
mkClasses Download

 mkTables 1.0

mkTables is a small collection of Tcl commands that allow for operating on tables. The term table simply means regular Tcl lists where each of the elements is itself a proper sublist (identical to what the Tcl command "lsort -index" accepts). The commands in this package provide column oriented manipulations and are in most cases similar to the command names for regular lists: The equivalent to lindex is tindex and so on.

mkTables Manual
mkTables Download

 mkThreads 1.2

mkThreads adds thread support to Tcl scripts. Tcl has been made thread-safe with version 8.1, however there was no equivalent of that great new feature in the Tcl language itself (yet). This package was intented to fill this gap. When it was written, it had some additional features over the "official" thread extension. By now, the latter has developed farther and may be the thread extension of choice for you. For this one, you need a Tcl/Tk version 8.1 or higher that was compiled with thread support. See below if you don't have it. mkThreads 1.2 for Tcl version 8.3.1 uses the improved thread API and is stubs enabled.

mkThreads Manual
mkThreads Download

 mkWidgets 1.3

mkWidgets 1.3 is written in pure Tcl without other package dependencies. It provides a method for defining metawidgets, i.e. widgets that consist of several regular widgets. Metawidgets can be rather complex but behave (almost) like the built-in Tk widgets. In addition, a nice collection of metawidgets is included. Check out the screenshots for Windows and Linux.

mkWidgets Manual
mkWidgets Download

 mkHttpd 1.0

mkHttpd is a compact HTTP server specially designed to be integrated into other applications. While significantly smaller and not as complete as TclHttpd, it has one unique feature: Dynamic page generation is done with what I call TSP, Tcl Server Pages. This is different from TclHttpd's TML concept and much more like Microsoft's ASP, since Tcl and HTML code can be interwoven with each other. This way the code becomes much easier to read.

mkHttpd Manual
mkHttpd Download

 mkZiplib 1.0

mkZiplib is a wrapper for Zlib 1.1.3 and Minizip 0.15. Zlib is a compression library that can be used to create gzip and zip files. It is free, very portable and works for virtually any computer hardware and operating system. With mkZiplib you can compress/decompress data and work with .gz and .zip files from within Tcl.

mkZiplib Manual
mkZiplib Download

 mkTulip 1.0

mkTulip, the Totally Unoptimized Large Integer Processor, evaluates arithmetic and comparison expressions with very long integers. There is virtually no limitation to the number of digits an integer value can have, and there is no 32 or 64 bit boundary and such. Supported operands are *, /, +, -, <, >, <=, >=, ==, and !=.

mkTulip Manual
mkTulip Download

 mkRinterp 1.1

mkRinterp is a package written in pure Tcl. It provides the 'rinterp' command, which is short for 'remote interpreter'. A remote interpreter is created and used like a regular Tcl interpreter (see the interp command), but resides in fact on any host that is running an rinterp server. Through redirection of stdin, stdout and stderr, mkRinterp is a pretty neat and powerful remote control tool. It comes with a set of ready-to-use example applications.

mkRinterp Manual
mkRinterp Download

 mkLibsdl 1.0

mkLibsdl is a wrapper to the SDL library for the joystick and CD-ROM modules. One can query game controllers with joysticks, trackballs, hats and buttons, and also query and play audio CDs with single tracks and frames on a CD-ROM drive. A new event type for joystick events makes working with game controllers fairly easy.

mkLibsdl Manual
mkLibsdl Download

 Other Stuff

If you are using Windows and want to use a thread extension, but your Tcl/Tk version was compiled without thread support (the default, check the global variable tcl_platform(threaded) on existence), then you can download it here:

Tcl/Tk 8.4.3 with thread support for Windows

Matt Newman wrote a Windows NT service that executes any Tcl script upon startup. Since it is so useful, here is it again with a compiled Exe for Tcl 8.4. It now contains Matt's very useful eventlog command, a better shutdown handling and a Tk-based installer.

Windows Service for Tcl 8.4 Scripts

Claudio Esparanca put a lot of work into his TkOgl package. For me this is the best OpenGL extension to Tcl, since it is fairly easy to handle and as intuitive as OpenGL (i.e., not at all, but that's not Claudio's fault ;-)

TkOgl 1.1 for Windows NT4/2000/XP

Editors like UltraEdit and TextPad support syntax highlighting. Here are the files for the two mentioned editors, both including the new commands of the above packages.

Syntax Definitions for UltraEdit and TextPad

Disclaimer

Permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted. The author makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. By use of this software the user agrees to indemnify and hold harmless the author from any claims or liability for loss arising out of such use.

Web Counter  Homepage
  E-Mail