Left-Ctrl-A disabler - No more lost text

by Andrew Rowland

Have you ever been typing an 'A' and accidentally hit the Ctrl key as well? If you use a DTP package you will have seen your whole text story selected, and the next keypress will delete the lot! To avoid this annoying (and, in the case of the author, embarrassingly frequent) occurrence, CtrlAdis was written.

This small module catches any <Ctrl-A> characters you may type and replaces them with the letter A (in either capitals or lower case depending on the state of Caps Lock, Shift etc.) so you will remain entirely ignorant of your clumsiness. You may still type a real <Ctrl-A> by using the right-hand Ctrl key. After all, it's useful at times!

Running CtrlAdis from the RISC User menu system opens a directory viewer containing the module (CtrlAmod) and its source code (CtrlAsrce). Double-clicking on the module will install it.

To disable the module, press F12 and enter:
    RMKill CtrlAdis

If you use it constantly, you could copy CtrlAmod onto your hard disc and include this line in your boot file:
    RMLoad <path>.CtrlAmod
where <path> is the full pathname of the module.

Alternatively, if you only want to run it when you use a DTP package, copy it into your Ovation Pro or Impression directory and include in the application's !Run file the line:
    RMEnsure CtrlAdis 1.00 RMload <Obey$dir>.CtrlAmod

Updating CtrlAMod
CtrlAMod was written primarily for use with older Acorn keyboards, on which the Ctrl key was immediately to the left of 'A' and Caps Lock was at the very bottom left-hand corner. With newer keyboards, these keys have been exchanged, so hitting <Ctrl-A> by accident isn't as much of a problem as it used to be. However, it's still easy to type <Ctrl-A> instead of <Ctrl-S> (which is often used for swapping the case of a letter in DTP packages), so the utility remains useful for avoiding that situation.

CtrlAMod is certainly the sort of program that can usefully be extended or adapted to suit different situations, though, and an example of a small modification is supplied on the disc: StarChar causes an asterisk to be typed rather than a letter 'A' if you press <Ctrl-A>, to make this particular typing error easier to spot than a (perhaps unwanted) letter 'a' inserted in the text.

The full source code for the module is provided, so if you come up with any suitably improved version of the module, do please send them in. If we choose to publish your submission, you will of course receive payment for it.


Copyright  RISC User magazine 1998