projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
added "more" command
[unix-history]
/
usr
/
src
/
usr.bin
/
window
/
tth19.c
diff --git
a/usr/src/usr.bin/window/tth19.c
b/usr/src/usr.bin/window/tth19.c
index
9d2c703
..
cda00af
100644
(file)
--- a/
usr/src/usr.bin/window/tth19.c
+++ b/
usr/src/usr.bin/window/tth19.c
@@
-1,7
+1,13
@@
#ifndef lint
#ifndef lint
-static char
*sccsid = "@(#)tth19.c 3.11 83/12/17
";
+static char
sccsid[] = "@(#)tth19.c 3.14 %G%
";
#endif
#endif
+/*
+ * Copyright (c) 1983 Regents of the University of California,
+ * All rights reserved. Redistribution permitted subject to
+ * the terms of the Berkeley Software License Agreement.
+ */
+
#include "ww.h"
#include "tt.h"
#include "ww.h"
#include "tt.h"
@@
-33,7
+39,7
@@
extern char *gen_VE;
int h19_msp10c;
int h19_msp10c;
-#define pc(c)
putchar
('c')
+#define pc(c)
ttputc
('c')
#define esc() pc(\033)
#define PAD(ms10) { \
register i; \
#define esc() pc(\033)
#define PAD(ms10) { \
register i; \
@@
-89,7
+95,7
@@
register char c;
h19_setmodes(tt.tt_nmodes);
if (tt.tt_ninsert != tt.tt_insert)
h19_setinsert(tt.tt_ninsert);
h19_setmodes(tt.tt_nmodes);
if (tt.tt_ninsert != tt.tt_insert)
h19_setinsert(tt.tt_ninsert);
-
putchar
(c);
+
ttputc
(c);
if (tt.tt_insert)
ICPAD();
if (++tt.tt_col == NCOL)
if (tt.tt_insert)
ICPAD();
if (++tt.tt_col == NCOL)
@@
-106,14
+112,14
@@
register n;
h19_setinsert(tt.tt_ninsert);
if (tt.tt_insert) {
while (--n >= 0) {
h19_setinsert(tt.tt_ninsert);
if (tt.tt_insert) {
while (--n >= 0) {
-
putchar
(*p++);
+
ttputc
(*p++);
ICPAD();
tt.tt_col++;
}
} else {
tt.tt_col += n;
while (--n >= 0)
ICPAD();
tt.tt_col++;
}
} else {
tt.tt_col += n;
while (--n >= 0)
-
putchar
(*p++);
+
ttputc
(*p++);
}
if (tt.tt_col == NCOL)
tt.tt_col = NCOL - 1;
}
if (tt.tt_col == NCOL)
tt.tt_col = NCOL - 1;
@@
-151,8
+157,8
@@
register char row, col;
}
esc();
pc(Y);
}
esc();
pc(Y);
-
putchar
(' ' + row);
-
putchar
(' ' + col);
+
ttputc
(' ' + row);
+
ttputc
(' ' + col);
out:
tt.tt_col = col;
tt.tt_row = row;
out:
tt.tt_col = col;
tt.tt_row = row;
@@
-161,7
+167,7
@@
out:
h19_init()
{
if (gen_VS)
h19_init()
{
if (gen_VS)
-
fputs(gen_VS, stdout
);
+
ttputs(gen_VS
);
esc();
pc(w);
esc();
esc();
pc(w);
esc();
@@
-176,7
+182,7
@@
h19_end()
h19_setmodes(0);
h19_setinsert(0);
if (gen_VE)
h19_setmodes(0);
h19_setinsert(0);
if (gen_VE)
-
fputs(gen_VE, stdout
);
+
ttputs(gen_VE
);
esc();
pc(v);
}
esc();
pc(v);
}
@@
-210,8
+216,8
@@
tt_h19()
float cpms = (float) wwbaud / 10000; /* char per ms */
h19_msp10c = 10 / cpms; /* ms per 10 char */
float cpms = (float) wwbaud / 10000; /* char per ms */
h19_msp10c = 10 / cpms; /* ms per 10 char */
- gen_VS = tt
_
xgetstr("vs");
- gen_VE = tt
_
xgetstr("ve");
+ gen_VS = ttxgetstr("vs");
+ gen_VE = ttxgetstr("ve");
tt.tt_init = h19_init;
tt.tt_end = h19_end;
tt.tt_init = h19_init;
tt.tt_end = h19_end;