Mail Reader 1997 by Przemek Borys

0. I apologize for my poor English ;-)

1. Installing program
To install this program, you should type "make" in the source directory.
The make script takes care of the whole installation process; it compiles
the program, and copies the important files to their directories. You can
change the default dirs by editing the Makefile; the program will accept any
given directory. The directories set in Makefile are being hardcoed to the
program durring the compilation.

2. Creating mr.rc file:
If you want to use this program for viewing messages, you have to
specify, where to find them. 
This is one of the primiary ideas of this file. Folder definition begins
by writing this word:

folder "name of the folder"

This specifies the name, which will appear to the user, when browsing
mailfolders. Second important thing is to define path to this folder. 
So in next line you type:

path "/path/to/the/folder"

Note, that my program does not recognize shortcuts like '~' for homedir, 
and others (but it will be probably supported in next versions)

That is. We've already defined our first folder. Now you may want to
define another folder. To do this, type in the next line 

folder "name of the next folder"
  path "/path/to/the/next/folder"

As you see, folder definition begins by word "folder", and ends at the
begining of the next folder definition (that is there, where the next word
"folder" is being found).

And now the goodies ;-) : except of the "path" option, folder definition
supports fields like

defaultto "Default receipent's address for this folder"
defaultcc "Default carbon copy for this folder"
defaultbcc "Default blind carbon copy for this folder"
replyto "The address, where replies will be sent back to you"
charset

Any of those options may appear in the folder definition. They don't have to
appear all - if any of those definitions is not specified, programm assumes, 
that you don't want to use this feature. 
Now I'll describe a bit more preciselly what do those fields define:

DefaultTo - defines the default receipent in the folder for new messages. It 
sets a default username, when you write new message. It may be usefull
in mailing lists, where all new messages are to be addressed to the listserver.

DefaultCc - defines the default carbon copy. Carbon copy allows you to send
the same message to different addresses.

DefaultBcc - same as above, but does not show the addreses, the message
was sent to to the receipent.

ReplyTo - defines the address, you want to receive replies on your
messages. This is mainly used then, when you're writting from different
addres than the one you want receive replies to.

Charset - Specifies the character set of your country. The default is
US-ASCII, but for many countries that's not enough, and, for example Europe
uses charsets like ISO-8859-2, ISO-8859-1, and so on, until ISO-8859-6 (that
is as far as I remember). Poland for example uses ISO-8859-2.

AlternateEditor - Specifies an alternate external editor, instead of the
internal one.

ForwardBanner - Specifies the banner, which will be added on the beginning
of the forwarded text message. It's independent of what is in the
forward.tpl file (about which you'll learn more later). The default value of
this field is "-----Forwarded message-----"

Graph_Warez - specifies, if you want or not to see some esthetical details
on the screen. They may slow down the program under some dial'up
terminals... The default is "no".

FileImportBanner - the banner, which will appear, when you import a text
file to your message under internal editor. The default is "--- cut ---"

One more thing. When using quotes ,, " '' in the field's value, you
must preceede them with a backslash, that is ,, \" ''. It is so, so the
program could differ the quote which is ending the field's value from a quote,
which is a part of this value.
One more thing: comments are assumed to be preceeded with '#' char, and they
contionue to the end of line.

And now an example of the file mr.rc:

---------------
###########################
# Simple MR's config file #
###########################

charset "ISO-8859-2"
AlternateEditor "vi"
ImportFileBoundary "**** cut it down! ****"
ForwardBanner "--------This is a forwarded message--------"
Graph_Warez "yes"

folder "Root's mail"
  path "/var/spool/mail/root"
  replyto "\"Przemek Borys\" pborys@rhea.ids.pl" #here you have an eg. for \"
folder "Przemek's mail"
  path "/var/spool/mail/pborys"
  defaultto "root@localhost"
---------------

4. Creating templates.
This program provides a set of templates. They are covered in files

~/.mr/new.tpl
~/.mr/reply.tpl
~/.mr/comment.tpl
~/.mr/signature.tpl

The first one defines template for new message, the second for replies, the
next for comments, and the last defines the signature.
These are the files, which are appended at the beginning of your messages,
and the signature is appended at end of them.
When writting template files, you can use the following macros:
@ff - From First Name - the first name of the sender of the msg 
      you reply/comment to
@fl - From Last Name - the last name of the sender of the msg, you
      reply/comment to
@tf - To First Name - the first name of the receipent of the msg you 
      reply/comment to
@tl - To Last Name - the last name of the receipent of the msg you 
      reply/comment to
@fa - similar to fn, but gives the e-mail address of the sender
@ta - stands for the e-mail address of the receipent
@s - stands for subject of the message you reply/comment to
@d? - stands for the date of the msg you reply/comment to. There are few
      types of this macro:
   @dy - the year
   @dm - the month
   @dd - the day
   @dw - the day of week
   @dh - the hour
   @dn - the miNute
   @ds - the second 
@@ - prints the '@' sign

You can edit templates from the program directly - use the option from the
"Options" submenu.

examples for templates:

----new.tpl----
Hello

---------------
Warning! For now new.tpl does not support macros :-( (it'll change soon)

---reply.tpl---
Hello, @fn
@d @fn wrote to @tn
 
---------------
--comment.tpl--
Hello, @tn
@d @fn wrote to @tn

---------------
-signature.tpl-
See ya
Przemek <pborys@@rhea.ids.pl>

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

5. Charset translation tables.
MR supports translation tables. You create them in the directory specified
by the variable CHARSETPATH of Makefile. Their name should correspond to the
name of an charset, you want to translate. I.e. a charset for ISO-8859-2
will be put in a file of name ISO-8859-2, here's an example:

--ISO-8859-2--
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
-------------
This is an "empty" translation - it does nothing. Translation tables are of
the format
f<space>t<cr>
f<space>t<cr>
...
where f is the character, which is about to be converted, and t is a value, to
which it's going to be set. <space> is a space character, which you can get
by pressing the long button on your keyboard ;-), and <cr> is a newline
sign, you get it by pressing Enter ;-).

6. Changing default colors.
You may not like my default colors. Well... probably you have a bad taste,
but I gave an interface to modify colors. Get into the menu (by pressing
F10), and go to the <Options>, and choose there the option for changing
colors. After changing colors, write them to HDD (there is an option in the
<Options> submenu).

7. Composing message.
When you send a message, (by pressing either INS, or 'c', or 'q', or 'f'),
you're asked about some things by the header. These are:
To: - you put here the address of the person, you're writting to. It's an
      required field.
Cc: - here you put the address of a person, you want to have this msg
      copied. It's an optional field.
Bcc: - same as above, but it's a 'Blind Carbon Copy' - the person, who gets
       mail doesn't see it. It's an optional field.
Subject: - The subject of your message. An optional field.
Attach: - This is rather not a field, but an interface for sending file
	  attachments. When you get on this field, you'll see two lists - 
	  one with the files on your disk, and second with the files, you've
	  selected to send. You switch between them by pressing [tab] key.
	  You select a file by pressing space, move through directories
	  using [enter], and delete choosen files by pressing [del] key.
	  After you've choosen your files, you press the OK button. 

After you've finished editing header you go to the "subject" field of header, 
where you push the enter key. Then you start to edit the message body. You
can abort this by pressing [esc] key. When you edit the message, all
available options are listed on the status line (as ussualy ;-). You can
abort editing, by pressing [esc].

7. Enjoy! >8-} 