| Line | |
|---|
| 1 | /* Copyright (c) 1985 Ceriel J.H. Jacobs */
|
|---|
| 2 |
|
|---|
| 3 | /* $Header: /cvsup/minix/src/commands/yap/output.h,v 1.1.1.1 2005/04/21 14:55:40 beng Exp $ */
|
|---|
| 4 |
|
|---|
| 5 | # ifndef _OUTPUT_
|
|---|
| 6 | # define PUBLIC extern
|
|---|
| 7 | # else
|
|---|
| 8 | # define PUBLIC
|
|---|
| 9 | # endif
|
|---|
| 10 |
|
|---|
| 11 | PUBLIC int _ocnt;
|
|---|
| 12 | PUBLIC char *_optr;
|
|---|
| 13 |
|
|---|
| 14 | #define putch(ch) if (1) {if (--_ocnt <= 0) flush(); *_optr++ = (ch);} else
|
|---|
| 15 |
|
|---|
| 16 | VOID flush();
|
|---|
| 17 | /*
|
|---|
| 18 | * void flush()
|
|---|
| 19 | *
|
|---|
| 20 | * Write the output buffer to the screen
|
|---|
| 21 | */
|
|---|
| 22 |
|
|---|
| 23 | VOID nflush();
|
|---|
| 24 | /*
|
|---|
| 25 | * void nflush()
|
|---|
| 26 | *
|
|---|
| 27 | * Clear output buffer, but do not write it
|
|---|
| 28 | */
|
|---|
| 29 |
|
|---|
| 30 | int fputch();
|
|---|
| 31 | /*
|
|---|
| 32 | * int fputch(c)
|
|---|
| 33 | * int c; The character to be printed
|
|---|
| 34 | *
|
|---|
| 35 | * Put character "c" in output buffer and flush if necessary.
|
|---|
| 36 | */
|
|---|
| 37 |
|
|---|
| 38 | VOID putline();
|
|---|
| 39 | /*
|
|---|
| 40 | * void putline(s)
|
|---|
| 41 | * char *s; The string to be printed
|
|---|
| 42 | *
|
|---|
| 43 | * Put string "s" in output buffer etc...
|
|---|
| 44 | */
|
|---|
| 45 |
|
|---|
| 46 | VOID cputline();
|
|---|
| 47 | /*
|
|---|
| 48 | * void cputline(s)
|
|---|
| 49 | * char *s; The string to be handled
|
|---|
| 50 | *
|
|---|
| 51 | * Put string "s" in the output buffer, expanding control characters
|
|---|
| 52 | */
|
|---|
| 53 |
|
|---|
| 54 | VOID prnum();
|
|---|
| 55 | /*
|
|---|
| 56 | * void prnum(n)
|
|---|
| 57 | * long n; The number to be printed
|
|---|
| 58 | *
|
|---|
| 59 | * print the number "n", using putch.
|
|---|
| 60 | */
|
|---|
| 61 |
|
|---|
| 62 | char *getnum();
|
|---|
| 63 | /*
|
|---|
| 64 | * char *getnum(n)
|
|---|
| 65 | * long n; The number to be converted to a string
|
|---|
| 66 | *
|
|---|
| 67 | * Convert a number to a string and return a pointer to it.
|
|---|
| 68 | */
|
|---|
| 69 | # undef PUBLIC
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.