home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 1: Amiga
/
FrozenFish-Apr94.iso
/
bbs
/
alib
/
d8xx
/
d887
/
throwmouse.lha
/
ThrowMouse
/
throwmouse.doc
< prev
next >
Wrap
Text File
|
1993-07-16
|
9KB
|
213 lines
===================== ThrowMouse 0.7 documentation ========================
===========================================================================
A simple Workbench tool to be used with Kickstart 2.x/3.x, written by
Roland 'Gizzy' Mainz, freeware, all rights reserved.
No guarantee of any kind is made that the programm described below in this
document is 100% reliable. You use this material on your own risk.
=========================== Misc ==========================================
===========================================================================
I did it every day. Monday till sunday I turned on the computer.
And I had to open one, two, three ... drawers.
There must be another way. The Workbench has no REXX port...
Hacks won't work with future OS releases...
'Get the mouse... double-click... once again...'
Whoops, there was a light in the darkness. The input.device...
Every user input is passed through this device. And programs are allowed to
send their own input streams.
Throw the mouse away (at first on startup). 'ThrowMouse' was born.
A little tool for replacing the mouse.
This release of 'ThrowMouse' may open a couple of specified icons,
on choice with a delay and so on (see below).
=========================== Installation ==================================
===========================================================================
Workbench: Drop the 'ThrowMouse' icon in your favorite drawer (like
Sys:WBStartup/ or Sys:Utilities). Be sure that the tooltype
DONOTWAIT is set, otherwise the Workbench will call with a requester
(only WBStartup).
CLI/Shell: Drop/Copy the 'ThrowMouse' file in your favorite directory
(like Sys:Utilities).
If you like to run the programm at startup, get your favorite editor
and add this line to S:user-startup (NOT Startup-Sequence !!):
run >nil: <nil: Sys:Utilities/ThrowMouse <args>
=============================== Usage =====================================
===========================================================================
From WB:
Look at first on the main 'ThrowMouse' icon (with Icons/Information...)
The only tooltype allowed there is DONOTWAIT.
Make a copy of this icon with IconEdit, select the menu item
Type/Project (the icontype is now PROJECT) and now you may select
the tooltypes of your choice.
RULES and TIPS for WBStartup
Be sure that the icons in the WBStartup drawer have the STARTPRI=-127
set because other programs may take much CPU performace and
'ThrowMouse' won't work correctly.
You also may set a WAIT=10 (minimum) to let the system settle before
starting operating.
Connecting project icons in the WBStartup drawer via NEXTDOBJ is
not a very good idea because the workbench will execute all of them.
Multiple 'ThrowMouse' icons in the WBStartup drawer without the
NEXTDOBJ tooltype are allowed.
example:
DONOTWAIT
STARTPRI=-127
...
NEXTDOBJ=sys:wbstartup/throwmouse.nextdobj /* wrong !!
only one root icon
in the WBStartup
drawer */
NEXTDOBJ=sys:utilities/throwmouse.nextdobj /* right !
all other project
icons must be in
another drawer */
WARNING
Loops with NEXTDOBJ are not allowed, you can't stop them and the tool
will crash.
From CLI / Shell:
ThrowMouse <args>
TEMPLATE
X=LEFT/N,Y=TOP/N,CLICK=CLICKS/N,WAIT=DELAY/N,WIN=WINDOW/K,DOBJ=ICON/K,
ACTIVATELASTWINDOW=ALW
VALID TOOLTYPES / SHELL ARGUMENTS
(The tooltypes in brackets (like DELAY) are not available from
Workbench yet)
X the X coordinate of the pointer's new position
(DEFAULT X=0)
Y the Y coordinate of the pointer's new position
(DEFAULT Y=0)
CLICK(=CLICKS)the left mousebutton clicks over the target
(DEFAULT CLICK=0
WAIT(=DELAY) the time delay in seconds to wait before starting
the action
(WIN=)WINDOW name of an existing window whitch topedge and leftedge
are added to the X and Y coordinates
The naming of windows is case sensetive, but you need
not type the full name;
example: <Ram Disk 100% full> --> WIN=Ram
DOBJ(=ICON) the icon witch middle coordinates relative to the window's
topedge & leftedge are added to the X and Y coordinates
YOU MUST SPECIFY THE FULL PATH
ACTIVATELASTWINDOW(=ALW)
when ThrowMouse finishes work with it's source icon,
the old activewindow is activated.
NEXTDOBJ (Workbech only !!!)
The next project icon to pass through 'ThrowMouse'.
To connect multiple ThrowMouse project icons to a script
EXAMPLE (From CLI / Shell)
ThrowMouse X=0 Y=0 DELAY=5 WIN=System2.0 DOBJ=sys:tools clicks=2
/* will open the 'Tools' drawer in the sys: device */
ThrowMouse X=0 y=0 WIN=AmigaShell
/* will move the pointer to the window called 'AmigaShell' */
ThrowMouse X=100 Y=200
/* will move the pointer to the position X=100 Y=200 */
SCRIPT EXMAPLE (from Workbench)
ICON "sys:wbstartup/throwmouse.project.info"
DONOTWAIT
STARTPRI=-127
X=0
Y=0
CLICK=2 /* double click = open drawer... */
WAIT=20 /* wait 20 seconds */
WINDOW=System2.0 /* targed window is "System2.0..."
DOBJ=System2.0:Tools /* the dobj filename (without .info) */
(ACTIVATELASTWINDOW) /* inactive tooltype */
NEXTDOBJ=sys:utilities/throwmouse.project2
ICON "sys:utilities/throwmouse.project2.info"
DONOTWAIT
X=0
Y=0
CLICK=2
WAIT=5
WINDOW=System2.0
DOBJ=System2.0:Utilities
================== CALCULATING THE MOUSE POSITION =========================
===========================================================================
The target position of the mouse may be calculated with this term:
mouseX = X + /* if X is specified */
window's leftedge + /* if WINDOW is specified */
(dobj's leftedge + (dobj's width / 2)) /* if WINDOW and
DOBJ is specified */
mouseY = Y + /* if Y is specified */
window's topedge + /*if WINDOW is specified */
(dobj's topedge + (dobj's height / 2)) /* if WINDOW and
DOBJ is specified */
X = the value set with the 'X' tooltype/arg
Y = the value set with the 'Y' tooltype/arg
window's leftedge = the border coordinates of the window's INNER frame
relative to it's screen
dobj's ... = the ICON's coordinates relative to it's window
=============================== TODO ======================================
===========================================================================
Split up the project in two parts:
ThrowMouse.commodity with REXX port ...
ThrowMouse
Repair any current bug
Add some tooltypes like DELAY, ALW...
=========================== Author's Request ==============================
===========================================================================
By releasing this program I do not place any obligations on you,
feel free to share this program with your friends (and enemies).
If you want to blame me, report any bugs or want the source,
send your letter to:
Roland Mainz
Hohenstaufenstraße 8
D-5164 Nörvenich
GERMANY
But, should you feel the need to make any contributions, send them to:
Fred Fish
Amiga Library Disks
1835 East Belmont Drive
Tempe, Arizona 85284
USA
for his great AMIGA library, and his work all over the years.
The entire ThrowMouse package may be noncommercially redistributed,
provided that the package is always distributed in it's complete form
(including it's documentation). A small copy fee for media costs is okay
but any kind of commercial distribution is strictly forbidden!
Comments and suggestions how to improve this program are generally
appreciated!
Thanks to Matt Dillon for his DICE, and Olaf 'Olsen' Barthel for his
help, ideas and some text clips from his documentations.
=========================== footnotes =====================================
===========================================================================
dobj short form of Disk OBJect