Passing Parameters to Auto-Booting Programs
===========================================

Stoop can now pass parametrs to auto-booting programs, though this is not
reliable as it should be because of bugs in TOS 4 or Lattice C which do not
allow the path for a drive or partition to be set.  Environment strings
can also be set at the same time.

To pass parameters to a program another program is needed, in this case
Launcher.prg, which is run instead of the required program and then calls
the program that you want to use. Launcher has to load in details, prepared
by Stoop, which contain the program's name and the other data such as the
filename(s) to be passed and the environment strings to be set.


Setting Up Stoop for Passing Parameters
---------------------------------------

The parameters are attached to the  preset  buttons  so  that  when  you
select a preset configuration to be set up the parameters will be set up
as well.

To set up for passing parameters, set up a button for normal operation,
see the section 'Deleting A Button', but after you have given the button
a name select the LAUNCH button on the dialogue.  A  new  dialogue  will
appear which has two windows, called tail and environment.

These windows can be have text entered into them in two  ways,  you  can
type directly into them or you can  use  the  file  selector  to  either
insert the text from a file or the full name of the file in the  window.
Whatever you choose, the new text will appear at the cursor position.

The tail window should contain  the  parameters  to  be  passed  to  the
program you want  to  use,  this  includes  filenames  or  command  line
parameters.

To enter text into either window using the file selector.

First move the cursor to the line where you  want  the  text  to  appear
(see below for keyboard commands), then call the file selector with the
FSEL button, select the file you want and press OK. Another dialogue now
appears, this gives you three choices; INSERT, PUT NAME or ABORT.

INSERT - Choosing this button will put the text contained in the file
into your window.
(WARNING - only try this with small files of about 10k length).

PUT NAME - This will put the file name, including it's full path, in the
window.

ABORT - Allows you to abort making changes to the text in the window.

Example, if the program for which you are setting the button up is
Gemview, you can put the names of picture  files  you  want  Gemview  to
automatically load and display when you  auto-boot  it.  (Use  the  FSEL
button and PUT NAME to enter the picture files, you can only do this one
at a time.)


Text Window Keyboard Commands
-----------------------------

The four cursor keys move the cursor as normal (left, right, up or down
one space).

Holding a SHIFT key down with either of the left and right cursor keys
to move the cursor to the  start   or   end   of   the   current   line
respectively.

Holding a SHIFT key down with either of the up and down cursor keys will
page the text up or down respectively.

RETURN will add a new line below the current line the cursor is  on.  If
the cursor is in the middle of the line, the text will be split  between
the lines.

DELETE will delete the character the cursor is covering. If  the  cursor
is at the end of the line, this line and the one below will  be  joined,
(any characters over the maximum character line length will be left on
the next line).

BACKSPACE will delete the character in front of the cursor. If the
cursor is at the start of the line, this line and the one above will be
joined, (any characters over the maximum character line length will be
left on the line).

TAB will change the window the cursor is in (this may also be done  with
a click of the mouse on the requred window).

CTRL - Y (hold the Control key down, press Y key before letting  go  of
Control) will delete the current line.
(BUG - the first line cannot be deleted in this way, to get around  this
put the cursor on the first character and press return to move the  line
to the next row and then delete, or just use the  Backspace  and  Delete
keys to remove individual characters.)

CTRL - U (hold the Control key down, press U key before letting  go  of
Control) will put the last line to  be  deleted  by  CTRL  -  Y  at  the
current position of the cursor.

These commands are fairly basic, but they are not intended  to  be  used
with large amounts of text.

NB. The maximum line length is 125 characters, if this is too small,
please let me know. 


Environment Options
-------------------

Just below the Environment window are two recessed displays clicking  on
the first of these will present options which can increase the usefulness
of environment strings.

The options will appear on a pop-up window in the middle of the screen,
they are :-

SEND TO PROGRAM ONLY - this is the  default  setting,  the  contents  of
the environment window are sent to the launcher program which then  sets
them up for the program it will launch.

SEND TO FILE ONLY - the environment window contents are sent to a  file,
the name of the file can be chosen using the file selector  by  clicking
on the second recessed display.

This will allow users of MultiTos to edit a MINT _or_ GEM configuration
file before launching MultiTos. Other programs which have an editable
configuration file may also benefit from this option.

If this is popular, I will add the ability to edit more than one file.

IGNORE ENVIRONMENT - the contents of the environment window are not used
in any way.


Problems With Passing Parameters
--------------------------------

For some reason unknown to me, I cannot set the current path on a drive.
This is a bug in either TOS 4.04 or in Lattice C  5.60.  Please  let  me
know if this is a known bug - and if a fix is possible.

This only causes problems with a few programs which I believe  look  for
their .RSC and .INF files in the current  directory  for  their  current
drive. The only program that I found that does this is  Papyrus  and  to
get around it put the .RSC and .INF files  it  looks  for  in  the  root
directory of drive C (or A if you do not have a harddrive).

Hopefully, I can come up with a better solution to this problem for  the
next release.



