VAN ~~~ by Robin Luiten 10 Chartwell St Aspley 4034 Brisbane Qld Australia "van" - short for Vanish [If you like "Very Active Nothing (generator)"] Written in 100% assembler. Version 2.0 22/08/90 USAGE: "van [switches] [command]" NOTE: van ? - produces a short help for the command SWITCHES: -t : default time - 60 seconds The number following -t is the decimal blank out time in seconds eg '-t34' sets the time required till blank to 34 seconds. -q : Can specify a command qualifier key other than LeftAmiga. eg '-q0008' specifies command key as CTRL The number entered following '-q' is the hexadecimal code input event qualifier as defined in include file : 'devices/inputevent.i'. ( see list below ) -e : If '-e' not found then command execution function is attached to -opensinglequote. If '-e' found then command execution functions is attached to -esc. LIST OF ACCEPTED QUALIFIERS To use LeftShift key : -q0001 ( not good to use by itself ) ( cant use LeftShift by it self as I use it for FORCE screen Blank ) To use RightShift key : -q0002 ( not good to use by itself ) To use CONTROL key : -q0008 To use LeftALT key : -q0010 To use RightALT key : -q0020 To use LeftAmiga key : -q0040 ( This is the default. ) To use RightAmiga key : -q0080 Any combination of the above can be used as the command qualifier. To create a multi key, key qualifier OR the individual qualifier key values together. eg '-q0048' sets the command qualifier to be LeftAmiga-Ctrl. NOTES: All references to the command key as being LeftAmiga should be read as whatever key you are using for command qualifier. INTRODUCTION: This program is FreeWare, so copy it around if you like. NOTE : I have released version 2.0 source code as part of the Macro68 Assembler package from DigiSoft. Feel free to modify and use any or all of the code in other programs, however please do not release any of your own versions of 'VAN' or 'Vanish' as I will continue to update and improve VAN. If you wish to release your own versions then come up with another name. It would be nice to get some recognition if you decide to include 'VAN' in something you are distributing. Feel free to contact me about bugs, improvements or ideas for other projects. THINGS I WILL NOT DO: I will not be adding Mouse Acceleration because I dont like it. I also will not be adding sun-mouse as it does not integrate very well with the Amigas operating system. ( specifically sun mouse generally stuffs up the keyboard short cuts for System Requesters ) USAGE NOTES: The cli/program that pops up when you hit that particular hot key inherits the path and prompt from the CLI it was started from. The easiest way to see if van is installed is to hit the left shift key 3 times in a row. If the screen blanks then van is installed. ( Unless you have got something else that causes the screen to blank on three left shift keys.[Ha as if you would.]) It does not matter if the CapsLock key is on for the three left shifts to blank the screen. However any other qualifer key ( like Left Alt, Right Alt, Ctrl, Left Amiga, Right Amiga ) will stop the three left shifts from blanking the screen. The minimum accepted value for timeout is 10 seconds. If your time argument is not above this bound then 'van' will not install itself. The Maximum value for time out that is possible to set is : 6553 seconds. ( about 1.8 hours ). Values above this entered on the command line will have unpredicatable results. That is the timeout value will not be predictable, nothing nasty or such will happen to the system. If the command has to contain spaces it should have quotes around it. The two types of quotes recognised are ["] and [']. ( ie standard double quotes and close single quotes ) LAZY MAN QUOTES: I have a really neat argument parser that supports Lazy Man Quotes. Lazy Man Quotes mean that if you open a quoted argument and do not close it then the rest of the line after the open quote is treated as a single argument. ( I like it anyway ) This means that the following four commands do exactly the same thing. 1) run van -t50 'ashell from s:InitVan 2) run van -t50 'ashell from s:InitVan' 3) run van -t50 "ashell from s:InitVan 4) run van -t50 "ashell from s:InitVan" If you want to include quotes in your command string (as in example 2 below) then you must quote the command with the other sort of quotes to the one you wish to include in your command. EXAMPLES: 1) run >NIL: van - This allows you to close the cli window that you run 'van' from - Sets up van to run using default values of command = "newcli and time = 60 seconds. 2) run >NIL: van -t60 'newshell "CON:0/12/620/240/ Van Cli" from S:Van-Shell"' - this is the way that I use van. 3) run van -t10 - you are not able to close the cli that can was started from now - the screen blanks after 10 seconds of nothing happening. - the command is the default "newcli" command. 4) run van - install van using default values. run van ( second time ) - uninstall van. FEATURES: ) Running van a second time makes van uninstall itself. ) LeftAmiga-` ( amiga open single quote, [below esc key] ) This HotKey pops WorkBench screen to front then executes the user command. (ala popcli) This can be moved to LeftAmiga-Esc if '-e' switch found. ) When ever the given number of seconds have passed without any input activity, then the screen is blanked. ) Pressing the left shift key 3 times in succesion with no other keys or anything between the 3 Left Shifts cause the screen to immediately be blanked. ) LeftAmiga-m : performs the function Front Screen to Back. The normal action of this key is WorkBench Screen to Back. ( I like to be able to look at all the screens that are currently opened. ) ** ) LeftAmiga-n key moves the bottom screen to front. ** ) LeftAmiga-w moves WorkBench Screen TO Front. This Feature LeftAmiga-w is currently dissabled as it annoyed me. ) Any input except for a left shift key will unblank the display if the display is currently blanked. ) LeftAmiga-J pop the bottom window on screen to front. In this case I dont care about windows < 12 pixels high. ) LeftAmiga-K push the top window on screen > 12 pixels high to back. This does not push front window to back if there is only one window on the screen. There is an exception to this rule, if the single windows title begins with the string 'Uedit V' then this window will be pushed to the back unlike other single windows on screens. This allows access to the screens Drag bar and front back gadgets on the Uedit screen (dont know why yet) but I love this "accidental" feature. ) LeftAmiga-A activate the most front window with height > 12 pixels high. ** ) LeftAmiga-t Tag a window to be the window to be swapped two from the current one using the command key LeftAmiga-z ** ) LeftAmiga-z Activates and moves the tagged window to the front. What this command does is store the current window as tagged and then restore the previously tagged window as current and active. Executing this command twice returns you to the same active window that you were in before you executed the first LeftAmiga-z. ** ) LeftAmiga-Delete Escapes the next command character that van normally recognises (including itself) and passes it through to intuition and all other processes instead of eating the event. Absolutely necessary for that one of command that you suddenly discovered you cant execute because VAN uses is for itself. NOTE : this only applies to the LeftAmiga - ? format commands. " You know, necessity really is the mother of invention. " FUTURE: *) Next version will likely see van split into two executables. Executable 1 will van as it is now with all command lines switches taken out. Executable 2 will be a customisation interface which physically sets up the options wanted ON/OFF in the first executable. *) Something interesting to watch while screen blanked. I am still condering something cheap CPU time wise that would do. REFERENCES: "popcli" - Written by "The Software Distillery" is a screen blanker and a 'popcli' utility available on Fish Disks. (Jeese : I cant explain it any better'n than that can you.) "shuffler" - Written by Jeff Lavin this little input handler takes over the job of popping screens forward and back ward using the LeftAmiga - n and m keys. "MachII" - General screen blanker/ popcli / macros / sunmouse / mouse accelrator / etc available on Fish Disks. Hope you like this little beasty, Bye...