home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
QBasic & Borland Pascal & C
/
Delphi5.iso
/
C
/
Samples
/
CSAPE32.ARJ
/
SOURCE
/
CSSRC
/
SPCEMBTD.C
< prev
next >
Wrap
C/C++ Source or Header
|
1990-10-05
|
1KB
|
65 lines
/*
spcembtd.c 12/14/88
% spc_EmbedTed
C-scape 3.2
Copyright (c) 1988, by Oakland Group, Inc.
ALL RIGHTS RESERVED.
Revision History:
-----------------
11/13/89 jmd added non-DOS scancodes
3/28/90 jmd ansi-fied
10/05/90 pmcm removed CTRL_U, CTRL_D aliases for CTRL_PGUP, CTRL_PGDN
(CTRL_PGUP CTRL_PGDN avail. as meta keys on non-DOS systems)
*/
#include <stdio.h>
#include <ctype.h>
#include "cscape.h"
#include "scancode.h"
/* special function for embedded teds */
boolean spc_EmbedTed(sed_type sed, int scancode)
/*
effects: untraps editing keys from spc_Embed
returns: whatever spc_Embed returns
*/
{
switch (scancode) {
case UP:
case DOWN:
case TAB:
case SHFT_TAB:
case ENTER:
/* don't let spc_Embed catch these keys */
return(FALSE);
case CTRL_PGUP:
/* move upward in embeding sed */
sed_SetBaton(sed, BOB_UP);
sed_ToggleExit(sed);
return(TRUE);
case CTRL_PGDN:
/* move downward in embeding sed */
sed_SetBaton(sed, BOB_DOWN);
sed_ToggleExit(sed);
return(TRUE);
default:
break;
}
return(spc_Embed(sed, scancode));
}