/* * CDDL HEADER START * * The contents of this file are subject to the terms of the * Common Development and Distribution License, Version 1.0 only * (the "License"). You may not use this file except in compliance * with the License. * * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE * or http://www.opensolaris.org/os/licensing. * See the License for the specific language governing permissions * and limitations under the License. * * When distributing Covered Code, include this CDDL HEADER in each * file and include the License file at usr/src/OPENSOLARIS.LICENSE. * If applicable, add the following below this CDDL HEADER, with the * fields enclosed by brackets "[]" replaced with your own identifying * information: Portions Copyright [yyyy] [name of copyright owner] * * CDDL HEADER END */ /* LINTLIBRARY */ /* PROTOLIB1 */ /* * Copyright (c) 1996-1998 by Sun Microsystems, Inc. * All rights reserved. */ #pragma ident "%Z%%M% %I% %E% SMI" #include <curses.h> #include <term.h> /* * lib/libxcurses/src/libc/xcurses routines */ /* * add_wch.c */ int add_wch(const cchar_t *); int mvadd_wch(int, int, const cchar_t *); int mvwadd_wch(WINDOW *, int, int, const cchar_t *); /* * addch.c */ int addch(chtype); int mvaddch(int, int, chtype); int mvwaddch(WINDOW *, int, int, chtype); /* * addchn.c */ int addchnstr(const chtype *, int); int mvaddchnstr(int, int, const chtype *, int); int mvwaddchnstr(WINDOW *, int, int, const chtype *, int); int addchstr(const chtype *); int mvaddchstr(int, int, const chtype *); int mvwaddchstr(WINDOW *, int, int, const chtype *); int waddchstr(WINDOW *, const chtype *); /* * addnstr.c */ int addnstr(const char *, int); int mvaddnstr(int, int, const char *, int); int mvwaddnstr(WINDOW *, int, int, const char *, int); int addstr(const char *); int mvaddstr(int, int, const char *); int mvwaddstr(WINDOW *, int, int, const char *); int waddstr(WINDOW *, const char *); /* * addnws.c */ int addnwstr(const wchar_t *, int); int mvaddnwstr(int, int, const wchar_t *, int); int mvwaddnwstr(WINDOW *, int, int, const wchar_t *, int); int addwstr(const wchar_t *); int mvaddwstr(int, int, const wchar_t *); int mvwaddwstr(WINDOW *, int, int, const wchar_t *); int waddwstr(WINDOW *, const wchar_t *); /* * addwchn.c */ int add_wchnstr(const cchar_t *, int); int mvadd_wchnstr(int, int, const cchar_t *, int); int mvwadd_wchnstr(WINDOW *, int, int, const cchar_t *, int); int add_wchstr(const cchar_t *); int mvadd_wchstr(int, int, const cchar_t *); int mvwadd_wchstr(WINDOW *, int, int, const cchar_t *); int wadd_wchstr(WINDOW *, const cchar_t *); /* * attr_on.c */ int attr_on(attr_t, void *); int attr_off(attr_t, void *); int attr_set(attr_t, short, void *); int color_set(short, void *); int attr_get(attr_t *, short *, void *); int standout(void); int standend(void); /* * attron.c */ int attron(int); int attroff(int); int attrset(int); int COLOR_PAIR(int); int PAIR_NUMBER(int); /* * baudrate.c */ int baudrate(void); /* * beep.c */ int beep(void); int flash(void); /* * bkgd.c */ int bkgd(chtype); int wbkgd(WINDOW *, chtype); /* * bkgdset.c */ void bkgdset(chtype); void wbkgdset(WINDOW *, chtype); chtype getbkgd(WINDOW *); /* * bkgrnd.c */ int bkgrnd(const cchar_t *); /* * bkgrndst.c */ void bkgrndset(const cchar_t *); void wbkgrndset(WINDOW *, const cchar_t *); int getbkgrnd(cchar_t *); int wgetbkgrnd(WINDOW *, cchar_t *); /* * box.c */ int box(WINDOW *, chtype, chtype); /* * box_set.c */ int box_set(WINDOW *, const cchar_t *, const cchar_t *); /* * brdr.c */ int border(chtype, chtype, chtype, chtype, chtype, chtype, chtype, chtype); /* * brdr_st.c */ int border_set(const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *); /* * cbreak.c */ int cbreak(void); int nocbreak(void); int halfdelay(int); int raw(void); int noraw(void); /* * chgat.c */ int chgat(int, attr_t, short, const void *); int mvchgat(int, int, int, attr_t, short, const void *); int mvwchgat(WINDOW *, int, int, int, attr_t, short, const void *); /* * clear.c */ int clear(void); int erase(void); /* * clearok.c */ int clearok(WINDOW *, bool); void immedok(WINDOW *, bool); int leaveok(WINDOW *, bool); int notimeout(WINDOW *, bool); int scrollok(WINDOW *, bool); /* * clrbot.c */ int clrtobot(void); /* * clreol.c */ int clrtoeol(void); /* * color.c */ int start_color(void); int init_color(short, short, short, short); int init_pair(short, short, short); int color_content(short, short *, short *, short *); int pair_content(short, short *, short *); /* * copywin.c */ int copywin(const WINDOW *, WINDOW *, int, int, int, int, int, int, int); /* * curs_set.c */ int curs_set(int); /* * delay.c */ int delay_output(int); /* * delch.c */ int delch(void); int mvdelch(int, int); int mvwdelch(WINDOW *, int, int); /* * deleteln.c */ int deleteln(void); int insertln(void); int insdelln(int); int wdeleteln(WINDOW *); int winsertln(WINDOW *); /* * doupdate.c */ int doupdate(void); void idcok(WINDOW *, bool); int idlok(WINDOW *, bool); /* * dupwin.c */ WINDOW *dupwin(WINDOW *); /* * echo_wch.c */ int echo_wchar(const cchar_t *); int wecho_wchar(WINDOW *, const cchar_t *); /* * echochar.c */ int echochar(chtype); int wechochar(WINDOW *, chtype); /* * endwin.c */ int endwin(void); /* * flushinp.c */ int flushinp(void); /* * get_wch.c */ int get_wch(wint_t *); int mvget_wch(int, int, wint_t *); int mvwget_wch(WINDOW *, int, int, wint_t *); /* * getcchar.c */ int getcchar(const cchar_t *, wchar_t *, attr_t *, short *, void *); /* * getch.c */ int getch(void); int mvgetch(int, int); int mvwgetch(WINDOW *, int, int); /* * getn_ws.c */ int getn_wstr(wint_t *, int); int mvgetn_wstr(int, int, wint_t *, int); int mvwgetn_wstr(WINDOW *, int, int, wint_t *, int); int get_wstr(wint_t *); int mvget_wstr(int, int, wint_t *); int mvwget_wstr(WINDOW *, int, int, wint_t *); int wget_wstr(WINDOW *, wint_t *); /* * getnstr.c */ int getnstr(char *, int); int mvgetnstr(int, int, char *, int); int mvwgetnstr(WINDOW *, int, int, char *, int); int getstr(char *); int mvgetstr(int, int, char *); int mvwgetstr(WINDOW *, int, int, char *); int wgetstr(WINDOW *, char *); /* * getwin.c */ WINDOW *getwin(FILE *); int putwin(WINDOW *, FILE *); /* * has.c */ bool has_colors(void); bool has_ic(void); bool has_il(void); bool can_change_color(void); /* * hln.c */ int hline(chtype, int); int mvhline(int, int, chtype, int); int mvwhline(WINDOW *, int, int, chtype, int); int vline(chtype, int); int mvvline(int, int, chtype, int); int mvwvline(WINDOW *, int, int, chtype, int); /* * hln_st.c */ int hline_set(const cchar_t *, int); int mvhline_set(int, int, const cchar_t *, int); int mvwhline_set(WINDOW *, int, int, const cchar_t *, int); int vline_set(const cchar_t *, int); int mvvline_set(int, int, const cchar_t *, int); int mvwvline_set(WINDOW *, int, int, const cchar_t *, int); /* * in_wch.c */ int in_wch(cchar_t *); int mvin_wch(int, int, cchar_t *); int mvwin_wch(WINDOW *, int, int, cchar_t *); /* * in_wchn.c */ int in_wchnstr(cchar_t *, int); int mvin_wchnstr(int, int, cchar_t *, int); int mvwin_wchnstr(WINDOW *, int, int, cchar_t *, int); int in_wchstr(cchar_t *); int mvin_wchstr(int, int, cchar_t *); int mvwin_wchstr(WINDOW *, int, int, cchar_t *); int win_wchstr(WINDOW *, cchar_t *); /* * inch.c */ chtype inch(void); chtype mvinch(int, int); chtype mvwinch(WINDOW *, int, int); /* * inchn.c */ int inchnstr(chtype *, int); int mvinchnstr(int, int, chtype *, int); int mvwinchnstr(WINDOW *, int, int, chtype *, int); int inchstr(chtype *); int mvinchstr(int, int, chtype *); int mvwinchstr(WINDOW *, int, int, chtype *); int winchstr(WINDOW *, chtype *); /* * initscr.c */ WINDOW *initscr(void); /* * innstr.c */ int innstr(char *, int); int mvinnstr(int, int, char *, int); int mvwinnstr(WINDOW *, int, int, char *, int); int instr(char *); int mvinstr(int, int, char *); int mvwinstr(WINDOW *, int, int, char *); int winstr(WINDOW *, char *); /* * innwstr.c */ int innwstr(wchar_t *, int); int mvinnwstr(int, int, wchar_t *, int); int mvwinnwstr(WINDOW *, int, int, wchar_t *, int); int inwstr(wchar_t *); int mvinwstr(int, int, wchar_t *); int mvwinwstr(WINDOW *, int, int, wchar_t *); int winwstr(WINDOW *, wchar_t *); /* * ins_nws.c */ int ins_nwstr(const wchar_t *, int); int mvins_nwstr(int, int, const wchar_t *, int); int mvwins_nwstr(WINDOW *, int, int, const wchar_t *, int); int ins_wstr(const wchar_t *); int mvins_wstr(int, int, const wchar_t *); int mvwins_wstr(WINDOW *, int, int, const wchar_t *); int wins_wstr(WINDOW *, const wchar_t *); /* * ins_wch.c */ int ins_wch(const cchar_t *); int mvins_wch(int, int, const cchar_t *); int mvwins_wch(WINDOW *, int, int, const cchar_t *); /* * insch.c */ int insch(chtype); int mvinsch(int, int, chtype); int mvwinsch(WINDOW *, int, int, chtype); /* * insnstr.c */ int insnstr(const char *, int); int mvinsnstr(int, int, const char *, int); int mvwinsnstr(WINDOW *, int, int, const char *, int); int insstr(const char *); int mvinsstr(int, int, const char *); int mvwinsstr(WINDOW *, int, int, const char *); int winsstr(WINDOW *, const char *); /* * intrflsh.c */ int intrflush(WINDOW *, bool); /* * isendwin.c */ bool isendwin(void); /* * key_name.c */ char *key_name(wchar_t); /* * keyname.c */ char *keyname(int); /* * keypad.c */ int keypad(WINDOW *, bool); /* * killchar.c */ char erasechar(void); char killchar(void); /* * killwch.c */ int erasewchar(wchar_t *); int killwchar(wchar_t *); /* * longname.c */ char *longname(void); char *termname(void); /* * meta.c */ int meta(WINDOW *, bool); /* * move.c */ int move(int, int); /* * mvcur.c */ int mvcur(int, int, int, int); /* * mvwin.c */ int mvwin(WINDOW *, int, int); int mvderwin(WINDOW *, int, int); /* * napms.c */ int napms(int); /* * newpad.c */ WINDOW *newpad(int, int); WINDOW *subpad(WINDOW *, int, int, int, int); /* * newterm.c */ void filter(void); void tstp(int); int ripoffline(int, int (*)(WINDOW *, int)); SCREEN *newterm(char *, FILE *, FILE *); void delscreen(SCREEN *); SCREEN *set_term(SCREEN *); int typeahead(int); /* * newwin.c */ int delwin(WINDOW *); WINDOW *derwin(WINDOW *, int, int, int, int); WINDOW *newwin(int, int, int, int); WINDOW *subwin(WINDOW *, int, int, int, int); /* * noecho.c */ int echo(void); int noecho(void); /* * nonl.c */ int nl(void); int nonl(void); /* * overlay.c */ int overlay(const WINDOW *, WINDOW *); int overwrite(const WINDOW *, WINDOW *); /* * pecho_wc.c */ int pecho_wchar(WINDOW *, const cchar_t *); /* * pechoch.c */ int pechochar(WINDOW *, chtype); /* * prefresh.c */ int prefresh(WINDOW *, int, int, int, int, int, int); int pnoutrefresh(WINDOW *, int, int, int, int, int, int); /* * printw.c */ int printw(char *, ...); int mvprintw(int, int, char *, ...); int mvwprintw(WINDOW *, int, int, char *, ...); int wprintw(WINDOW *, char *, ...); /* * qiflush.c */ void qiflush(void); void noqiflush(void); /* * redraw.c */ int redrawwin(WINDOW *); /* * refresh.c */ int refresh(void); /* * savetty.c */ int savetty(void); int resetty(void); /* * scanw.c */ int scanw(char *, ...); int mvscanw(int, int, char *, ...); int mvwscanw(WINDOW *, int, int, char *, ...); int wscanw(WINDOW *, char *, ...); /* * scr_dump.c */ int scr_dump(const char *); int scr_restore(const char *); int scr_init(const char *); int scr_set(const char *); /* * scrl.c */ int scroll(WINDOW *); int scrl(int); /* * scrreg.c */ int setscrreg(int, int); /* * setcchar.c */ int setcchar(cchar_t *, const wchar_t *, attr_t, short, const void *); /* * setup.c */ void use_env(bool); int setupterm(char *, int, int *); int del_curterm(TERMINAL *); TERMINAL *set_curterm(TERMINAL *); int restartterm(char *, int, int *); int def_shell_mode(void); int def_prog_mode(void); int reset_shell_mode(void); int reset_prog_mode(void); /* * slk.c */ int slk_init(int); int slk_attron(const chtype); int slk_attroff(const chtype); int slk_attrset(const chtype); int slk_attr_off(const attr_t, void *); int slk_attr_on(const attr_t, void *); int slk_attr_set(const attr_t, short, void *); int slk_color(short); int slk_touch(void); int slk_clear(void); int slk_restore(void); int slk_noutrefresh(void); int slk_refresh(void); char *slk_label(int); int slk_set(int, const char *, int); int slk_wset(int, const wchar_t *, int); int slk_color_set(short); /* * termattr.c */ chtype termattrs(void); attr_t term_attrs(void); /* * tgetent.c */ int tgetent(char *, const char *); /* * tgetflag.c */ int tgetflag(char *); /* * tgetnum.c */ int tgetnum(char *); /* * tgetstr.c */ char *tgetstr(char *, char **); /* * tgoto.c */ char *tgoto(char *, int, int); /* * tigetfla.c */ int tigetflag(char *); /* * tigetnum.c */ int tigetnum(char *); /* * tigetstr.c */ char *tigetstr(char *); /* * timeout.c */ int nodelay(WINDOW *, bool); void timeout(int); /* * touched.c */ bool is_linetouched(WINDOW *, int); bool is_wintouched(WINDOW *); /* * touchwin.c */ int touchwin(WINDOW *); int untouchwin(WINDOW *); int touchline(WINDOW *, int, int); /* * unctrl.c */ char *unctrl(chtype); /* * vid_attr.c */ int vid_attr(attr_t, short, void *); /* * vid_puts.c */ int vid_puts(attr_t, short, void *, int (*)(int)); /* * vidattr.c */ int vidattr(chtype); int vidputs(chtype, int (*)(int)); /* * vw_print.c */ int vw_printw(WINDOW *, char *, __va_list); /* * vw_scanw.c */ int vw_scanw(WINDOW *, char *, __va_list); /* * vwprintw.c */ int vwprintw(WINDOW *, char *, __va_list); /* * vwscanw.c */ int vwscanw(WINDOW *, char *, __va_list); /* * wadd_wch.c */ int wadd_wch(WINDOW *, const cchar_t *); /* * waddch.c */ int waddch(WINDOW *, chtype); /* * waddchn.c */ int waddchnstr(WINDOW *, const chtype *, int); /* * waddnstr.c */ int waddnstr(WINDOW *, const char *, int); /* * waddnws.c */ int waddnwstr(WINDOW *, const wchar_t *, int); /* * waddwchn.c */ int wadd_wchnstr(WINDOW *, const cchar_t *, int); /* * wattr_on.c */ int wattr_on(WINDOW *, attr_t, void *); int wattr_off(WINDOW *, attr_t, void *); int wattr_set(WINDOW *, attr_t, short, void *); int wattr_get(WINDOW *, attr_t *, short *, void *); int wcolor_set(WINDOW *, short, void *); int wstandout(WINDOW *); int wstandend(WINDOW *); /* * wattron.c */ int wattron(WINDOW *, int); int wattroff(WINDOW *, int); int wattrset(WINDOW *, int); /* * wbkgrnd.c */ int wbkgrnd(WINDOW *, const cchar_t *); /* * wbrdr.c */ int wborder(WINDOW *, chtype, chtype, chtype, chtype, chtype, chtype, chtype, chtype); /* * wbrdr_st.c */ int wborder_set(WINDOW *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *, const cchar_t *); /* * wchgat.c */ int wchgat(WINDOW *, int, attr_t, short, const void *); /* * wclear.c */ int wclear(WINDOW *); int werase(WINDOW *); /* * wclrbot.c */ int wclrtobot(WINDOW *); /* * wclreol.c */ int wclrtoeol(WINDOW *); /* * wdelch.c */ int wdelch(WINDOW *); /* * wget_wch.c */ int unget_wch(const wchar_t); int wget_wch(WINDOW *, wint_t *); /* * wgetch.c */ int ungetch(int); int wgetch(WINDOW *); /* * wgetn_ws.c */ int wgetnstr(WINDOW *, char *, int); int wgetn_wstr(WINDOW *, wint_t *, int); /* * whln.c */ int whline(WINDOW *, chtype, int); int wvline(WINDOW *, chtype, int); /* * whln_st.c */ int whline_set(WINDOW *, const cchar_t *, int); int wvline_set(WINDOW *, const cchar_t *, int); /* * win_wch.c */ int win_wch(WINDOW *, cchar_t *); /* * win_wchn.c */ int win_wchnstr(WINDOW *, cchar_t *, int); /* * winch.c */ chtype winch(WINDOW *); /* * winchn.c */ int winchnstr(WINDOW *, chtype *, int); /* * winnstr.c */ int winnstr(WINDOW *, char *, int); /* * winnwstr.c */ int winnwstr(WINDOW *, wchar_t *, int); /* * wins_nws.c */ int wins_nwstr(WINDOW *, const wchar_t *, int); /* * wins_wch.c */ int wins_wch(WINDOW *, const cchar_t *); /* * winsch.c */ int winsch(WINDOW *, chtype); /* * winsdel.c */ int winsdelln(WINDOW *, int); /* * winsnstr.c */ int winsnstr(WINDOW *, const char *, int); /* * wmove.c */ int wmove(WINDOW *, int, int); /* * wredraw.c */ int wredrawln(WINDOW *, int, int); /* * wrefresh.c */ int wrefresh(WINDOW *); int wnoutrefresh(WINDOW *); /* * wscrl.c */ int wscrl(WINDOW *, int); /* * wscrreg.c */ int wsetscrreg(WINDOW *, int, int); /* * wsyncdn.c */ void wsyncdown(WINDOW *); /* * wsyncup.c */ int syncok(WINDOW *, bool); void wsyncup(WINDOW *); void wcursyncup(WINDOW *); /* * wtimeout.c */ void wtimeout(WINDOW *, int); /* * wtouchln.c */ int wtouchln(WINDOW *, int, int, int); /* * wunctrl.c */ wchar_t *wunctrl(cchar_t *);