Many of Mac OS X's standard keyboard shortcuts, such as "New Folder" (Shift + Command + N), "Save As" (Shift + Command + S), and "Paste and Match Style" (Option + Shift + Command + V), require pressing multiple keys simultaneously. While this isn't very difficult to do with KeyStrokes or SwitchXS, it would be much easier if you could save yourself two or three clicks by triggering complex commands like these with one button. Fortunately, LayoutKitchen makes this possible -and it couldn't be easier!
This article will show you how to create a Text Macro button in LayoutKitchen that simultaneously activates multiple keys. For demonstration purposes, we'll be adding a button to a KeyStrokes panel that takes a picture of the screen; however, if you want to add the button to a SwitchXS panel or change its function to something else, such as "Save As," the same basic steps should apply.
For this tutorial we'll be adding our button to an existing KeyStrokes panel. In LayoutKitchen, choose KS Panels and select an existing panel to open it.
In the Inspector, click the item kind pop-up menu and select Text Macro.
Click "New Button" to add a new Text Macro button to your panel. Position and size the button as you like.
Now we will set style and color options for the button. With the button still selected, in the Appearance section of the Inspector click the pop-up menu beside the word "Design" to set the design of the key. For this example we chose the Snow Key design.
Click the pop-up menu beside the word "Display" and select Label Only so only the button's label is displayed.
Click the color swatch directly below the word "Label" to bring up the Mac OS X Colors panel and set the label color. If it is not visible, click the small color wheel icon to bring up the color wheel. Make sure the small dot is centered in the middle of the color wheel and then drag the brightness slider towards the center so a shade of grey is selected. Click OK.
Click the color swatch directly below the word "Button" to bring up the Mac OS X Colors panel and set the button color. Click the red part of the color wheel near the edge and then drag the brightness slider all the way to the top so a bright shade of red is selected. Click OK.
Now we will enter the button's content including its Text Macro. In the Content section of the Inspector, click in the Description field and type "This button takes a picture of the screen".
Click in the Label field and title the button "Take a Picture".
Click in the Cue text field and type Take a Picture. If "Speak the key or suggestion below the cursor" is selected in the Audio & Visual Feedback section of the KeyStrokes preferences, KeyStrokes will speak this text when the cursor is over the button.
Now for the fun part: assigning the button's Text Macro. Click in the Text Macro field and then click the key list pop-up menu situated directly above it. From there, select Command from the list and then press "Add Key". A bracketed command down and command up instruction is added to the Text Macro field.
Click in between the command down and command up instruction. From the key list pop-up menu, select Shift from the list and then press "Add Key". A bracketed shift down and shift up instruction is inserted between the command down and command up instruction.
To complete the Text Macro, click in between the shift down and shift up instruction and type "3".
Right below the Text Macro field, make sure the option for "Allow auto repeat" is unchecked.
Choose File > Save to save your panel. Please note that if you are editing a read-only panel, such as those that come preinstalled with KeyStrokes, you will have to choose File > Save As to save your panel and give it a new name.
From the KeyStrokes Keyboard menu, select the panel that contains the new Text Macro button.
To test it, click "Take a Picture". If you hear a camera sound and see a new file titled "Picture 1" appear on your desktop, voila, you have correctly made a Text Macro button that simultaneously activates multiple keys!
- Joe Barnick