This document describes version 4.1/4.4 of the jstools libraries.
There's a bug in unpatched Tk 3.6 that causes wish(1) to die with a core dump under certain circumstances; you should apply the official patch to Tk, which is available with the Tk sources on the official Tk distribution sites.
There were focusrelated bugs in Tk 4.0b2 (the second beta release) which caused the jstools applications (and some others) to crash frequently; later versions of Tk dowill not suffer from this problem. I think j:dialogue in particular tends to trigger this.
jldb.tcl - localisation support for naturallanguage strings
jdebug.tcl - debugging support
jfileio.tcl - convenience procedures for reading from and writing to files
jinit.tcl - the common
jstools initialisation sequence
jparseargs.tcl - procedures for parsing procedure and application arguments
jprefixmatch.tcl - filename expansion and abbreviation matching procedures
jhistory.tcl - procedures to use persistent (ondisk) history lists
jprefs.tcl - general routines for loading, saving, and using preferences
(see also
jprefpanel.tcl)
jstools.tcl - miscellaneous procedures shared by
jstools applications
jtkutils.tcl - convenience procedures and userinterface layout support
jtclutils.tcl - convenience procedures that don't require Tk
jtkversion.tcl - procedures for writing code compatible with both Tk 3 and
Tk 4
jviewers.tcl - show manual pages or URLs with the user's preferred tools
jmetawidgets.tcl - compound widgets including a colour chooser
joptionbutton.tcl - a button that lets the user choose one of several options
jtext.tcl - wrappers around the text widget's widget command
jtextcmds.tcl - uservisible command procedures for working with text
jabout.tcl - richtext about panels
(see also
jrichtext.tcl)
jalert.tcl - popup notification panels
jconfirm.tcl - a panel asking the user to confirm actions
jfindpanel.tcl - a searchandreplace panel for the text widget
jfs.tcl - a fileselector panel
jmore.tcl - a textdisplay panel
jprefpanel.tcl - a preference panel for setting shared
jstools preferences
jprompts.tcl - procedures to ask the user for various kinds of information
jcommand.tcl - procedures to manage user-invokable commands
jmenu.tcl - procedures to manage menus
(see also
jprompts.tcl,
jinit.tcl, and
jtextcmds.tcl)
jrichtext.tcl - procedures to embed rich text in Tk applications
jtagconvert.tcl - procedures for saving multifont text in various formats
jtexttags.tcl - extensive support for working with tagged text
(see also
jtext.tcl and
jtextcmds.tcl)
Currently, only jbindentry.tcl, jbindtext.tcl, jcompose.tcl, and jlatin1.tcl are documented at all, and they aren't documented very thoroughly. However, the others are not intended to be called directly; they're called by the libraries mentioned above.
jbindentry.tcl - several userselected styles of entry bindings
jbindtext.tcl - several userselected styles of text bindings
(see also
jtext.tcl)
jcompose.tcl - support for the
Compose key
jentrybasic.tcl - support for minimalist bindings
jentryedt.tcl - rudimentary support for EDT bindings
jentryemacs.tcl - support for Emacsstyle entry bindings
jentrykeys.tcl - general support for entry keyboard bindings
jentrymouse.tcl - support for entry mouse bindings
jentryvi.tcl - support for vistyle entry bindings
jlatin1.tcl - additional support for the
Compose key
jtextbasic.tcl - support for minimalist text bindings
jtextedt.tcl - rudimentary support for EDT bindings
jtextemacs.tcl - support for Emacsstyle text bindings
jtextkeys.tcl - support for text keyboard bindings
jtextmouse.tcl - support for text mouse bindings
jtextvi.tcl - support for vistyle text bindings
## begin boiler_header
if {[info exists env(JSTOOLS_LIB)]} {
set jstools_library $env(JSTOOLS_LIB)
} else {
set jstools_library /usr/local/lib/jstools
}
# add the jstools library to the library search path:
set auto_path [concat [list $jstools_library] $auto_path]
# check for ~/.tk and prepend it to the auto_path
# if it exists. that way the user can override
# and customise the jstools libraries.
if {[file isdirectory ~/.tk]} then {
set auto_path [concat [list [glob ~/.tk]] $auto_path]
}
## end boiler_header
You should also call
j:jstools_init early in your code; this reads in global (crossapplication)
preferences, which are used by some of the other libraries, and
automatically sets up bindings for entry and text widgets based
on the user's preferences.
In many places in the libraries, I've borrowed code from other people (with permission); they're mentioned in the documentation files for the individual libraries and in comments in the code itself.
* I'd like to write a library for working with the contents of canvases (e.g. archiving and restoring them).
* I hope to overhaul the Preferences mechanism, which will probably involve new preferences libraries. See the jstools documentation for more about this.
* I'd like to add libraries for popup menus and/or gesture commands. (Actually, popup menu support is provided with Tk 4.0, but gesture commands would still be nice, and they could be combined - dragright could pop up a menu, and dragup could delete text, for instance.)
* I'd like to write a library for interapplication communication,
to help tie the various applications more closely together.
See
the
jstools documentation for
more about this.