home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Elysian Archive
/
AmigaElysianArchive.iso
/
compress
/
xpk25usr.lha
/
Workbench
/
most
/
Most.doc
< prev
next >
Wrap
Text File
|
1992-11-11
|
19KB
|
534 lines
Documentation for Most V1.31
Date : 11 Nov 1992
Author: Uwe Röhm
Most is a 2.0 only textviewer which I wrote with full workbench support
in mind. First at all an overview of interesting features:
- unlimited number of windows
- each text has its own process
- search function
- highly configurable
- clipboard support
- "click-and-load" function for includes
- font sensitive GUI
- PubScreen, CustomScreen or Workbench
- AppWindow, AppIcon
- ARexx Port
- localization with locale.library
- XPK support
- pipe support
- as mentioned, kickstart 2.0 is requiered
Table of Contents
===================
1. Copyright
2. Background
3. Configuration
4. Keyboard commands
5. Menus
6. Most's window
7. The search requester
8. The AppIcon
9. XPK support
10. pipe support
11. ARexx Port
12. Ideas, Bug reports
13. current versions
14. Thanks
1. Copyright
===========
Most 1.31 is published under the concept of GiftWare! So if you
find Most a useful tool (and of course use it) please make me a present
of any kind - and make me VERY happy.
Beside this I keep my Copyright: Copyright (c) 1992 by Uwe Röhm
You MUST get my aggreement if you wish to publish Most in a commercial product.
Especially it is not allowed to use Most for military purposes of any kind
which includes using Most in companies which plan or only support military
products.
You are allowed to include Most in PD packages which cost less than $10.- !
But I ask you to keep the archive together. You have to include the
documentation with each version. Thank you!
2. Background
============
There are some goals I try to achieve with Most:
- full workbench support
- easy to use with mouse AND keyboard
- flexibility
- memory friendly :-)
So Most uses a window for EACH text - there is no possibility to use it
like Commodore's More in a shell. Of course you can choose another screen
to open on or even an own CustomScreen. How much windows are opened by
Most and where they are is absolut without interest and only limited by
the amount of free (chip-) memory!
As each text is displayed in his own window there is also its own process
behind. Cause of the windows are absolut independent of each other.
Especially you can send ARexx commands to different windows simultaneous
and you are free to open new Most windows even if previously opened
windows are "busy" - there is Most's main process which handles all
texts and some global ARexx commands.
To be memory friendly and to display very huge texts even on a 500KB
system Most does buffering. Small texts, which fit completly into the
buffer, are read only once and closed than so that you can e.g. edit
and save it again. But if the text is larger than the configurated
buffer length (yes, of course you can change the buffer size, but read
on :-) ) Most will do some sort of "paging". So memory usage will be
limited by the buffer size you specified (little memory -> small buffer).
On the other hand this slowes scrolling and searching down!!! Sorry
for this, but if you have enough memory just increase to buffer size
to - let's say - 2 MB. Don't be afraid. Of course Most only uses the
amount of memory it needs if a text is smaller than the buffer ;-)
There is one exception of the paging method: XPK packed files. In the
current version Most does NO PAGING to XPK files but reads the complete
file into memory. Perhaps this will change in future, perhaps it will
stay...
Oh, I nearly forgot that Most can diplay all ANSI sequences. Without this
it wouldn't be a real textviewer. As I don't want to do old work again
and again I decided to use the console.device. This enables you to mark
lines and copy them with "Amiga C" into the clipboard! (Don't use the
FASTSCROLL Option if you want mark something). I regret that there are
also some problems:
- You can only mark text inside the visible text portion.
- Scrolling is quiet annoying on an "normal" Amiga without 680x0 (x > 1).
- Don't load binary files. I warned you!!!
3. Configuration
===============
Most does the following configuration steps on startup:
1.) internal defaults
2.) environments "Most/Most" und "Most/FileReq"
(When used from shell local environments will be read first!)
3.) Shell-start: parse command line
WB-start : parse ToolTypes
And now, ladys and gentlemans, here are the options to be used in 2.) and 3.):
FILES list of filenames to be displayed (shell only!!!)
PUBSCREEN name of PubScreen where Most will open its windows on
PORTNAME overwites the default ARexx portname "MostPort"
STARTUP name of an ARexx Macro executed every time Most opens a window
WX=WINDOWX X-coordinate of Most's window
WY=WINDOWY Y-coordinate of Most's window. -1 for centered windows
WW=WINDOWW width of windows (defaults to 600)
WH=WINDOWH height of... (defaults to 400)
SM=SCREENMODE A valid screenmode Most will use to open its on screen with
(which will be a PubScreen named 'Most').
You can get a list of the avaible screenmodes of your system
if you start Prefs/ScreenMode.
ATTENTION!
The names of the screenmodes are different for most versions
of the monitor files. Remember that you must specify a valid
name, which means, that you must spell it exactly as in the
monitor files. If in doubt start Prefs/ScreenMode and read
the listview.
FONT name of a font to be used. The name must include the '.font'
postfix. Don't forget it! And be careful with proportional fonts.
FONTHEIGHT works only together with the FONT option (see above).
if not specified Most uses the system default font's height.
APPICON a switch, which lets Most use an AppIcon on workbench.
If you start Most with the APPICON option and without
further file names, Most will only put its AppIcon onto
workbench and stay in background. (Read on for more details)
ICONX X-coordinate of Most's AppIcons
ICONY (see ICONX)
FASTSCROLL a switch to force Most to use console without the copy
option. This will (slightly) increase output speed...
WORDWRAP a switch to AVOID word wrap.
ATTENTION!
Without word wrap Most will scroll long lines quiet strange ;-)
BUFLEN very interesting option to justify Most's buffer size.
In general: On small systems use small values, on larger
systems try higher buffer sizes. BUFLEN defaults to 50 KB
(which is quiet small :-) ). Texts smaller than the buffer
size will be read complete into memory and use only the
necessary amount of memory.
QUOTES you can specify a sequence of quote characters.
These characters will be used for the "click-and-load"
option: If you doubleclick on a word which stands BETWEEN a
quote character Most will try to load a text named like this
word. This is very useful for programmers as you can view
include files very easy!
Default: "'<>(){}[]
DIRS specify one or more directories Most will search in if you
use the "click-and-load" function (see above). All directories
must be seperated by |
Example: DIRS "Include:|TexInputs:|LC:Include/"
ENDS Postfixes to be appended on include files with the "click-and-
load" function (see above) in the given order!
Example: ENDS ".c.h.tex"
4. Keyboard commands
===================
In the current version Most supports all (and more!) keyboard shortcuts well
known from More. Future versions will allow custom keyboard commands...
* Scrolling
CURSOR DOWN
NUMERICALPAD 2
RETURN
ENTER
one line forwards
CURSOR UP
NUMERICPAD 8
DELETE
one line backwards
SHIFT CURSOR DOWN
SPACE
PAGE DOWN
one page forwards
SHIFT CURSOR UP
BACKSPACE
"b"
PAGE UP
one page backwards
HOME
"<"
jump to beginning of text
END
">"
jump to end of text
* Searching
"n"
search actual searchstring again
"."
ignore upper/lower case
"/"
searching with distinction of upper/lower case
"f"
"s"
open search requester (if it es opened, search string)
* load new text
"l"
* information
HELP
"h"
* start editor (as configurated in ENV:Editor)
"e"
* close text
ESCAPE
"q"
5. Menus
======
Project
New...
Opens a new window and brings up a filerequester where you can choose
a text file to be displayed in the new window. If you cancel the
filerequester the window will be closed.
Open...
Asks you for a new file to be loaded into the current window
Edit...
Starts the editor with the current text via RUN. The name of the editor
can be configurated in ENV:Editor
Info...
Pops up an information requester where you find some useful
information to the current text like name, length, line count,
visible lines, XPK packername and a short comment if the text
has been loaded completely into memory or if it uses an buffer.
Quit
Quits the current window (and if it was the last one Most at all)
Move
Move through current text as the menus describe.
Search
suchen...
Opens search requester (described later) and activates its string
gadget. If the search requester is open this menu is disabled.
forwards
backwards
Search string forwards/backwards (only with open search requester)
Extras
Refresh page
Reset console and redraw page
Execute ARexx Macro...
Asks for an ARexx Macro to be executed.
Settings
save
global Prefs
Save actual settings in two environments in ENV: and ENVARC:. A
subdirectory Most will be created automatically.
All known options from workbench or shell start are saved and
also the dimensions and position and the pattern string of the
file requester.
local Prefs
Does the same as above, but uses local shell variables. This
only works if you started Most from a Shell!
6. Most's window
===============
* Gadgets
Beside the system gadgets there are three further ones which control
text scrolling:
You can use the scroller continously by click-and-draging or for
scrolling one page forwards/backwards if you click under/above the
knob. The knob's position represents the current text position, its
height the relation between the visible and the total text length.
Use the arrows to scroll one line in the correspondending direction.
* Mouse
"Click-And-Load" function
If you doubleclick into the window Most will look at this position to
find a word which is limited by one of the configurated quote characters.
This word (can include spaces!!) will be treated as a filename for
which Most searches first in the current directory and than in each
further configurated (DIRS option) directory. Most will also try
the plain filename and than (if not found) append each prefix given
with the ENDS option. The first found file will be displayed in a
new window. If no name matches, the screen will flash (DisplayBeep).
Example: Doubleclick on " #include <exec/exec.h>" between < and >.
the file Include:Exec/Exec.h will be loaded, if you
specifed DIRS Include: on startup.
clipboard support
If you don't use the FASTSCROLL mode you can easy mark any text in the
visible text by click-and-dragging (drag without releasing the
mouse button). Copy the marked block with "Amiga-C" into the clipboard.
The current version doesn't support paste from the clipboard.
* AppWindow
Take any "real" icon (no AppIcon) on workbench and drop it in Most's
window. It will be loaded into the current window. If you drop more
than one icons Most will open further windows.
7. The search requester
======================
Here you can enter a search string and also manipulate the three search
option. Therefor you can use the mouse and/or the keyboard shortcuts
indicated by the underlined characters.
Additionaly you have the same functionality as in the main window! So no
annoying re-activation of Most's textwindow.
- All menus are avaible as in the text window. Only the menu
"search" will be disabled and instead "search forwards" and "search
backwards" are unghosted.
- Beside the mentioned Requester shortcuts you can use ALL normal
keyboard commands like scrolling with the cursor keys!!!
(Be sure the string gadget isn't activated)
8. The AppIcon
=============
The AppIcon has two functions
- Doubleclick
A filerequester will come up where you can choose a file to be loaded
and displayed. If you select CANCEL Most will show a security requester
where you can quit Most.
- Icons
Drag-and-drop one or more icons on the AppIcon and they will be loaded.
Comments:
Most uses his own program icon as its AppIcon. Perhaps I will support
custom icons in the future but not yet ;-)
The coordinates of the AppIcon can be saved with "Save Settings".
Use the options ICONX and ICONY for exact placement of the AppIcon.
9. XPK support
=============
Main goal of Most's XPK support is to hide any consequences of packed
data from the user. This means, that any packed file (with XPK) will
automatically be unpacked from Most if the XPK packages is correct
installed. The only hint you get is in the information requester,
where the line "XPK-packer:" will show you the used packer (usually
you see "---" there). There is only one thing special with XPK packed
data: The file will be loaded completely into memory and no buffering
will be done!
On the other hand if you don't have XPK you can use Most without any
difference. The xpkmaster.library is not required by Most to run at all.
Of course in this case XPK packed data will not be unpacked :-)
10. pipe support
==============
As a new feature Most 1.31 supports pipes. This means, that you can type
something like "type foo | Most" at your (W)Shell prompt and Most will show
the output of the first type command in its window!
As I said this feature is brand new. So I regret that I couldn't test
it for all possibilities. Please report me any failure.
There are two small problems:
XPK doesn't work with pipes (or better: I don't support it ;-) ).
Second there is the problem with pipes that you cannot know how much
data therein will be... So one effect is, that you cannot scroll back
to the start of an file if you scrolled over the bounds of a buffer and
the other one is that the size of the buffer will be maximum bufferlen
every time. If the pipe's data fits completly into the buffer you
have no restrictions for scrolling. But if the data is to large - Sorry.
11. ARexx Port
============
Beside the global ARexx port "MostPort" (or the name you gave it with the
option PORTNAME on startup) of Most's main process each text window has
his own private ARexx port. To select a window first send the command
"GetFileList" to the global port. You will receive a list of the avaible
windows and its portnames.
All following ARexx commands can be send to a private window port, but
Most's main port does only understand the first 6 commands "GetFileList",
"GetScreenName", "Quit", "OpenNew", "Set" and "Request". All other commands
will return an errorcode of 20 if send to "MostPort".
Sorry, but the ARexx port isn't complete today. Especially it lakes some
interesting set commands. You also cannot specify a custom portname for
Most's main process. But I'm working :-)
The following ARexx commands are supported:
GetFileList In RESULT you receive a list of avaible textwindows and their
port names. Format: {<windowname> <portname> }^+
GetScreenName get the name of the PubScreen of the current window
Quit Quit Most and close ALL windows. Also the AppIcon will be removed.
Request Simple possibility to open a custom requester and to call for
a user decition. In RESULT you get the 0 for CANCEL, 1 to...
for the left to right gadgets.
Format: REQUEST <Title> <Gadgets> <Text>
Set set some internal parameters like
CASE ignore upper/lower case ON/OFF
WORD search only for whole words ON/OFF
BACK search backwards ON/OFF
NOT IMPLEMENTED YET!!!
OpenNew Like Open, but loads the text in its own new window.
Open Load a new text into the current window. If you don't specify
a filename, a filerequester will appear.
Close close the current window
ToFront bring the current window (and its screen) to front
GetWindowDims get the dimentions of the current window in RESULT
Edit start ENV:Editor with the current text
Info open information requester
FirstPage show first page
LastPage show last page
NextPage show next page
PrevPage show previous page
NextLine scroll one line forwards
PrevLine scroll one line backwards
GotoLine jump to the given line (as first line of visible page)
Search Without argument: open search requester
With searchstring: search for the given text
12. Ideas, Bug reports
====================
As mentioned before Most isn't complete today. There are some points I
will improve in the future. I also have Commodore's Style Guide in
mind and will follow its rules the next release better.
I'm absolut interested in any kind of responds - ideas, enhancements
requests, criticism or bug reports. Call me, write me, mail me. I
will hear you!
My address:
Uwe Roehm
Woerthstr. 18
8390 Passau
Germany
EMail:
roehm@kirk.fmi.uni-passau.de
Fido:
2:246/200.5
13. current Versions
==================
You can download the current version of Most from forwiss.uni-passau.de
(132.231.1.10) in the directory pub/amiga/local/UweR. You will also find
other interesting software in pub/amiga/local....
14. Thanks
========
I want to thank my beta testers
David, Uli, Karl, Holger, Stefan und Stefan ;-)
A special thanks to Urban for his sugesstions and XPK.