| 1 |
– |
/* Copyright (c) 1995 Regents of the University of California */ |
| 2 |
– |
|
| 1 |
|
#ifndef lint |
| 2 |
< |
static char SCCSid[] = "$SunId$ LBL"; |
| 2 |
> |
static const char RCSid[] = "$Id$"; |
| 3 |
|
#endif |
| 6 |
– |
|
| 4 |
|
/* |
| 5 |
|
* editline.c - routine for editing raw input for rview. |
| 6 |
|
* |
| 7 |
< |
* 10/5/88 |
| 7 |
> |
* External symbols declared in driver.h |
| 8 |
|
*/ |
| 9 |
|
|
| 10 |
+ |
#include "copyright.h" |
| 11 |
+ |
|
| 12 |
+ |
#include "color.h" |
| 13 |
+ |
|
| 14 |
+ |
#include "driver.h" |
| 15 |
+ |
|
| 16 |
|
#define iscntrl(c) ((c) < ' ') |
| 17 |
|
#define isblank(c) ((c) == ' ') |
| 18 |
|
#define iserase(c) ((c) == '\b' || (c) == 127) |
| 20 |
|
#define iskill(c) ((c) == 'U'-'@' || (c) == 'X'-'@') |
| 21 |
|
|
| 22 |
|
|
| 23 |
+ |
void |
| 24 |
|
editline(buf, c_get, s_put) /* edit input line */ |
| 25 |
|
char *buf; |
| 26 |
< |
int (*c_get)(), (*s_put)(); |
| 26 |
> |
int (*c_get)(); |
| 27 |
> |
void (*s_put)(); |
| 28 |
|
{ |
| 29 |
|
static char erases[] = "\b \b"; |
| 30 |
|
static char obuf[4]; |
| 68 |
|
} |
| 69 |
|
|
| 70 |
|
|
| 66 |
– |
#include "driver.h" |
| 67 |
– |
|
| 71 |
|
static char mybuf[512]; |
| 72 |
|
|
| 73 |
|
|
| 74 |
+ |
void |
| 75 |
|
tocombuf(b, d) /* add command(s) to my buffer */ |
| 76 |
|
register char *b; |
| 77 |
|
register struct driver *d; |
| 93 |
|
} |
| 94 |
|
|
| 95 |
|
|
| 96 |
+ |
int |
| 97 |
|
fromcombuf(b, d) /* get command from my buffer */ |
| 98 |
|
char *b; |
| 99 |
|
struct driver *d; |