
            ------------------------------------------------



                   PlutHeadit - Message Header Editor


                       (c) Copyright 31-Jan-1993


                              Version 1.1


                  By Peter Deane  3:622/401.0@FidoNet


                      Written in GFA-Basic V 3.51


            ------------------------------------------------



                              ===========
                              Description
                              ===========


PlutHeadit is a specialised program which will edit 2d and 4d FTS-1
*.MSG file HEADERS (the first 190 bytes) in a very convenient
point-and-click manner.  Now, if you forget to file attach a file, or
address a message to the wrong person, or forget to mark a message as
crash, or any of a host of other misadventures, you'll be able to fix
this up quickly and simply, with PlutHeadit (the Header-Editor).

While PlutHeadit replaces NewZap (or similar binary file editor) for the
message headers, you will still need a good text editor for actually
changing the body of the text.


                               ==========
                               Invocation
                               ==========


You MUST HAVE a copy of traplist.library (any version) around before
this program will run.  I won't include this in the distribution.  Look
in the TrapDoor archive for a copy of Traplist.library.

PlutHeadit can be invoked from the command line (or called by an
external menu, eg off Chameleon or Directory Opus to name but two).  It
understands 2 command line arguments.

Some message tossing programs (most?) do NOT store messages in 4d mode.
PlutHeadit caters for this by also running in 2d mode.  To run
PlutHeadit in 2d mode, simply include use the "2D" (not case-sensitive)
switch in the command line.  (EG "Run PlutHeadit 2D").  As you might
expect "PlutHeadit 4d" will cause it to operate in 4d mode.

Note that PlutHeadit runs in 4d mode by default.

You may also now tell PlutHeadit what filename to use.  It must be
longer than 2 characters long (to distinguish it from the 2d/4d switch),
and will, be opened up in PlutHeadit if the filename specified is
available.  (If the message does not load, choose the "LOAD" gadget to
load another one).

The order of the 2d/4d switch and filename should not matter in the
command line.  Feel free to specify them either way around.

If no filename is given on the command line, a file requester will be
brought up for you to enter a filename, or to change directories, etc.
Don't forget you can always choose LOAD, SAVE, QUIT or RELOAD at any
time.

It becomes immediately apparent when you have a message header loaded,
and then you can go to work and change just about ANYTHING in the header
in a point-and-click user-friendly way.


Some command line examples:


PlutHeadit 2d Mail:Echo/AMIGA/3456.MSG

        [edit 3456.MSG in the AMIGA directory in 2 d mode]

PlutHeadit Mail:Echo/AMIGA/3456.MSG 4d

        [edit 3456.MSG in the AMIGA directory in 4 d mode]

PlutHeadit 2d

        [Runs program in 4d mode, will ask for filename]

PlutHeadit Mail:Matrix/546.MSG

        [Load up 546.MSG from Matrix. (In 4d mode by default)]



                          ===================
                          Compatible Software
                          ===================


PlutHeadit works with 2d and 4d FTS-1 messages.

It will NOT work with:

* Foozle messages, unless you have selected Confmail mode.

* Integrated packages using squish-type message bases
  (eg Spot, April and PointManager).


------------------
It WILL work with:
------------------

* Messages that you use GCC, Chameleon, RMB, Plutonic, etc to work with.

* It is particularly useful for anyone with TrapToss v1.50+, because
  it supports the full 4d message storage available there.


     ***********************************************
     **                                           **
     **  * StarNet/Paragon messages (in 2d mode)  **  <==  YEP!
     **                                           **
     ***********************************************



Any further question of compatibility should be directed to the author,
with perhaps a sample message file or two uuencoded into a netmail
message addressed to him.

IMPORTANT:  Under NO circumstances is the author liable to any damages
from the use or misuse of this program.  Before you click on the save
gadget, make SURE that PlutHeadit seems to have understood what the
message actually was.  If the Destination and Origin node numbers seem
okay, then it's a good sign.

If the Zone and Point field in the address fields look AWFULLY LARGE,
chances are you are editing a 2d message only and you have PlutHeadit
working in 4d mode.  Switch to 2d mode by using the relevant command
line switch

But it's YOUR data, and you use this program at your own risk!  Backup
the message first if it's important!


                           =================
                           Using the program
                           =================


Headit opens an 8 colour 640 * 200 screen and a window covering most of
it.  It will attempt to load a message from a directory called
"Mail:Matrix".  If you don't want this path, simply click in the path
gadget of the file requester, and type your own, ending with a trailing
slash or colon.  Beware of the GFA file requester:  a trailing slash or
colon is mandatory!

Once the message has been selected from the file requester, it is read
into the program, and displayed.  The top half of the window contains
text gadgets for the various message fields.  Simply click in them to
activate them.  You must press return to leave a field, even if it's
unchanged.  Special parsing is in place in the program to correctly
capitalise From and To names, and to ensure a valid address is entered.

To change any of the message's attributes, you can simply toggle them on
and off in the lower half.  ALL attributes are available, but be aware
that if you are editing an ECHOMAIL message, then most of them will NOT
make much sense!  Only the LOCAL, SENT and RECEIVED attributes are
generally used in echomail.  Netmail of course is different.  Be careful
not to set contrary bits (eg CRASH and HOLD bits should never BOTH be
set)!

If you select to toggle the File Attach bit, PlutHeadit will pull up a
file requester allowing you to select a file to attach.  If you ever
want to change this, just de-select and re-select the File Attach
attribute again.

Note that any KLUDGE LINES already in the message will be unchanged.
These might conflict with the header if you change the Zone or Point
parts of the header.  PlutHeadit, remember, is only for the HEADER.  Use
another editor for the body of the message!

Much of PlutHeadit is fairly well self explanatory, however!  Point and
click and experiment!


                              ============
                              Distribution
                              ============


PlutHeadit is NOT in the Public Domain.  It may, however, be
redistributed for no charge, or for a nominal charge that includes no
profit factor.

The author's maximum liability to any person who suffers damage from the
use, misuse, or inability to use this program will in no circumstances
exceed the amount paid to the author by the user for the program.  (In
this case nil).

The copyright of this program always remains with the author.

If you re-distribute the program, all files:  PlutHeadit, PlutHeadit.doc
and PlutHeadit.LST must be included in the distribution.

The author can be contacted:

Peter Deane

FidoNet:   3:622/401        Postal: PO Box 228
GlobalNet: 54:6101/401              Swansea  NSW  2281
AmigaNet:  41:200/401               AUSTRALIA

BBS:    from O/S   +61-49-72-1647
(24hrs) from Aust  (049) 72-1647




                                ========
                                Appendix
                                ========


This extract, courtesy of FTS-1 shows the specifications of a message
that PlutHeadit will edit.  Note that in 2-dimensional mode, the offsets
from 176-182 decimal (marked with ** below) are NOT accesible and will
NEVER be changed by this program.  If you have 4d storage available (eg
TrapToss 1.50), these parts MAY be edited (they are part of the
destination and origin node numbers).

Note that in PlutHeadit, the FromName, ToName and Subject ARE NOT the
full 36 bytes and 72 bytes long - they wouldn't quite fit!  You may only
edit the first so many bytes of each.  This will generally never be a
problem.


   1. Application Layer Data Definition : a Stored Message
 
                               Stored Message
 
       Offset
      dec hex
              .-----------------------------------------------.
        0   0 |                                               |
              ~                 fromUserName                  ~
              |                   36 bytes                    |
              +-----------------------+-----------------------+
       36  24 |                                               |
              ~                  toUserName                   ~
              |                   36 bytes                    |
              +-----------------------+-----------------------+
       72  48 |                                               |
              ~                    subject                    ~
              |                   72  bytes                   |
              +-----------------------+-----------------------+
      144  90 |                                               |
              ~                    dateTime                   ~
              |                    20 bytes                   |
              +-----------------------+-----------------------+
      164  A4 | timesRead (low order) | timesRead (high order)|
              +-----------------------+-----------------------+
      166  A6 | destNode (low order)  | destNode (high order) |
              +-----------------------+-----------------------+
      168  A8 | origNode (low order)  | origNode (high order) |
              +-----------------------+-----------------------+
      170  AA |   cost (low order)    |   cost (high order)   |
              +-----------------------+-----------------------+
      172  AC | origNet (low order)   | origNet (high order)  |
              +-----------------------+-----------------------+
      174  AE | destNet (low order)   | destNet (high order)  |
              +-----------------------+-----------------------+
**    176  B0 | destZone (low order)  | destZone (high order) |
              +-----------------------+-----------------------+
**    178  B0 | origZone (low order)  | origZone (high order) |
              +-----------------------+-----------------------+
**    180  B0 | destPoint (low order) | destPoint (high order)|
              +-----------------------+-----------------------+
**    182  B0 | origPoint (low order) | origPoint (high order)|
              +-----------------------+-----------------------+
      184  B8 |  replyTo (low order)  |  replyTo (high order) |
              +-----------------------+-----------------------+
      186  BA | Attribute (low order) | Attribute (high order)|
              +-----------------------+-----------------------+
      188  BC | nextReply (low order) | nextReply (high order)|
              +-----------------------+-----------------------+
      190  BE |                      text                     |
              ~                    unbounded                  ~
              |                 null terminated               |
              `-----------------------------------------------'
 

      Message    = fromUserName(36)  (* Null terminated *)
                   toUserName(36)    (* Null terminated *)
                   subject(72)       (* see FileList below *)
                   DateTime          (* message body was last edited *)
                   timesRead
                   destNode          (* of message *)
                   origNode          (* of message *)
                   cost              (* in lowest unit of originator's
                                        currency *)
                   origNet           (* of message *)
                   destNet           (* of message *)
**                 fill[8]
                   replyTo           (* msg to which this replies *)
                   AttributeWord
                   nextReply         (* msg which replies to this *)
                   text(unbounded)   (* Null terminated *)

 
      DateTime   = (* a character string 20 characters long *)
                                     (* 01 Jan 86  02:34:56 *)
                   DayOfMonth " " Month " " Year " "
                   " " HH ":" MM ":" SS
                   Null
 
      DayOfMonth = "01" | "02" | "03" | ... | "31"   (* Fido 0 fills *)
      Month      = "Jan" | "Feb" | "Mar" | "Apr" | "May" | "Jun" |
                   "Jul" | "Aug" | "Sep" | "Oct" | "Nov" | "Dec"
      Year       = "01" | "02" | .. | "85" | "86" | ... | "99" | "00"
      HH         = "00" | .. | "23"
      MM         = "00" | .. | "59"
      SS         = "00" | .. | "59"

 
      AttributeWord   bit       meaning
                      ---       --------------------
                        0  +    Private
                        1  + s  Crash
                        2       Recd
                        3       Sent
                        4  +    FileAttached
                        5       InTransit
                        6       Orphan
                        7       KillSent
                        8       Local
                        9    s  HoldForPickup
                       10  +    unused
                       11    s  FileRequest
                       12  + s  ReturnReceiptRequest
                       13  + s  IsReturnReceipt
                       14  + s  AuditRequest
                       15    s  FileUpdateReq
 
                             s - this bit is supported by SEAdog only
                           + - this bit is not zeroed before packeting
 

