home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Professional
/
OS2PRO194.ISO
/
os2
/
editor
/
me
/
whatchar.m
< prev
next >
Wrap
Text File
|
1994-01-31
|
476b
|
22 lines
/*
WHATCHAR
The whatchar() macro is invoked by pressing <CTRL Q>. It prints the ASCII
value of the character over the cursor on the status line. A nice idea
would be to set a hook to this function so that this value is displayed
somewhere on the screen after every key is pressed.
*/
#define CTRL_Q 17
init()
{
assign_key("what_char", CTRL_Q);
}
what_char()
{
message(sprintf("Character under the cursor is %d", currchar()));
get_tty_char();
}