3 * Converts keypresses to strings
5 * © 1992-1998 Straylight
8 /*----- Licensing note ----------------------------------------------------*
10 * This file is part of Straylight's Steel library.
12 * Steel is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2, or (at your option)
17 * Steel is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with Steel. If not, write to the Free Software Foundation,
24 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
31 * char *keyString(int key)
34 * Converts a keypress as returned by the WIMP into a string suitable for
35 * displaying to the user, for example as a keyboard shortcut. The routine
36 * handles the following cases:
38 * * Function keys and Print, possibly with <Shift> and/or <Ctrl>
39 * * Alphabetic keys with <Ctrl>
41 * Note: f12 is not trapped; neither is <Ctrl> M, since this is <Return>.
44 * int key == the key pressed
47 * A pointer to a READ-ONLY string, or 0 if the key was invalid.
50 char *keyString(int key);
53 * char *keyString_convert(int key,BOOL mnu)
56 * Converts a STEEL extended keypress into a string suitable for displaying
57 * either as a short-cut string in a dialogue box or in a menu
60 * int key == the keypress to translate
61 * BOOL mnu == TRUE to create menu shortcut string, FALSE for dbox
64 * A pointer to the string, or 0
67 char *keyString_convert(int key,BOOL mnu);