Introduction to the macro program ÒKeyQuencerÓ
by Henry Linton (whljr@aol.com)

A shareware macro program for $10? Yes, but it is so compact that it takes some doing to ferret out the way to make use of it. The reason I looked for an economy macro program was the demise of Macromaker in System 7, with the consequent loss of a few simple macros I had come to love. 

This essay tries to help the new user, and is written in the form of a Òpartial tutorialÓ. Hopefully the programÕs author, Alex Levi Montalcini of Italy (lmontalcini@pmn.it) will like my work.

The program, downloadable from America Online, consists of an INIT and an Application, with all instructions on screen. In a way it is a home macro construction set. All macros created are global, so key  combinations you need or like in your other programs should be avoided, but you can use many control key combinations and function keys so there should be plenty of room. I will assume you have loaded the program and restarted your Mac.

LetÕs prove we can make it work

¥ Press command-option-k. A rectangular KeyQuencer (KQ) display window should appear, thus proving you have installed KQ. Press option-control-c, then option-control-t and notice the KQ window moves. Do it again. You have now used two macros made by the author. It works.

LetÕs make it work without the KQ window showing

¥ Click on some other window so the KQ window is not in front. For instance your Finder window. Then try the option-control-c and option-control-t keypresses. It should work on the Finder window. The macros are indeed GLOBAL.

LetÕs peek at that macro and change the key combination

¥ Now go back to the KQ window and note the list of ready-made macros. Scroll if necessary and find the ÒMove window to centerÓ line. Double-click it. You now see more than you wanted to see, namely a dialog box with the name of the 
macro, the activating key, the macro command script, and a scrollable list of commands you can use to insert command lines. Be of stout heart and ignore everything except the Òmacro keyÓ box! Click where it says opt-ctrl-c and note the whole key combination will be selected. For our example now press control-2 and note it is immediately shown in the macro key box. Click ok. Now try alternating opt-ctrl-t and ctrl-2. The window position should now alternate between upper left and center, thus proving your new key selection is working! You can repeat this and change the ctrl-2 back to opt-ctrl-c as an exercise.

LetÕs pause a moment and look around 

Having shown just a small piece of the program, I suggest we reflect on what we expect of a home macro construction set and note where the author has tucked away all the instructions. Although there is no provision for ÒrecordingÓ a set of moves and presenting us with the resultant script (such as may be done with an Excel spreadsheet), there is a set of prepared commands, a help display, a way to practice and test ideas we may have, a list we can view of what macros we have ÒactiveÓ, a way to save and retrieve sets of macros, and much more.

For example, get the KQ window up front and click on the little picture of a pair of hands on the keyboard. That opens the main documentation and I have found myself going back to it many times. It is especially good at explaining the KQ window or as it calls it, the ÒControl PanelÓ: 

You can print it out but I prefer frequent referral on-screen. Then there is the Òway to practiceÓ device, aka the Macro Editor application. More on that later, if you can hold off.

Creating your first new macro

ItÕs best to start small! One of my simple macros in the MacroMaker days dedicated the F2 key (Functionkey 2) as a substitute for mousing to File and going down to Open; (also done with Cmd-O). I found it easy to remember and useful in virtually every application. Also it ends with an open dialog box, an interesting challenge for a macro. 
You can create a macro using the KQ window, but early-on it is better to use the Macro Editor (MacEd) for reasons IÕll show. Open the MacEd application, note that a blank document appears titled KeyQuencer Macro 1; then proceed:

Step 1. What will be our logic? I stumbled around with a wrong answer and three possible right answers. In words, my four were: (1) type command-o, (2) press the key combination command-o, (3) go to the file menu and choose Open, and (4) (shorthand for the latter) go to Menu 2 and choose item 2. For each line of logic we need the correct syntax; letÕs try them in order.

Step 1a1.  Go to the Extensions menu, scroll down to Type and let go. The word Type shows on our KQM 1. Then scroll down again to type and on the submenu to the right, choose cmd. But there is no ÒcmdÓ! We need help! 

(I ignored this for a while and tried Type ÒCmd-OÓ and things like that but they all failed the test. That is, when I chose ÒTry MacroÓ under the File menu all I got was the appearance of the text ÒCmd-OÓ on the page! You may get other fascinating messages, but no macro!)

Step 1a2.  So go to the Extensions menu, choose Help, and click the upper right window box to expand it to full screen. Now we have a list of all the commands and their syntax, more or less explained. If we look under Type, we see 

*  Types some text into the frontmost application (you may use more than one parameter)
*  Type "text"/clipboard/return/date/time/$20
*  "text" = Types some text

There is nothing to indicate that the command ÒTypeÓ can cause the command key to get into the picture. So move on to logic #2.

Step 2a. Going down the Extensions list we see Key, so letÕs try that by letting up on the mouse button when we are over Key. The word Key appears on our KQM blank. Only it isnÕt blank - Type is still there. Delete Type.

Step 2b. Now scroll down again to Key and move to the submenu and choose cmd (it is first on the list).

Step 2c. Now repeat and from the submenu, choose ÒaÓ. It appears on the KQM but it seems logical to change the ÒaÓ to ÒoÓ. WeÕll guess that upper case or lower case doesnÕt matter.

Step 2d. LetÕs test it by Test Macro from the File menu (or cmd-t). It works and the dialog box appears!

Step 2e. Select the text on the KQM (Key cmd o) and copy it to the scrapbook! No further embellishments needed.

Logic #3 mostly works and it is very revealing to try it.

Step 3a. Going down the Extensions list we see Menu, so select that. The word Menu appears on our KQM blank. (Of course you have deleted the previous listing, right?).

Step 3b. Now again to Menu, across to submenu, and select ÒMenu NameÓ, which you change to ÒFileÓ on KQM.

Step 3c. Ditto but select ÒMenu ItemÓ, which you change to ÒOpen...Ó on KQM. Note that it isnÕt just plain ÒOpenÓ, or Open followed by three periods, it has to be the ellipsis, which is option-semicolon!

Step 3d. Try it; it doesnÕt work on KQM because the File menu says Open MacroÉ, but it will work on Word and other major applications. Still, it has more limits than ÒKey cmd oÓ.

Logic #4 works more than Logic #3, but not always. Like #3 it uses the Menu approach, but just uses the number of the items. So the command is Menu 2 2, meaning choose menu #2,Êalways File, then item #2, most always some kind of Open.

But note that even Logic#2 doesnÕt do anything if you arenÕt anywhere where there is something to open. For example in the Finder with nothing selected, pressing the macro key to give cmd-o wonÕt do anything, good or bad.

Put your created macro on the active list

The active list must be on the KeyQuencer control panel, so open that with cmd-opt-k. On the pseudo File menu choose New Macro. Type in a name like Open File and tab once, to the macro key field. I pressed F2 (function key #2) here to get my old favorite activator. Briefly exit to the Finder window and go to your scrapbook entry of ÒKey cmd oÓ (without the quotes) and copy it for pasting in the KQ window in the Macro script field. Then click OK and you have it for use right away.

A more complicated macro

I use America Online frequently just to send and receive mail and log off, all in one automated swoop. They call it flashmail but there is too much mouse action for me. Here is my macro for doing it with one keypress: I only use this in AOL so the Menu 4 11 is specific and the Key return chooses NOT to stay online after getting mail. The Volume 2 sets the Mac speaker volume loud enough to hear the dialing, and the quiet says donÕt sound a beep along the way. It works!

Note the Macro Mini-creator in the KQ macro edit window

In lower left there is a small scrollable window for creating macros. It is just like the Macro Editor but when you get a result it is ready to go. ItÕs another easy way to run tests.
Other Goodies for the $10.00

1. A pre-made macro, ctrl-keypad-*, briefly shows the time in a box onscreen. 
2. Another, cmd-opt-ctrl-3 captures to clipboard any rectangular area you choose.
3. Another, cmd-opt-ctrl-6 displays screen/window location of next click or drag.
4. The Click command lets you specify screen/window coordinates to be clicked
5. The Changeclip lets you manipulate a clipboard like a text editor.
6. There is a HyperCard modification to permit macro control from stacks.
7. A long macro sequence can be called from a text file.

Summary:
Requires digging but very ingenious and I am using it!

Henry Linton
October 31, 1994
