{The jstools Application Suite

Introduction
The jstools package is a suite of applications based on a common set of libraries.  The applications share a set of libraries, so they have a consistent look­and­feel.  They are extensively customisable, both through startup scripts and through a preferences mechanism.  They are written in wish(1), an graphical shell based on the Tk toolkit and the Tcl scripting language (all three by John Ousterhout of Sun Microsystems).

This document describes version 4.0/4.0 of the jstools package.

Compatibility
Version 4.0/4.0b of the jstools application suite is compatible with Tk 4.0p1 and Tcl 7.4p1 or Tk 4.0p2 and Tcl 7.4p2; it may work properly with other versions, but then again, it might not.  I have tested the jstools applications lightly under Tk 3.6, and they appear to work.

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 focus­related bugs in Tk 4.0b2 (the second beta release) which caused the jstools applications (and some others) to crash frequently; later versions of Tk do not suffer from this problem.

Changes
See jstools changes since 3.6/3.0 for a change log (including pointers to earlier changes).

Applications
The jstools package currently includes the following chief applications:

jabbrevs - an abbreviation manager (used by jedit)
jbrowser - a directory browser
jdoc - a documentation viewer, which you are presumably using to read this
jedit - an multi­mode, multi­window text editor
jmore - a file viewer, essentially a graphical analogue to more(1)
jprefs - a tool to set preferences shared by the jstools applications

The jedit editor can also be embedded in other Tk applications (and jmore and jprefs are really just wrappers around library procedures, so they can as well).  I hope to add this capability to the other applications in the future.

Shell Utilities
The following little applications are also included.  They are essentially wrappers around particular library routines, intended to make jstools panels available from shell scripts, window­manager configuration files, etc.

jalert - display an alert panel
jcolname - prompt for a colour name
jcolrgb - prompt for a colour by RGB values
jconfirm - ask user for confirmation
jfs - allow user to select a file
jprompt - ask user to supply a string

Unsupported Applications and Demos
There are also a few toy or demonstration applications distributed as part of jstools. Some of these are applications that aren't yet robust or functional enough to be considered production­quality, but which I intend to further develop; others are simply proof­of­concept or special­purpose hacks.  These include:

jcalendar - a tool to edit and print calendar data in xcalendar(1) format
jhotlist - a tool to manage hotlists for an old version of NCSA Mosaic
jlaunchpad - a menu of applications and remote hosts, similar to SGI's toolchest.
jmsgs - a graphical analogue to the Berkeley msgs(1) command
jnewbrowser - a preview of the appearance of the next version of jbrowser
jpeople - an address­list and email alias manager
jperson - a command­line interface to the jpeople database
jrtgrep - search for a regular expression in a .jrt or .jdoc document

Usage
Assuming jstools has been installed normally at your site, you shouldn't need to do anything special to use the applications, beyond making sure they're in your PATH.  However, you can set the environment variable JSTOOLS_LIB to specify the directory that holds the jstools libraries.  (This is normally /usr/local/jstools/lib or a location chosen by the person who installed jstools at your site.)  You may want to do this if you have jstools in your own home directory for personal use, or to test jstools out before installing it.

For specific information on using or invoking particular applications, see the documentation for the individual application (referenced above under Applications).

Credits and Copyright
Author
Jay Sekora 
js@calumet.org
http://shore.net/~js/

Copyright
The jstools distribution (applications, libraries, and support files) is copyright © 1992-1995 by Jay Sekora, but may be freely copied and modified for any purpose under the conditions spelled out in the copyright notices at the top of each code file.

Thanks
Most importantly, I'd like to thank John Ousterhout <ouster@tcl.eng.sun.com>, the author of Tk and Tcl, for providing such a wonderful, robust, simple language for writing X Windows applications, and the Tcl community which has helped extend Tk and Tcl without forcing them to succumb to feature bloat.

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.

Preferences
The jstools applications (and other applications written with the jstools libraries) share a set of global preferences.  These preferences can be set from within jstools applications through the Global Preferences panel, or with the jprefs application, (which is just a wrapper around the Global Preferences panel).  Most jstools applications also provide application­specific preferences which can be set with an application­specific preferences panel.

Global preferences are saved in the file ~/.tk/defaults, which is in the standard X Windows resource format.  (For more information on this format, see X(1), particularly the section RESOURCES, and option(n), particularly the section on option readfile.)  Most jstools applications save their application­specific preferences in the same format in the file ~/.tk/application-defaults, where application is the name of the particular application, but some may save them someplace else and/or in some other format.

Future Directions
* I intend to move more code from other applications into separate libraries.

* I intend to make jdoc (at least, and perhaps other applications as well) embeddable.

* I hope to overhaul the Preferences mechanism.  I'd like to have some system similar to that in Brent Welch's exmh application, where preferences are organised into categories.  I'd like a central preference panel to list the categories, and for each application to be able to add categories, instead of having separate global and application­specific panels.  Also,  I'd like to add an interface for editing all the standard Tk appearance resources, as described in options(n), so users don't have to edit defaults files by hand to adjust fonts, colours, relief options, etc.

* I'd like to add a notecard­browser application, for typing and searching through lots of short notes - an electronic card file.

* I'd like to add a basic sketching program.  (It would be nice if drawings created by it could be included in jedit documents.)

* I'd like to have some of the applications dynamically communicate among each other.  For instance, as soon as you add an abbreviation with jabbrevs, it should be available in all your jedit sessions.  Global preferences you change in one application should be reflected in all your running jstools applications.  And perhaps various applications could communicate among each other to decide where to put their windows, so windows overlap as little as possible.
} {{{jdoc:xref:link {4.107 4.125 4.245 4.268 16.4 16.33 21.0 21.8 21.44 21.49 22.0 22.8 23.0 23.4 24.0 24.5 25.0 25.5 26.0 26.6 26.23 26.69 28.4 28.9 28.29 28.37 28.68 28.73 28.78 28.84 33.0 33.6 34.0 34.8 35.0 35.7 36.0 36.8 37.0 37.3 38.0 38.7 53.262 53.283 55.148 55.160 72.62 72.83 72.100 72.118 72.191 72.219 72.233 72.239 79.19 79.23 81.21 81.46 85.111 85.116 87.141 87.149 87.186 87.191}} {jdoc:xref:manpage {4.291 4.295 11.46 11.50 25.59 25.63 43.54 43.63 46.45 46.49 74.152 74.153 74.198 74.204 81.468 81.475}} {jdoc:anchor:anchorname {3.0 4.0 18.0 19.0 52.0 53.0 57.0 57.21 71.0 72.0 81.0 81.47 87.0 87.85}} {richtext:font:roman {2.0 3.0 4.0 4.4 4.11 4.291 4.295 6.47 6.54 8.0 9.0 9.24 9.31 9.122 9.125 9.210 9.217 11.46 11.50 13.85 13.92 15.0 16.0 16.4 16.33 18.0 19.0 19.4 19.11 21.0 21.8 21.44 21.49 21.50 22.8 23.0 23.4 24.0 24.5 25.0 25.5 25.59 25.63 26.0 26.6 26.49 26.56 28.4 28.9 28.68 28.73 28.78 28.84 30.0 30.15 31.137 31.144 33.0 33.6 34.0 34.8 35.0 35.7 36.0 36.8 37.0 37.3 38.0 38.7 40.0 40.34 41.78 41.85 43.0 43.9 43.54 43.63 44.0 44.8 45.0 45.10 45.71 45.80 46.0 46.5 46.45 46.49 47.0 47.11 47.65 47.73 48.0 48.7 49.0 49.7 49.42 49.49 50.0 50.7 50.47 50.51 50.55 50.60 52.0 53.0 53.9 53.16 53.161 53.165 53.214 53.225 53.266 53.273 53.304 53.326 53.376 53.383 53.436 53.443 53.500 53.507 55.148 55.160 57.0 57.21 58.0 58.6 60.0 60.14 61.0 61.21 63.0 63.9 64.4 64.11 66.0 66.6 67.52 67.76 71.0 72.0 72.4 72.11 72.66 72.73 72.162 72.169 72.233 72.239 72.322 72.329 74.41 74.55 74.152 74.153 74.183 74.192 74.198 74.204 74.237 74.252 74.261 74.268 74.357 74.383 74.391 74.402 76.0 77.0 79.19 79.23 81.111 81.115 81.468 81.475 85.111 85.116 87.141 87.149 87.186 87.191 87.292 87.299 88.0}} {richtext:font:italic {9.122 9.125 74.391 74.402}} {richtext:font:bold {4.4 4.11 6.47 6.54 9.24 9.31 9.210 9.217 13.85 13.92 19.4 19.11 26.49 26.56 31.137 31.144 41.78 41.85 53.9 53.16 53.266 53.273 53.304 53.326 53.376 53.383 53.436 53.443 53.500 53.507 64.4 64.11 72.4 72.11 72.66 72.73 72.162 72.169 72.322 72.329 74.41 74.55 74.183 74.192 74.261 74.268 74.357 74.363 74.374 74.383 87.292 87.299}} {richtext:font:bolditalic {16.4 16.33 55.148 55.160 74.363 74.374}} {richtext:font:typewriter {4.291 4.295 11.46 11.50 21.0 21.8 21.44 21.49 21.50 22.8 23.0 23.4 24.0 24.5 25.0 25.5 25.59 25.63 26.0 26.6 28.4 28.9 28.68 28.73 28.78 28.84 33.0 33.6 34.0 34.8 35.0 35.7 36.0 36.8 37.0 37.3 38.0 38.7 43.0 43.9 43.54 43.63 44.0 44.8 45.0 45.10 45.71 45.80 46.0 46.5 46.45 46.49 47.0 47.11 47.65 47.73 48.0 48.7 49.0 49.7 49.42 49.49 50.0 50.7 50.47 50.51 50.55 50.60 53.161 53.165 53.214 53.225 60.0 60.14 61.0 61.21 67.52 67.76 72.233 72.239 74.152 74.153 74.198 74.204 74.237 74.252 79.19 79.23 81.111 81.115 81.468 81.475 85.111 85.116 87.141 87.149 87.186 87.191}} {richtext:font:heading0 {1.0 2.0}} {richtext:font:heading1 {3.0 4.0 18.0 19.0 52.0 53.0 57.0 57.21 71.0 72.0 76.0 77.0}} {richtext:font:heading2 {8.0 9.0 15.0 16.0 30.0 30.15 40.0 40.34 58.0 58.6 63.0 63.9 66.0 66.6}} {jdoc:manpage:more {25.59 25.63}} {jdoc:manpage:xcalendar {43.54 43.63}} {jdoc:manpage:msgs {46.45 46.49}} {jdoc:link:#Preferences {4.245 4.268 81.21 81.46}} {jdoc:anchorname:Applications {18.0 19.0}} {jdoc:anchorname:Introduction {3.0 4.0}} {jdoc:link:jslibraries.jdoc {4.107 4.125 53.262 53.283 72.62 72.83}} {jdoc:link:jabbrevs.jdoc {21.0 21.8 87.141 87.149}} {jdoc:link:jbrowser.jdoc {22.0 22.8}} {jdoc:link:jdoc.jdoc {23.0 23.4 79.19 79.23}} {jdoc:link:jedit.jdoc {21.44 21.49 24.0 24.5 28.4 28.9 85.111 85.116 87.186 87.191}} {jdoc:link:jmore.jdoc {25.0 25.5 28.68 28.73}} {jdoc:link:jprefs.jdoc {26.0 26.6 28.78 28.84 72.233 72.239}} {jdoc:anchorname:Usage {52.0 53.0}} {jdoc:anchorname:Preferences {71.0 72.0}} {jdoc:manpage:option {74.198 74.204}} {jdoc:manpage:X {74.152 74.153}} {jdoc:manpage:options {81.468 81.475}} {jdoc:link:#Applications {55.148 55.160}} {jdoc:manpage:wish {4.291 4.295 11.46 11.50}} {jdoc:anchorname:Preferences_futures {81.0 81.47}} {jdoc:anchorname:interapplication_communication {87.0 87.85}} {jdoc:link:panels/prefs.jdoc {26.23 26.69 72.100 72.118 72.191 72.219}} {jdoc:anchorname:Credits_and_Copyright {57.0 57.21}} {jdoc:link:jedit_prog.jdoc#Embedding_jedit_in_Other_Applications {28.29 28.37}} {jdoc:link:jalert.jdoc {33.0 33.6}} {jdoc:link:jcolname.jdoc {34.0 34.8}} {jdoc:link:jcolrgb.jdoc {35.0 35.7}} {jdoc:link:jconfirm.jdoc {36.0 36.8}} {jdoc:link:jfs.jdoc {37.0 37.3}} {jdoc:link:jprompt.jdoc {38.0 38.7}} {jdoc:link:jstools/jstools-changes-4.0.jdoc {16.4 16.33}}} {{abbrevstart 4.303} {matchend 75.0} {richptr 9.277} {abbrevend 4.318} {insert 1.0} {anchor 1.0} {matchstart 75.0} {emacs_mark 88.0} {current 1.0}}}