Stuff a key press into the keyboard buffer.
──────────────────────────────────────────────────────────────────────────────

Syntax

GT_StuffKey(<nInkeyCode> | <cChar>) --> lStuffed

Arguments:

<nInkeyCode> is a key code as returned by the Clipper InKey()
function.
<cChar> is a character string of which the first character is
used.

Returns:

A logical value, .T. if the key was stuffed, .F. if not.

Description:

GT_StuffKey() can be used to stuff most of the standard InKey()
codes into the keyboard buffer. The use of this function differs
from using the Clipper KEYBOARD command in a number of ways.
First, it will only stuff one key at a time. Second, it will
accept either keyboard codes or an actual character. Third, it
will stuff many of the keys that the KEYBOARD command will not
cope with, function keys for example.

Note that not all keys have been included, F11 and F12 are examples
of this.

This function is based on FT_PutKey() as coded my Ted Means for the
NanFor Library. The main changes are support for the Alt "-" and
Alt "+" keys plus this function will work in Blinker protected
mode (and so may work with Exospace).


Examples:


// Stuff the character "A" into the keyboard buffer.

GT_StuffKey(65) // Use the key code.
GT_StuffKey("A") // Use the character.
GT_StuffKey("A Test") // Only the first character is used.

// Stuff an F1 key press into the keyboard buffer.

GT_StuffKey(K_F1)


Source: STUFFKEY.C

Author: Dave Pearson