[BACK]Return to screen.h CVS log [TXT][DIR] Up to [local] / src / usr.bin / top

Annotation of src/usr.bin/top/screen.h, Revision 1.4

1.4     ! deraadt     1: /*     $OpenBSD: screen.h,v 1.3 2002/02/16 21:27:55 millert Exp $      */
        !             2:
        !             3: /*
        !             4:  *  Top users/processes display for Unix
        !             5:  *  Version 3
        !             6:  *
        !             7:  * Copyright (c) 1984, 1989, William LeFebvre, Rice University
        !             8:  * Copyright (c) 1989, 1990, 1992, William LeFebvre, Northwestern University
        !             9:  *
        !            10:  * Redistribution and use in source and binary forms, with or without
        !            11:  * modification, are permitted provided that the following conditions
        !            12:  * are met:
        !            13:  * 1. Redistributions of source code must retain the above copyright
        !            14:  *    notice, this list of conditions and the following disclaimer.
        !            15:  * 2. Redistributions in binary form must reproduce the above copyright
        !            16:  *    notice, this list of conditions and the following disclaimer in the
        !            17:  *    documentation and/or other materials provided with the distribution.
        !            18:  *
        !            19:  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
        !            20:  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
        !            21:  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
        !            22:  * IN NO EVENT SHALL THE AUTHOR OR HIS EMPLOYER BE LIABLE FOR ANY DIRECT, INDIRECT,
        !            23:  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
        !            24:  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
        !            25:  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
        !            26:  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
        !            27:  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
        !            28:  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        !            29:  */
1.1       downsj     30:
                     31: /*
                     32:  *  top - a top users display for Unix 4.2
                     33:  *
                     34:  *  This file contains all the definitions necessary to use the hand-written
                     35:  *  screen package in "screen.c"
                     36:  */
                     37:
                     38: #define TCputs(str)    tputs(str, 1, putstdout)
                     39: #define putcap(str)    (void)((str) != NULL ? TCputs(str) : 0)
                     40: #define Move_to(x, y)  TCputs(tgoto(cursor_motion, x, y))
                     41:
                     42: extern char ch_erase;          /* set to the user's erase character */
                     43: extern char ch_kill;           /* set to the user's kill  character */
                     44: extern char smart_terminal;     /* set if the terminal has sufficient termcap
                     45:                                   capabilities for normal operation */
                     46:
                     47: /* These are some termcap strings for use outside of "screen.c" */
                     48: extern char *cursor_motion;
                     49: extern char *clear_line;
                     50: extern char *clear_to_end;
                     51:
                     52: /* rows and columns on the screen according to termcap */
                     53: extern int  screen_length;
                     54: extern int  screen_width;
                     55:
1.2       downsj     56: /* prototypes from screen.c */
1.3       millert    57: extern void init_termcap(int);
                     58: extern void init_screen(void);
                     59: extern void end_screen(void);
                     60: extern void reinit_screen(void);
                     61: extern void get_screensize(void);
                     62: extern void standout(char *);
                     63: extern void clear(void);
                     64: extern int clear_eol(int);
                     65: extern void go_home(void);
                     66: extern int putstdout(int);