EvenMore 0.63
A freeware textviewer for the Amiga

EvenMore ©1996-2004 Chris Perver
ReqTools  ©1991-1994 Nico François, ©1995-1998 Magnus Holmgren


    Contents

Disclaimer
Introduction
System requirements
Installation
Features
Getting started
Programming EvenMore
Contacting
Credits

    DISCLAIMER

This archive can be distributed by commercial or private companies, profit making or otherwise, as long as the following rules are applied.

1) The contents of this archive must remain intact and unaltered. This archive is permitted to be distributed so long as all the files are included and are not malformed, edited, changed or modified in any way, by accident or intent. 
2) The version distributed must be the latest release. (Check on aminet, the EvenMore homepage or email me
3) This archive may be distributed and advertised by public domain libraries, as long as no profit is made on the program, and the price is no higher than the cost of a disk, copying and distribution costs. This is freeware! You can't charge people any money for it!

I HEREBY DISCLAIM ALL RESPONSIBILTIES FOR THE USE OR MIS-USE OF THIS SOFTWARE.

THIS SOFTWARE IS PROVIDED 'AS IS', AND IS SUBJECT TO CHANGE WITHOUT FURTHER NOTICE. THERE ARE NO GUARANTEES THAT THIS SOFTWARE WORKS, HAS NO BUGS, AND THAT IT WILL NOT HARM ANY OF YOUR EQUIPMENT OR SOFTWARE ETC. BY USING THIS SOFTWARE, YOU AGREE THAT ANY DAMAGES INFLICTED ARE THE TOTAL RESPOSIBILITY OF NONE OTHER INDIVIDUALS, OR GROUPS, BUT YOURSELF, AND YOU MUST MEET THE EXPENSES TO COVER THE DAMAGES. THIS AUTHOR WILL NOT BE HELD RESPONSIBLE FOR ANY DAMAGES THAT MAY BE CAUSED, EITHER DIRECTLY OR INDIRECTLY BY USING THIS SOFTWARE. BEFORE USING THIS PROGRAM, BACK UP ALL IMPORTANT SOFTWARE AND FILES, AND MOST OF ALL, READ THE MANUAL BEFORE PROCEEDING! AS I CANNOT RECOMPENCE FOR LOSSES. (INCLUDING, BUT NOT LIMITED TO LOSS OF BUSINESS, LOSS OF SOFTWARE/HARDWARE OR LOSS OF SANITY/HAIR).

    Introduction

The AmigaOS is an excellent operating system. Even the last OS before Commodore ran out of money (OS 3.1) can't be touched by Windoof and other operating systems. So why spoil it now? Commodore also brought in features such as Screen and Icon fonts, which could be proportional. And proportional fonts look so much nicer. So that is why I decided to have a bash at designing a nice looking text viewer to complement Workbench. Well, that is partly the reason. The other part is, I wanted to program... I was thinking about C, and then I just happened to see what E could do and I was hooked! So this is my grand contribution to the Amiga :).

    System requirements

Those requirements in red are essential for EvenMore to run, those in black are libraries used by EvenMore.

Kickstart 39+ 
Asl.library 37+ 
ReqTools.library 37+ 
XPK libraries 2+ 
Newicon.library 
OpenURL.library 
Titlebar.image class
Icon library 44+

    Installation

Installation is simple. EvenMore should run directly from the directory it is in, without any need of setup if you have the required libraries already on your system, but if you don't, here is what to do.

1) Simply copy 'libs/reqtools.library' to 'Libs:', if you haven't already got it, or haven't got a version later than 37. 
2) Copy 'classes/images/titlebar.image' to 'SYS:classes/images/' 
3) Then copy the entire EvenMore directory anywhere on your harddrive or floppy disk. 
4) Run EvenMore, and configure the preferences to your own taste.

    Features

and more...

    Getting started

Arguments

EvenMore takes two arguments when running from Shell and just one when running from Workbench (Which is drawers or files).

    Shell

If you do not specify any filenames, a requester will pop up allowing you to do so. Once you have selected the file you wish to view, a window will open displaying the contents.

e.g. EvenMore S:User-startup PREFS=BigHD:EvenMore.prefs 
      EvenMore Docs:EvenMore S:User-startup S:Startup-sequence

    Workbench

You can either shift-select multiple files or drawers with EvenMore (Holding shift, left click on the EvenMore icon, then double click on a file), or if you simply double click on the EvenMore icon, a requester will allow you to choose a file. EvenMore of course supports drag and drop. Just drag a file or folder on to the EvenMore window, or onto the icon when EvenMore is iconified, and EvenMore will open the file or folder.


Interface

EvenMore will detect on start-up what type of files your have selected to open, if any. If you are running the FileTypes plugin module, EvenMore will first of all scan through what filetypes have been set up, and launch those specific applications with those files that have matched those in the filetypes.txt file. If you have selected a path, a requester will appear asking you to choose a file from the path you have selected.

The EvenMore window should then appear, and any files remaining to be opened will be opened now. You should have something like the picture below on the screen.

Close file Close currently displayed file
Open file Open a new file. If the file is already opened, the previously opened file will be viewed instead.
Reopen file Reopen displayed file
Save file Save displayed file in text format
Edit file Open the displayed file in a text editor
Print file Print the displayed file/highlighted section
Search window Search the document for words
Find last Repeat last search going backwards
Find next Repeat last search going forwards
Find occurance Find number of times a word occurs in the displayed file
Preferences Change the EvenMore settings

Across the top of the window you will see a toolbar, giving access to common functions of EvenMore. Positioning the mouse over each of these will display a help text to show what each button does. The buttons and an explanation of what they do are listed to the left...

Depending on the current configuration, you may have EvenMore set to open with a standard Amiga window, or on it's own custom window. Whatever the case may be, you can use the scroll bars available to scroll about the document. Pressing the HELP key will open a list of additional keys you may use to run common functions on EvenMore.

Quickload Menu

EvenMore will automatically look for a file called "quickload.txt" in the EvenMore directory. This is simply a file containing a list of files (including full path) eg:-

S:Startup-sequence
S:User-startup
BAR
SUB
Commands
EXE
NewCLI,c:newcli
Open in Multiview,sys:utilities/multiview "%s"
ITEM
BAR
Work:Readme.txt

Each of these files will then be loaded into the Quickload menu in EvenMore for easy access. The BAR in the file will create a menu break. The word SUB on a line on its own will place all following lines in a sub menu, with the next line containing the name of the sub menu. The word ITEM designates the end of the declaration of sub menu items, and the beginning of main menu items. The word EXE on a line on its own will cause EvenMore to treat the following lines as strings to execute from the shell rather than text files for loading. These lines can be preceeded by a description followed by a comma, to give them an intelligable name. You can use filename keywords in the executable strings in the same way as used in the texteditor preference. EvenMore will replace the %s keyword with the filepath of the currently loaded document. Typing FILE in the quickload textfile will revert to EvenMore treating subsequent strings as text files for loading in the text viewer.

History Menu

Any files that are loaded into EvenMore are stored in memory. In fact, EvenMore will allow you to open up to 1000 files at the same time. Each filename is then added to the History menu. You can move between the files you have opened by selecting documents in this menu.

    Configuration

Clicking on the Preferences button on the main toolbar will bring up the settings window. Across the bottom of the window are 3 buttons, marked Save (Save settings to current preference file), Use (Accept settings without saving them) and Cancel (Reject any changes made). 

To the left, there is a listview where you can select different preference pages. These are as follows...

Tab Setting Description
Application Position Using these two boxes, you can specify where on the screen the appitem will be created when EvenMore is iconified
Open/Close These two cycle gadgets will allow you to select how EvenMore behaves when it is opened or closed. It can open as an icon on Workbench, or when you quit, EvenMore can be iconified instead, etc.
Confirm quit A requester will appear whenever you want to quit, asking you to confirm this is ok.
Multiple copies If EvenMore is already running in the background when you try to open another file with EvenMore, the file will be passed on to the copy already open. This option disables that behaviour.
File XPK pack method If you have XPK archiver installed, you can select which method of arhiving you wish to use if you want to save a file crunched with XPK
XPK efficiency Again, same as above except this option specifies how efficient the crunch routine should be.
Default Document(s) loaded when EvenMore starts with no arguments.
Editor Path of your favourite text editor to use when editing files. Note that the string you enter here is basically a command line. So you can include options other than just the editor path.

Keyword... Replaced with...
%s  Full filename 
%l   Top line of file in the window

For exmaple...
EDITORSTR=c:ged "%s" LINE=%l

GUI Objects Clicking on an object in the listview (eg, Gadgets, Text, Info bar), will select the settings for that object in EvenMore's window.
R, G, B Adjusting these sliders will allow you to set the main colour of the currently selected object.
Style Using the listview, you can select what each GUI element that makes up the EvenMore interface will look like. 
Recess/Light Selecting these will show the object currently selected in a recessed state, or in a lightened state.
Offsets These are the gaps between the edge of the window and the rest of the interface, and the gap around the toolbar buttons in pixels.
Dither You can select a type of dither to use for either the window pen or the toolbar pen.
Select icon set This is the path where EvenMore will find the images for the toolbar.
Text Font Which font to use to display the file with.
Leading Extra space in pixels between lines in the file.
Tab How many characters a Tab will space on by (default is 8).
Page overlap How many lines will be `repeated` when you scroll by a page length.
Wheel-mouse Scroll How many lines a single scroll of a wheel mouse is equal to.
Smooth scroll Scrolling will be graduated instead of immediate.
Window Mode Screen mode to use when using EvenMore's own screen.
Name Name of public screen EvenMore should create.
Use custom screens Whether or not to enable the use of EvenMore's own screen.
ASL filerequester Use an ASL filerequester instead of ReqTools (default).
Info bar The format of the file information bar. 
Keyword... Replaced with...

%fs   File size
%fl    First line in window
%ll    Last line in window
%tl    Total lines in document
%pg  Page
%cf   Current file viewed
%nf   Number of files open

Scrollers You can set which proportional gadgets should be available in the window, or have a borderless window for EvenMore.
3d window title If enable, when the window is borderless, the title will be drawn in 3d.

In addition there may be other preference pages in the list that appear depending on which plugins you have installed.

    Programming EvenMore

Arexx

You can use EvenMore's arexx port to control EvenMore remotely. The port's name is 'EvenMore', plus a number. This number will increment if a port of a similar name is found, for instance if you load two copies of EvenMore, the first copy will have a port name of 'EvenMore.1', and the second one will have a port name of 'EvenMore.2'. You can find which port EvenMore is using by looking in the Information/About requester.

The commands are:-

'r = ' indicates the command returns a value

CLOSE Close current file
CLOSEALL Close all files opened
r = GETFILENAME Return name of current file
r = GETFILESIZE Return size of current file
OPEN <name> Open a new file 
VIEWFILE <number> View a file already opened
r = CURRENTFILE Get number of current file displayed
SAVE <name> Save current file to disk
PRINT Print current file
r = GETLINE <number> Return text of line number
r = GETFIRSTLINE Get number of first line in window
r = GETLASTLINE Get number of last line in window
r = GETFIRSTCOL Same as above but for column numbers
r = GETLASTCOL Same as above but for column numbers
r = GETTOTALLINES Get total number of lines in window
r = GETTOTALCOLS Same as above but for columns
SCROLLTOLINE <number> Scroll to a line number in the window
SCROLLTOCOL <number> Same as above but for columns
SCROLLTOPAGE <number> Same as above but for pages
SCROLLTOPERCENT <percent> Same as above but for a percentage of the document
BOOKMARKSTORE <number 0-4> Store current position in document
BOOKMARKRECALL <number 0-4> Recall stored position in document
r = GETFONT Get the name and size of font used
SETFONT <name/size> Set the font in the window
r = SEARCH <string> Search for this string in the current document
r = OCCURANCE <string> Find how many times this string occurs in the document
GOTOSCREEN <name> Move window to another screen
ICONIFY Toggle iconifying of EvenMore
QUIT Close EvenMore
GETWINPTR Return a pointer to the EvenMore window if open

To use one of these commands from a shell, you could simply type the following:-

RX "ADDRESS 'EvenMore.1'; OPEN 's:startup-sequence "ram disk:my file"'"

Note the quotes which must be put around some strings when characters like ':' are present in them. If you do not specify a filename for OPEN (just '') or if you just specify a path, then a requester will open.

Plugins

There are quite a few plugins I have created for use with EvenMore, ranging from MSWord file conversion, HTML, RTF, and many more formats. When EvenMore loads, it will automatically check the file it is loading against each of the plugins that are installed in the Plugins directory. When a match is found, this plugin will then convert the file data to a readable format. Now with EvenMore, full colour text is possible, and many plugins will support this (see RTF, HTML plugins, etc).

Some of the plugins will work differently from others. One such plugin is the Filetypes plugin. This plugin looks for a file called "filetypes.txt" in the EvenMore directory. This is a file containing wildcard matches and a program path to launch the selected file with, eg:-

#?.guide=sys:utilities/multiview "%s"

This string would cause EvenMore to pass any file ending in ".guide" over to MultiView to open. The %s in the line is replaced by EvenMore with the file selected for loading.

Some plugins can even allow you to create your own preferences in the EvenMore preference window. This will allow more complicated plugins to be developed.

    Creating your own plugins

The plugins are fairly simple to code, and anyone with a basic understanding of any library-compiling language is able to create these. There are a few basic types of plugins you can create. These are identified by the Em_pluginid() function.

When EvenMore opens a file, it is passed through these plugin types in the following order...

    FTYP
This plugin type is loaded whenever the user selected which file they want to load, but before the file is opened. The filename is passed on to the plugin, and the plugin returns TRUE or FALSE depending on whether a match was made (TRUE will stop EvenMore from opening the file itself).

    PACK
EvenMore will then check the file against all the plugins with the PACK identifier. This plugin type should check if a file has been crunched by a particular compression program, such as XPK, PowerPacker etc. Even if a file has been found to be compressed, and is uncompressed by the plugin, it still will be passed onto the following plugin types.

    FILE
This is the main type of plugin. Whenever EvenMore opens a file, the Em_begin() function in the plugin will be called, which will return TRUE or FALSE depending on whether this file matched the plugin's criteria. If so, the function Em_main() will be called, which will convert the file format into the desired format via the plugin code, allocating extra memory if required.

    FRMT
This plugin type is used after all other plugin types have been checked against the file, and none of the plugins have been used. The plugins that use this identifier should only change the formatting of a document if necessary, and not affect the file in any other way. An example of a plugin that would use the FRMT identifier would be a word wrapping plugin.

    Other plugins which don't relate to loading files...

    PREF
This plugin will create its own page on the preference window of EvenMore. This can be used to store user settings for created plugins. The preference plugin will have its own seperate configuration file, which will be loaded or saved whenever the EvenMore configuration file is loaded or saved.

    MPRF
This plugin is used to create the preferences window for EvenMore. The current preference plugin is created in EasyGUI, but could be easily replaced by an MUI interface or any other GUI. Because the preference window and settings are set through a plugin, it would also be possible for programmers to customize and expand their EvenMore preferences, either for plugins they create or for the main EvenMore program.

For examples of these plugins, please refer to the EvenMore website where their source code can be freely downloaded.

    Contacting

You can contact me at the following addresses.

Postal address

Chris Perver
6 Gransha Road
Bangor
County Down
N. Ireland
BT20 4TG
Email: chris@evenmore.co.uk
URL: www.evenmore.co.uk
Telephone: 028 91 457144

I cannot expect to be able to develop this program much further, as I am a Christian and believe Jesus Christ will return very soon. If I do not reply to any mail for months and months, then the development of this program has ceased.

If anyone wishes to help in the distribution files, please email me. You could design a few NewIcons, MagicWB icons, Iconographics icons, plugins, or anything. If you have any suggestions or contributions for the distribution files, again email me :). Suggestions for the program are always welcome. Tell me what YOU would like to see in a text viewer.

    Credits

Mum & dad - RKRM manuals, Amiga 3000... (you name it, they provided it) 
Johan Björnson - AmigaGuide, program icons... 
Per Reidar Verlo - Norsk Install script, locale translations 
Girish Nath - Program icons

Beta testers: 
Johan Björnson 
Mikael Grahn 
Per Reidar Verlo 
Dominique Neveu 
Tony Hazel 
Andrew Holt 
Roland de Herder 
Raul Silva

Locale translators:
Per Reidar Verlo (prbverlo@online.no) - Norsk 
Roland de Herder (macron@multiweb.nl) - Nederlands 
Victor Gutiérrez (masone@ctv.es) - Español 
Jerome Chesnot (jchesnot@noname.fr) - Français
Raul Silva - Português, Glowicon and Newicon sets, program, drawer and document icons
Vitaliy Chepeleff - Russian
Alfred Faust - Deutsch
Jan Zahurancik - Slovak
Pär Boberg - Svensk
ATO-PL (www.amiga.pl/ato/) - Polski
    Members which working on it: 
    Daniel Sternik
    Kamil Niescioruk
    Mariusz Danilewicz

Without the following people, writing this program would have been virtually impossible...

Nico François, Magnus Holmgren  - ReqTools 
Dietmar Eilert - GoldEd 
Wouter van Oortmerssen - AmigaE and EasyGUI 
J R Hulance - AmigaE and EasyGUI help

Ilan Sharoni - Word wrapping help 
Marco Talamelli - ReqTools help 
Eric Sauvageau - Screenmode help 
Victor Ducedre - dclistview EasyGUI plugin 
Ralph Wermke - register EasyGUI plugin 
Ali Graham - multitext EasyGUI plugin 
Sven Steiniger - patternStringF, runback modules 
Will Harwood - gadgetinfo module 
A.F.C. - rexxer, localer (www.intercom.it/~fsoft/afc.html) 
Massimo Tantignone - titlebarimage.class