TkPostage 1.3b


Name

tkpostage - fancy mailbox message counter (like xbiff)

Synopsis

tkpostage [-toolkitoption ...] [-option ...]

Description

tkpostage is a replacement for xbiff and similar programs. It shows a picture similar to a U.S.A. metered stamp with a count of how many messages are in your mail spool. Clicking on this window will bring up a window with one line per mail message, containing the subject and author.

NEW:This version of tkpostage only knows how to read your mail on your local filesystem. Arnaud Taddei at CERN has added all kinds of features, including support for POP, IMAP, and AFS. Check it out.

Downloading

tkpostage is available via anonymous FTP:
ftp://ftp.cs.princeton.edu/pub/people/dwallach/tkpostage-1.3b.tar.gz

Options

tkpostage accepts all of the standard Tk Toolkit command line options along with the additional options listed below:
-help
This option gives the usual wish help summary which isn't really what you want. To get detailed help on tkpostage, use some other unused option, like -foo. This message is printed to standard error.
-delay seconds
This option specifies the frequency in seconds at which tkpostage should check if you have new mail. The default is 2 seconds.
-mailDrop filename
This option specifies the name of the file which should be monitored. By default, it watches /usr/spool/mail/username, where username is your login name, or a number of other typical directories if it can't find /usr/spool/mail. tkpostage will also try your MAILDROP environment variable, if set.
-fg color
This option specifies the foreground color of the postage window. The color is specified in the usual X syntax.
-bg color
This option specifies the background color of the postage window.
+/-flip
This option tells tkpostage to invert its colors when new mail arrives. This is the default behavior. -flip disables flipping, and +flip forces flipping.
+/-beep
This option tells tkpostage to beep when new mail arrives. By default, it's quiet. +beep enables beeping, and -beep disables it. This won't always work, though. See the Bugs section for more details.
+/-paranoid
This option tells tkpostage to watch the file access time on the mail spool, which it normally ignores. +paranoid enables file access time checking, and -paranoid disables it.

For most people, this is unnecessary, but if you think tkpostage isn't rescanning when things change, try this flag out. If you're running more than one copy of tkpostage or other application which accesses your mail spool, and you use the +paranoid option, you may notice a substantial slowdown, or a full rescan every so many seconds. This isn't so much a bug as a problem with checking the file access times.

The following options are intended more for the tinkerer than for general usage. They're included for completeness:

-bitmap bitmap-file
This option specifies the path a different bitmap, if you don't want to use the usual postage meter.
-numberFont font-specification
This option specifies the font to use for the counter.
-numberAnchor anchor-direction
This option specifies the corner from which the following offsets are relative. anchor-direction may be one of c, sw, s, se, e, ne, n, nw, or w.
-numberXOffset integer
This option specifies the x-offset of the counter in the bitmap, relative to the anchor.
-numberYOffset integer
This option specifies the y-offset of the counter in the bitmap, relative to the anchor.
-detailFont font-specification
This option specifies the font to use for the mes- sage details window.
-postageGeometry geometry-spec
This option specifies the geometry of the main postage window.
-detailGeometry geometry-spec
This option specifies the geometry of the message details window. The width and height are specified as numbers of characters rather than pixels, in the same way as xterm's geometry specification.

X Defaults

The application class is the same as the program name (usually ``tkpostage''). Setting a resource like ``tkpostage.beep: true'' is equivalent to running ``tkpostage +beep''. Command line options will override any X resources set.

For convincing your window manager what borders you want on each toplevel window, use ``tkpostage'' to refer to the small postage window, and ``TkPostageDetails'' to refer to the message details window.

For more information about this, see the Bugs section below.

tkpostage understands all of the core resource names and classes that Tk supports as well as resources corresponding to all of the above flags.

X ResourceCommand Line Option
paranoid+/-paranoid
beep+/-beep
flip+/-flip
bitmap-bitmap
delay-delay
mailDrop-mailDrop
foreground-fg (or) -foreground
background-bg (or) -background
numberXOffset-numberXOffset
numberYOffset-numberYOffset
numberAnchor-numberAnchor
numberFont-numberFont
detailFont-detailFont
postageGeometry-postageGeometry
detailGeometry-detailGeometry

Environment

DISPLAY
to get the default host and display number.
MAILDROP
if set, this overrides the usual checks of /usr/spool/mail/username and /usr/mail/username.
XENVIRONMENT
to get the name of a resource file that overrides the global resources stored in the RESOURCE_MANAGER property.

See Also

X(1), xterm(1), xbiff(1), wish(1), Tcl(n), xrdb(1), stat(2)

Bugs

Tk3.3 has a bug with setting the application class of the top-level window. Although Tk3.4 fixed this bug, I'm not going to ``fix'' tkpostage in a way that breaks it under Tk3.3. You can always use the program name (``tkpostage'') as the class, and this works fine.

Tk3.6 and earlier versions don't directly support ringing the X bell. If you're using Tk4.0 or later, the new ``bell'' command is used. Otherwise, the +beep option is a hack which sends a control-G to standard output. If you run tkpostage from a session manager, or some other program not attached to a tty, you won't hear the beep. This won't be a problem under Tk4.0 - just make sure you're using the correct version of wish.

Author

Dan Wallach <dwallach@cs.rice.edu>

Home Page

http://www.cs.rice.edu/~dwallach/tkpostage/

Copyright

Copyright © 1993-1996 Dan Wallach

The X Consortium, and any party obtaining a copy of these files from the X Consortium, directly or indirectly, is granted, free of charge, a full and unrestricted irrevocable, world-wide, paid up, royalty-free, nonexclusive right and license to deal in this software and documentation files (the ``Software''), including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons who receive copies from any such party to do so. This license includes without limitation a license to do the foregoing actions under any patents of the party supplying this software to the X Consortium.

Inspiration

xpostage, by Cliff Herod, Convex Computer Corp, 1989. 128x64 bitmap image (Postage.xbm) used with permission.
Dan Wallach, CS Department, Rice University
Last modified: Sun Nov 22 22:26:20 Central Standard Time 1998