curses.h File Reference

MuCurses header file. More...

#include <stdint.h>
#include <stdarg.h>
#include <gpxe/keys.h>

Go to the source code of this file.

Data Structures

struct  _curses_screen
 Curses SCREEN object. More...
struct  _curses_window
 Curses Window struct. More...

Defines

#define ERR   (-1)
#define FALSE   (0)
#define OK   (0)
#define TRUE   (1)
#define stdscr   ( &_stdscr )
#define COLS   _COLS
#define LINES   _LINES
#define MUCURSES_BITS(mask, shift)   (( mask ) << (shift))
#define CPAIR_SHIFT   8
#define ATTRS_SHIFT   16
#define WA_DEFAULT   ( 0x0000 << ATTRS_SHIFT )
#define WA_ALTCHARSET   ( 0x0001 << ATTRS_SHIFT )
#define WA_BLINK   ( 0x0002 << ATTRS_SHIFT )
#define WA_BOLD   ( 0x0004 << ATTRS_SHIFT )
#define WA_DIM   ( 0x0008 << ATTRS_SHIFT )
#define WA_INVIS   ( 0x0010 << ATTRS_SHIFT )
#define WA_PROTECT   ( 0x0020 << ATTRS_SHIFT )
#define WA_REVERSE   ( 0x0040 << ATTRS_SHIFT )
#define WA_STANDOUT   ( 0x0080 << ATTRS_SHIFT )
#define WA_UNDERLINE   ( 0x0100 << ATTRS_SHIFT )
#define WA_HORIZONTAL   ( 0x0200 << ATTRS_SHIFT )
#define WA_VERTICAL   ( 0x0400 << ATTRS_SHIFT )
#define WA_LEFT   ( 0x0800 << ATTRS_SHIFT )
#define WA_RIGHT   ( 0x1000 << ATTRS_SHIFT )
#define WA_LOW   ( 0x2000 << ATTRS_SHIFT )
#define WA_TOP   ( 0x4000 << ATTRS_SHIFT )
#define A_DEFAULT   WA_DEFAULT
#define A_ALTCHARSET   WA_ALTCHARSET
#define A_BLINK   WA_BLINK
#define A_BOLD   WA_BOLD
#define A_DIM   WA_DIM
#define A_INVIS   WA_INVIS
#define A_PROTECT   WA_PROTECT
#define A_REVERSE   WA_REVERSE
#define A_STANDOUT   WA_STANDOUT
#define A_UNDERLINE   WA_UNDERLINE
#define A_ATTRIBUTES   ( 0xffff << ATTRS_SHIFT )
#define A_CHARTEXT   ( 0xff )
#define A_COLOUR   ( 0xff << CPAIR_SHIFT )
#define A_COLOR   A_COLOUR
#define COLOUR_PAIR(n)   ( (n) << CPAIR_SHIFT )
#define COLOR_PAIR(n)   COLOUR_PAIR(n)
#define PAIR_NUMBER(attrs)   ( ( (attrs) & A_COLOUR ) >> CPAIR_SHIFT )
#define COLOUR_PAIRS   8
#define COLOR_PAIRS   COLOUR_PAIRS
#define ACS_ULCORNER   '+'
#define ACS_LLCORNER   '+'
#define ACS_URCORNER   '+'
#define ACS_LRCORNER   '+'
#define ACS_RTEE   '+'
#define ACS_LTEE   '+'
#define ACS_BTEE   '+'
#define ACS_TTEE   '+'
#define ACS_HLINE   '-'
#define ACS_VLINE   '|'
#define ACS_PLUS   '+'
#define ACS_S1   '-'
#define ACS_S9   '_'
#define ACS_DIAMOND   '+'
#define ACS_CKBOARD   ':'
#define ACS_DEGREE   '\''
#define ACS_PLMINUS   '#'
#define ACS_BULLET   'o'
#define ACS_LARROW   '<'
#define ACS_RARROW   '>'
#define ACS_DARROW   'v'
#define ACS_UARROW   '^'
#define ACS_BOARD   '#'
#define ACS_LANTERN   '#'
#define ACS_BLOCK   '#'
#define COLOUR_BLACK   0
#define COLOUR_RED   1
#define COLOUR_GREEN   2
#define COLOUR_YELLOW   3
#define COLOUR_BLUE   4
#define COLOUR_MAGENTA   5
#define COLOUR_CYAN   6
#define COLOUR_WHITE   7
#define COLOURS   7
#define COLOUR_FG   30
#define COLOUR_BG   40
#define COLOR_FG   COLOUR_FG
#define COLOR_BG   COLOUR_BG
#define COLOR_BLACK   COLOUR_BLACK
#define COLOR_BLUE   COLOUR_BLUE
#define COLOR_GREEN   COLOUR_GREEN
#define COLOR_CYAN   COLOUR_CYAN
#define COLOR_RED   COLOUR_RED
#define COLOR_MAGENTA   COLOUR_MAGENTA
#define COLOR_YELLOW   COLOUR_YELLOW
#define COLOR_WHITE   COLOUR_WHITE
#define COLORS   COLOURS
#define can_change_color()   can_change_colour()
#define color_content(c, r, g, b)   colour_content( (c), (r), (g), (b) )
#define color_set(cpno, opts)   colour_set( (cpno), (opts) )
#define init_color   ( c, r, g, b ) init_colour ( (c), (r), (g), (b) )
#define slk_color(c)   slk_colour( (c) )
#define start_color()   start_colour()
#define wcolor_set(w, s, v)   wcolour_set((w),(s),(v))
#define mvprintw(y, x, fmt,...)
#define mvwprintw(win, y, x, fmt,...)
#define printw(fmt,...)   wprintw(stdscr,(fmt), ## __VA_ARGS__ )
#define standend()   wstandend( stdscr )
#define standout()   wstandout( stdscr )

Typedefs

typedef int bool
typedef uint32_t chtype
typedef uint32_t attr_t
typedef struct _curses_screen SCREEN
 Curses SCREEN object.
typedef struct _curses_window WINDOW
 Curses Window struct.

Functions

 FILE_LICENCE (GPL2_OR_LATER)
int baudrate (void)
int beep (void)
 Audible signal.
int box (WINDOW *, chtype, chtype) __nonnull
 Draw borders from single-byte characters and renditions around a window.
int cbreak (void)
int colour_content (short, short *, short *, short *) __nonnull
 Identify the RGB components of a given colour value.
int copywin (const WINDOW *, WINDOW *, int, int, int, int, int, int, int)
int curs_set (int)
int def_prog_mode (void)
int def_shell_mode (void)
int delay_output (int)
void delscreen (SCREEN *)
int delwin (WINDOW *) __nonnull
 Delete a window.
WINDOWderwin (WINDOW *, int, int, int, int) __nonnull
 Create a new derived window.
WINDOWdupwin (WINDOW *) __nonnull
 Create a duplicate of the specified window.
int echo (void)
int echochar (const chtype)
int endwin (void)
 Finalise console environment.
char erasechar (void)
void filter (void)
int flash (void)
int flushinp (void)
__pure chtype getbkgd (WINDOW *) __nonnull
 Get the background rendition attributes for a window.
int halfdelay (int)
bool has_ic (void)
bool has_il (void)
void idcok (WINDOW *, bool)
int idlok (WINDOW *, bool)
WINDOWinitscr (void)
 Initialise console environment.
int init_colour (short, short, short, short)
int init_pair (short, short, short)
 Initialise colour pair.
int intrflush (WINDOW *, bool)
bool isendwin (void)
char * keyname (int)
int keypad (WINDOW *, bool)
char killchar (void)
int leaveok (WINDOW *, bool)
char * longname (void)
int meta (WINDOW *, bool)
int mvcur (int, int, int, int)
int mvderwin (WINDOW *, int, int)
int mvwin (WINDOW *, int, int) __nonnull
 Move window origin to specified coordinates.
int napms (int)
WINDOWnewwin (int, int, int, int)
 Create new WINDOW.
int nl (void)
int nocbreak (void)
int nodelay (WINDOW *, bool)
int noecho (void)
int nonl (void)
void noqiflush (void)
int noraw (void)
int notimeout (WINDOW *, bool)
int overlay (const WINDOW *, WINDOW *)
int overwrite (const WINDOW *, WINDOW *)
int pair_content (short, short *, short *) __nonnull
 Get colours of colour pair.
int printw (char *,...)
int putp (const char *)
void qiflush (void)
int raw (void)
int reset_prog_mode (void)
int reset_shell_mode (void)
int resetty (void)
int ripoffline (int, int(*)(WINDOW *, int))
int savetty (void)
SCREENset_term (SCREEN *)
int setupterm (char *, int, int *)
int slk_attr_off (const attr_t, void *)
int slk_attroff (const chtype)
 Turn off soft function key attributes.
int slk_attr_on (const attr_t, void *)
int slk_attron (const chtype)
 Turn on soft function key attributes.
int slk_attr_set (const attr_t, short, void *)
int slk_attrset (const chtype)
 Set soft function key attributes.
int slk_clear (void)
 Clear the soft function key labels from the screen.
int slk_colour (short)
 Set soft label colour pair.
int slk_init (int)
 Initialise the soft function keys.
char * slk_label (int)
 Return the label for the specified soft key.
int slk_noutrefresh (void)
int slk_restore (void)
 Restore soft function key labels to the screen.
int slk_set (int, const char *, int) __nonnull
 Configure specified soft key.
int slk_touch (void)
WINDOWsubwin (WINDOW *, int, int, int, int) __nonnull
 Create a new sub-window.
int syncok (WINDOW *, bool)
chtype termattrs (void)
attr_t term_attrs (void)
char * termname (void)
int tigetflag (char *)
int tigetnum (char *)
char * tigetstr (char *)
void timeout (int)
char * tparm (char *, long, long, long, long, long, long, long, long, long)
int typeahead (int)
void use_env (bool)
int vid_attr (attr_t, short, void *)
int vidattr (chtype)
int vid_puts (attr_t, short, void *, int(*)(int))
int vidputs (chtype, int(*)(int))
int vw_printw (WINDOW *, const char *, va_list) __nonnull
 Print formatted output in a window.
int waddch (WINDOW *, const chtype) __nonnull
 Add a single-byte character and rendition to a window and advance the cursor.
int waddchnstr (WINDOW *, const chtype *, int) __nonnull
 Add string of single-byte characters and renditions to a window.
int waddnstr (WINDOW *, const char *, int) __nonnull
 Add string of single-byte characters to a window.
int wattroff (WINDOW *, int) __nonnull
 Turn off attributes in a window.
int wattron (WINDOW *, int) __nonnull
 Turn on attributes in a window.
int wattrset (WINDOW *, int) __nonnull
 Set attributes in a window.
int wattr_get (WINDOW *, attr_t *, short *, void *) __attribute__((nonnull(1
int int wattr_off (WINDOW *, attr_t, void *) __attribute__((nonnull(1)))
int wattr_on (WINDOW *, attr_t, void *) __attribute__((nonnull(1)))
int wattr_set (WINDOW *, attr_t, short, void *) __attribute__((nonnull(1)))
int wborder (WINDOW *, chtype, chtype, chtype, chtype, chtype, chtype, chtype, chtype) __nonnull
 Draw borders from single-byte characters and renditions around a window.
int wclrtobot (WINDOW *) __nonnull
 Clear a window to the bottom from current cursor position.
int wclrtoeol (WINDOW *) __nonnull
 Clear a window to the end of the current line.
void wcursyncup (WINDOW *)
int wcolour_set (WINDOW *, short, void *) __nonnull
int wdelch (WINDOW *) __nonnull
 Delete character under the cursor in a window.
int wdeleteln (WINDOW *) __nonnull
 Delete line under a window's cursor.
int wechochar (WINDOW *, const chtype)
int werase (WINDOW *) __nonnull
 Completely clear a window.
int wgetch (WINDOW *)
 Pop a character from the FIFO into a window.
int wgetnstr (WINDOW *, char *, int)
 Read at most n characters from the FIFO into a window.
int whline (WINDOW *, chtype, int) __nonnull
 Create a horizontal line in a window.
int wmove (WINDOW *, int, int)
int wprintw (WINDOW *, const char *,...) __nonnull
 Print formatted output to a window.
void wsyncup (WINDOW *)
void wsyncdown (WINDOW *)
void wtimeout (WINDOW *, int)
int wvline (WINDOW *, chtype, int) __nonnull
 Create a vertical line in a window.
static int addch (const chtype ch)
static int addchnstr (const chtype *chstr, int n)
static int addchstr (const chtype *chstr)
static int addnstr (const char *str, int n)
static int addstr (const char *str)
static int attroff (int attrs)
static int attron (int attrs)
static int attrset (int attrs)
static int attr_get (attr_t *attrs, short *pair, void *opts)
static int attr_off (attr_t attrs, void *opts)
static int attr_on (attr_t attrs, void *opts)
static int attr_set (attr_t attrs, short cpair, void *opts)
static void bkgdset (chtype ch)
static int border (chtype ls, chtype rs, chtype ts, chtype bs, chtype tl, chtype tr, chtype bl, chtype br)
static bool can_change_colour (void)
static int clrtobot (void)
static int clrtoeol (void)
static int colour_set (short colour_pair_number, void *opts)
static int delch (void)
static int deleteln (void)
static int erase (void)
static int getch (void)
static int getnstr (char *str, int n)
static int getstr (char *str)
static bool has_colors (void)
static int has_key (int kc __unused)
static int hline (chtype ch, int n)
static int move (int y, int x)
static int mvaddch (int y, int x, const chtype ch)
static int mvaddchnstr (int y, int x, const chtype *chstr, int n)
static int mvaddchstr (int y, int x, const chtype *chstr)
static int mvaddnstr (int y, int x, const char *str, int n)
static int mvaddstr (int y, int x, const char *str)
static int mvdelch (int y, int x)
static int mvgetch (int y, int x)
static int mvgetnstr (int y, int x, char *str, int n)
static int mvgetstr (int y, int x, char *str)
static int mvhline (int y, int x, chtype ch, int n)
static int mvvline (int y, int x, chtype ch, int n)
static int mvwaddch (WINDOW *win, int y, int x, const chtype ch)
static int mvwaddchnstr (WINDOW *win, int y, int x, const chtype *chstr, int n)
static int mvwaddchstr (WINDOW *win, int y, int x, const chtype *chstr)
static int mvwaddnstr (WINDOW *win, int y, int x, const char *str, int n)
static int mvwaddstr (WINDOW *win, int y, int x, const char *str)
static int mvwdelch (WINDOW *win, int y, int x)
static int mvwgetch (WINDOW *win, int y, int x)
static int mvwgetnstr (WINDOW *win, int y, int x, char *str, int n)
static int mvwgetstr (WINDOW *win, int y, int x, char *str)
static int mvwhline (WINDOW *win, int y, int x, chtype ch, int n)
static int mvwvline (WINDOW *win, int y, int x, chtype ch, int n)
static int slk_refresh (void)
static int start_colour (void)
static int vline (chtype ch, int n)
static int vwprintw (WINDOW *win, const char *fmt, va_list varglist)
static int waddchstr (WINDOW *win, const chtype *chstr)
static int waddstr (WINDOW *win, const char *str)
static int wbkgdset (WINDOW *win, chtype ch)
static int wgetstr (WINDOW *win, char *str)
static int wstandend (WINDOW *win)
static int wstandout (WINDOW *win)

Variables

WINDOW _stdscr
unsigned short _COLS
unsigned short _LINES


Detailed Description

MuCurses header file.

Definition in file curses.h.


Define Documentation

#define ERR   (-1)

#define FALSE   (0)

Definition at line 19 of file curses.h.

#define OK   (0)

#define TRUE   (1)

Definition at line 25 of file curses.h.

#define stdscr   ( &_stdscr )

#define COLS   _COLS

#define LINES   _LINES

#define MUCURSES_BITS ( mask,
shift   )     (( mask ) << (shift))

Definition at line 101 of file curses.h.

#define CPAIR_SHIFT   8

Definition at line 102 of file curses.h.

Referenced by slk_attr_set(), and slk_colour().

#define ATTRS_SHIFT   16

Definition at line 103 of file curses.h.

#define WA_DEFAULT   ( 0x0000 << ATTRS_SHIFT )

Definition at line 105 of file curses.h.

#define WA_ALTCHARSET   ( 0x0001 << ATTRS_SHIFT )

Definition at line 106 of file curses.h.

#define WA_BLINK   ( 0x0002 << ATTRS_SHIFT )

Definition at line 107 of file curses.h.

#define WA_BOLD   ( 0x0004 << ATTRS_SHIFT )

Definition at line 108 of file curses.h.

#define WA_DIM   ( 0x0008 << ATTRS_SHIFT )

Definition at line 109 of file curses.h.

#define WA_INVIS   ( 0x0010 << ATTRS_SHIFT )

Definition at line 110 of file curses.h.

#define WA_PROTECT   ( 0x0020 << ATTRS_SHIFT )

Definition at line 111 of file curses.h.

#define WA_REVERSE   ( 0x0040 << ATTRS_SHIFT )

Definition at line 112 of file curses.h.

#define WA_STANDOUT   ( 0x0080 << ATTRS_SHIFT )

Definition at line 113 of file curses.h.

#define WA_UNDERLINE   ( 0x0100 << ATTRS_SHIFT )

Definition at line 114 of file curses.h.

#define WA_HORIZONTAL   ( 0x0200 << ATTRS_SHIFT )

Definition at line 115 of file curses.h.

#define WA_VERTICAL   ( 0x0400 << ATTRS_SHIFT )

Definition at line 116 of file curses.h.

#define WA_LEFT   ( 0x0800 << ATTRS_SHIFT )

Definition at line 117 of file curses.h.

#define WA_RIGHT   ( 0x1000 << ATTRS_SHIFT )

Definition at line 118 of file curses.h.

#define WA_LOW   ( 0x2000 << ATTRS_SHIFT )

Definition at line 119 of file curses.h.

#define WA_TOP   ( 0x4000 << ATTRS_SHIFT )

Definition at line 120 of file curses.h.

#define A_DEFAULT   WA_DEFAULT

Definition at line 122 of file curses.h.

Referenced by slk_init(), and wstandend().

#define A_ALTCHARSET   WA_ALTCHARSET

Definition at line 123 of file curses.h.

#define A_BLINK   WA_BLINK

Definition at line 124 of file curses.h.

#define A_BOLD   WA_BOLD

Definition at line 125 of file curses.h.

Referenced by ansiscr_putc(), draw_info_row(), and draw_title_row().

#define A_DIM   WA_DIM

Definition at line 126 of file curses.h.

#define A_INVIS   WA_INVIS

Definition at line 127 of file curses.h.

#define A_PROTECT   WA_PROTECT

Definition at line 128 of file curses.h.

#define A_REVERSE   WA_REVERSE

Definition at line 129 of file curses.h.

#define A_STANDOUT   WA_STANDOUT

Definition at line 130 of file curses.h.

Referenced by wstandout().

#define A_UNDERLINE   WA_UNDERLINE

Definition at line 131 of file curses.h.

#define A_ATTRIBUTES   ( 0xffff << ATTRS_SHIFT )

#define A_CHARTEXT   ( 0xff )

Definition at line 134 of file curses.h.

Referenced by ansiscr_putc().

#define A_COLOUR   ( 0xff << CPAIR_SHIFT )

Definition at line 135 of file curses.h.

#define A_COLOR   A_COLOUR

Definition at line 136 of file curses.h.

Referenced by ansiscr_putc(), and wattrset().

#define COLOUR_PAIR (  )     ( (n) << CPAIR_SHIFT )

Definition at line 138 of file curses.h.

Referenced by wattr_set(), and wcolour_set().

#define COLOR_PAIR (  )     COLOUR_PAIR(n)

Definition at line 139 of file curses.h.

#define PAIR_NUMBER ( attrs   )     ( ( (attrs) & A_COLOUR ) >> CPAIR_SHIFT )

Definition at line 140 of file curses.h.

Referenced by ansiscr_putc(), and wattr_get().

#define COLOUR_PAIRS   8

Definition at line 142 of file curses.h.

Referenced by init_pair(), pair_content(), and wcolour_set().

#define COLOR_PAIRS   COLOUR_PAIRS

Definition at line 143 of file curses.h.

#define ACS_ULCORNER   '+'

Definition at line 145 of file curses.h.

#define ACS_LLCORNER   '+'

Definition at line 146 of file curses.h.

#define ACS_URCORNER   '+'

Definition at line 147 of file curses.h.

#define ACS_LRCORNER   '+'

Definition at line 148 of file curses.h.

#define ACS_RTEE   '+'

Definition at line 149 of file curses.h.

#define ACS_LTEE   '+'

Definition at line 150 of file curses.h.

#define ACS_BTEE   '+'

Definition at line 151 of file curses.h.

#define ACS_TTEE   '+'

Definition at line 152 of file curses.h.

#define ACS_HLINE   '-'

Definition at line 153 of file curses.h.

#define ACS_VLINE   '|'

Definition at line 154 of file curses.h.

#define ACS_PLUS   '+'

Definition at line 155 of file curses.h.

#define ACS_S1   '-'

Definition at line 156 of file curses.h.

#define ACS_S9   '_'

Definition at line 157 of file curses.h.

#define ACS_DIAMOND   '+'

Definition at line 158 of file curses.h.

#define ACS_CKBOARD   ':'

Definition at line 159 of file curses.h.

#define ACS_DEGREE   '\''

Definition at line 160 of file curses.h.

#define ACS_PLMINUS   '#'

Definition at line 161 of file curses.h.

#define ACS_BULLET   'o'

Definition at line 162 of file curses.h.

#define ACS_LARROW   '<'

Definition at line 163 of file curses.h.

#define ACS_RARROW   '>'

Definition at line 164 of file curses.h.

#define ACS_DARROW   'v'

Definition at line 165 of file curses.h.

#define ACS_UARROW   '^'

Definition at line 166 of file curses.h.

#define ACS_BOARD   '#'

Definition at line 167 of file curses.h.

#define ACS_LANTERN   '#'

Definition at line 168 of file curses.h.

#define ACS_BLOCK   '#'

Definition at line 169 of file curses.h.

#define COLOUR_BLACK   0

Definition at line 171 of file curses.h.

#define COLOUR_RED   1

Definition at line 172 of file curses.h.

Referenced by colour_content().

#define COLOUR_GREEN   2

Definition at line 173 of file curses.h.

Referenced by colour_content().

#define COLOUR_YELLOW   3

Definition at line 174 of file curses.h.

#define COLOUR_BLUE   4

Definition at line 175 of file curses.h.

Referenced by colour_content().

#define COLOUR_MAGENTA   5

Definition at line 176 of file curses.h.

#define COLOUR_CYAN   6

Definition at line 177 of file curses.h.

#define COLOUR_WHITE   7

Definition at line 178 of file curses.h.

#define COLOURS   7

Definition at line 179 of file curses.h.

#define COLOUR_FG   30

Definition at line 181 of file curses.h.

#define COLOUR_BG   40

Definition at line 182 of file curses.h.

#define COLOR_FG   COLOUR_FG

Definition at line 183 of file curses.h.

#define COLOR_BG   COLOUR_BG

Definition at line 184 of file curses.h.

#define COLOR_BLACK   COLOUR_BLACK

Definition at line 186 of file curses.h.

Referenced by login_ui(), pxe_menu_select(), and settings_ui().

#define COLOR_BLUE   COLOUR_BLUE

Definition at line 187 of file curses.h.

Referenced by login_ui(), and settings_ui().

#define COLOR_GREEN   COLOUR_GREEN

Definition at line 188 of file curses.h.

#define COLOR_CYAN   COLOUR_CYAN

Definition at line 189 of file curses.h.

Referenced by settings_ui().

#define COLOR_RED   COLOUR_RED

Definition at line 190 of file curses.h.

Referenced by settings_ui().

#define COLOR_MAGENTA   COLOUR_MAGENTA

Definition at line 191 of file curses.h.

#define COLOR_YELLOW   COLOUR_YELLOW

Definition at line 192 of file curses.h.

#define COLOR_WHITE   COLOUR_WHITE

Definition at line 193 of file curses.h.

Referenced by login_ui(), pxe_menu_select(), and settings_ui().

#define COLORS   COLOURS

Definition at line 194 of file curses.h.

Referenced by slk_attr_set(), and slk_colour().

 
#define can_change_color (  )     can_change_colour()

Definition at line 220 of file curses.h.

#define color_content ( c,
r,
g,
 )     colour_content( (c), (r), (g), (b) )

Definition at line 225 of file curses.h.

#define color_set ( cpno,
opts   )     colour_set( (cpno), (opts) )

#define init_color   ( c, r, g, b ) init_colour ( (c), (r), (g), (b) )

Definition at line 266 of file curses.h.

#define slk_color (  )     slk_colour( (c) )

Definition at line 372 of file curses.h.

 
#define start_color (  )     start_colour()

Definition at line 383 of file curses.h.

Referenced by login_ui(), pxe_menu_select(), and settings_ui().

#define wcolor_set ( w,
s,
 )     wcolour_set((w),(s),(v))

Definition at line 434 of file curses.h.

#define mvprintw ( y,
x,
fmt,
...   ) 

Value:

( wmove(stdscr,(y),(x)) == OK \
          ? wprintw( stdscr,(fmt), ## __VA_ARGS__ ) : ERR )

Definition at line 638 of file curses.h.

Referenced by draw_setting(), endwin(), login_ui(), pxe_menu_draw_item(), and vmsg().

#define mvwprintw ( win,
y,
x,
fmt,
...   ) 

Value:

( wmove((win),(y),(x)) == OK \
          ? wprintw((win),(fmt), ## __VA_ARGS__) : ERR )

Definition at line 697 of file curses.h.

Referenced by draw_editbox().

#define printw ( fmt,
...   )     wprintw(stdscr,(fmt), ## __VA_ARGS__ )

Definition at line 706 of file curses.h.

 
int standend (  )     wstandend( stdscr )

Definition at line 715 of file curses.h.

 
int standout (  )     wstandout( stdscr )

Definition at line 716 of file curses.h.


Typedef Documentation

typedef int bool

Definition at line 27 of file curses.h.

typedef uint32_t chtype

Definition at line 28 of file curses.h.

typedef uint32_t attr_t

Definition at line 29 of file curses.h.

typedef struct _curses_screen SCREEN

Curses SCREEN object.

typedef struct _curses_window WINDOW

Curses Window struct.


Function Documentation

FILE_LICENCE ( GPL2_OR_LATER   ) 

int baudrate ( void   ) 

int beep ( void   ) 

Audible signal.

Return values:
rc return status code

Definition at line 15 of file alert.c.

References OK, and printf().

Referenced by wgetch(), and wgetnstr().

00015                   {
00016         printf("\a");
00017         return OK;
00018 }

int box ( WINDOW win,
chtype  verch,
chtype  horch 
)

Draw borders from single-byte characters and renditions around a window.

Parameters:
*win window to be bordered
verch vertical chtype
horch horizontal chtype
Return values:
rc return status code

Definition at line 20 of file edging.c.

References _curses_window::attrs, and wborder().

00020                                                     {
00021         chtype corner = '+' | win->attrs; /* default corner character */
00022         return wborder( win, verch, verch, horch, horch,
00023                         corner, corner, corner, corner );
00024 }

int cbreak ( void   ) 

int colour_content ( short  colour,
short *  red,
short *  green,
short *  blue 
)

Identify the RGB components of a given colour value.

Parameters:
colour colour value
*red address to store red component
*green address to store green component
*blue address to store blue component
Return values:
rc return status code

Definition at line 23 of file colour.c.

References COLOUR_BLUE, COLOUR_GREEN, COLOUR_RED, and OK.

00023                                                                            {
00024         *red = ( ( colour & COLOUR_RED ) ? 1 : 0 );
00025         *green = ( ( colour & COLOUR_GREEN ) ? 1 : 0 );
00026         *blue = ( ( colour & COLOUR_BLUE ) ? 1 : 0 );
00027         return OK;
00028 }

int copywin ( const WINDOW ,
WINDOW ,
int  ,
int  ,
int  ,
int  ,
int  ,
int  ,
int   
)

int curs_set ( int   ) 

int def_prog_mode ( void   ) 

int def_shell_mode ( void   ) 

int delay_output ( int   ) 

void delscreen ( SCREEN  ) 

int delwin ( WINDOW win  ) 

Delete a window.

Parameters:
*win pointer to window being deleted
Return values:
rc return status code

Definition at line 18 of file windows.c.

References _wputch(), _curses_window::curs_x, _curses_window::curs_y, ERR, free(), NULL, OK, stdscr, wmove(), and WRAP.

00018                            {
00019         if ( win == NULL )
00020                 return ERR;
00021 
00022         /* I think we should blank the region covered by the window -
00023            ncurses doesn't do this, but they have a buffer, so they
00024            may just be deleting from an offscreen context whereas we
00025            are guaranteed to be deleting something onscreen */
00026         wmove( win, 0, 0 );
00027         chtype killch = (chtype)' ';
00028         do {
00029                 _wputch( win, killch, WRAP );
00030         } while ( win->curs_x + win->curs_y );
00031 
00032         free( win );
00033 
00034         wmove ( stdscr, 0, 0 );
00035 
00036         return OK;
00037 }

WINDOW* derwin ( WINDOW parent,
int  nlines,
int  ncols,
int  begin_y,
int  begin_x 
)

Create a new derived window.

Parameters:
parent parent window
nlines window height
ncols window width
begin_y window y origin (relative to parent)
begin_x window x origin (relative to parent)
Return values:
ptr return pointer to child window

Definition at line 49 of file windows.c.

References _curses_window::height, malloc(), NULL, _curses_window::ori_x, _curses_window::ori_y, _curses_window::parent, _curses_window::scr, and _curses_window::width.

00050                                                             {
00051         WINDOW *child;
00052         if ( parent == NULL )
00053                 return NULL;
00054         if ( ( child = malloc( sizeof( WINDOW ) ) ) == NULL )
00055                 return NULL;
00056         if ( ( (unsigned)ncols > parent->width ) || 
00057              ( (unsigned)nlines > parent->height ) )
00058                 return NULL;
00059         child->ori_y = parent->ori_y + begin_y;
00060         child->ori_x = parent->ori_x + begin_x;
00061         child->height = nlines;
00062         child->width = ncols;
00063         child->parent = parent;
00064         child->scr = parent->scr;
00065         return child;
00066 }

WINDOW* dupwin ( WINDOW orig  ) 

Create a duplicate of the specified window.

Parameters:
orig original window
Return values:
ptr pointer to duplicate window

Definition at line 74 of file windows.c.

References _curses_window::attrs, _curses_window::curs_x, _curses_window::curs_y, _curses_window::height, malloc(), NULL, _curses_window::ori_x, _curses_window::ori_y, _curses_window::scr, and _curses_window::width.

00074                                 {
00075         WINDOW *copy;
00076         if ( orig == NULL )
00077                 return NULL;
00078         if ( ( copy = malloc( sizeof( WINDOW ) ) ) == NULL )
00079                 return NULL;
00080         copy->scr = orig->scr;
00081         copy->attrs = orig->attrs;
00082         copy->ori_y = orig->ori_y;
00083         copy->ori_x = orig->ori_x;
00084         copy->curs_y = orig->curs_y;
00085         copy->curs_x = orig->curs_x;
00086         copy->height = orig->height;
00087         copy->width = orig->width;
00088         return copy;
00089 }

int echo ( void   ) 

Definition at line 132 of file kb.c.

References m_echo, OK, and TRUE.

00132                   {
00133         m_echo = TRUE;
00134         return OK;
00135 }

int echochar ( const   chtype  ) 

int endwin ( void   ) 

Finalise console environment.

Definition at line 31 of file wininit.c.

References attrset(), color_set, LINES, mvprintw, NULL, OK, and stdscr.

Referenced by login_ui(), pxe_menu_select(), and settings_ui().

00031                     {
00032         attrset ( 0 );
00033         color_set ( 0, NULL );
00034         mvprintw ( ( LINES - 1 ), 0, "\n" );
00035         stdscr->scr->exit( stdscr->scr );
00036         return OK;
00037 }

char erasechar ( void   ) 

void filter ( void   ) 

int flash ( void   ) 

Referenced by bnx2_init_nvram().

int flushinp ( void   ) 

__pure chtype getbkgd ( WINDOW win  )  [inline]

Get the background rendition attributes for a window.

Parameters:
*win subject window
Return values:
ch chtype rendition representation

Definition at line 17 of file winattrs.c.

References _curses_window::attrs.

00017                                       {
00018         return win->attrs;
00019 }

int halfdelay ( int   ) 

bool has_ic ( void   ) 

bool has_il ( void   ) 

void idcok ( WINDOW ,
bool   
)

int idlok ( WINDOW ,
bool   
)

WINDOW* initscr ( void   ) 

Initialise console environment.

Return values:
*win return pointer to stdscr

Definition at line 17 of file wininit.c.

References COLS, LINES, move(), and stdscr.

Referenced by login_ui(), pxe_menu_select(), and settings_ui().

00017                          {
00018         /* determine console size */
00019         /* initialise screen */
00020         stdscr->scr->init( stdscr->scr );
00021         stdscr->height = LINES;
00022         stdscr->width = COLS;
00023         move ( 0, 0 );
00024         return stdscr;
00025 }

int init_colour ( short  ,
short  ,
short  ,
short   
)

int init_pair ( short  pair,
short  fcol,
short  bcol 
)

Initialise colour pair.

Parameters:
pair colour pair number
fcol foreground colour
bcol background colour

Definition at line 37 of file colour.c.

References colour_pair::bcol, COLOUR_PAIRS, ERR, colour_pair::fcol, and OK.

Referenced by login_ui(), pxe_menu_select(), and settings_ui().

00037                                                      {
00038         struct colour_pair *cpair;
00039 
00040         if ( ( pair < 1 ) || ( pair >= COLOUR_PAIRS ) )
00041                 return ERR;
00042         
00043         cpair = &cpairs[pair];
00044         cpair->fcol = fcol;
00045         cpair->bcol = bcol;
00046         return OK;
00047 }

int intrflush ( WINDOW ,
bool   
)

bool isendwin ( void   ) 

char* keyname ( int   ) 

int keypad ( WINDOW ,
bool   
)

char killchar ( void   ) 

int leaveok ( WINDOW ,
bool   
)

char* longname ( void   ) 

int meta ( WINDOW ,
bool   
)

int mvcur ( int  ,
int  ,
int  ,
int   
)

int mvderwin ( WINDOW ,
int  ,
int   
)

int mvwin ( WINDOW win,
int  y,
int  x 
)

Move window origin to specified coordinates.

Parameters:
*win window to move
y Y position
x X position
Return values:
rc return status code

Definition at line 99 of file windows.c.

References COLS, ERR, _curses_window::height, LINES, NULL, OK, _curses_window::ori_x, _curses_window::ori_y, and _curses_window::width.

00099                                         {
00100         if ( win == NULL )
00101                 return ERR;
00102         if ( ( ( (unsigned)y + win->height ) > LINES ) ||
00103              ( ( (unsigned)x + win->width ) > COLS ) )
00104                 return ERR;
00105 
00106         win->ori_y = y;
00107         win->ori_x = x;
00108 
00109         return OK;
00110 }

int napms ( int   ) 

WINDOW* newwin ( int  nlines,
int  ncols,
int  begin_y,
int  begin_x 
)

Create new WINDOW.

Parameters:
nlines number of lines
ncols number of columns
begin_y column origin
begin_x line origin
Return values:
*win return pointer to new window

Definition at line 121 of file windows.c.

References _curses_window::height, malloc(), NULL, _curses_window::ori_x, _curses_window::ori_y, _curses_window::parent, _curses_window::scr, stdscr, and _curses_window::width.

Referenced by subwin().

00121                                                                    {
00122         WINDOW *win;
00123         if ( ( win = malloc( sizeof(WINDOW) ) ) == NULL )
00124                 return NULL;
00125         if ( ( (unsigned)( begin_y + nlines ) > stdscr->height ) &&
00126              ( (unsigned)( begin_x + ncols ) > stdscr->width ) )
00127                 return NULL;
00128         win->ori_y = begin_y;
00129         win->ori_x = begin_x;
00130         win->height = nlines;
00131         win->width = ncols;
00132         win->scr = stdscr->scr;
00133         win->parent = stdscr;
00134         return win;
00135 }

int nl ( void   ) 

int nocbreak ( void   ) 

int nodelay ( WINDOW ,
bool   
)

int noecho ( void   ) 

Definition at line 140 of file kb.c.

References FALSE, m_echo, and OK.

00140                     {
00141         m_echo = FALSE;
00142         return OK;
00143 }

int nonl ( void   ) 

void noqiflush ( void   ) 

int noraw ( void   ) 

int notimeout ( WINDOW ,
bool   
)

int overlay ( const WINDOW ,
WINDOW  
)

int overwrite ( const WINDOW ,
WINDOW  
)

int pair_content ( short  pair,
short *  fcol,
short *  bcol 
)

Get colours of colour pair.

Parameters:
pair colour pair number
Return values:
fcol foreground colour
bcol background colour

Definition at line 56 of file colour.c.

References colour_pair::bcol, COLOUR_PAIRS, ERR, colour_pair::fcol, and OK.

Referenced by ansiscr_putc().

00056                                                           {
00057         struct colour_pair *cpair;
00058 
00059         if ( ( pair < 0 ) || ( pair >= COLOUR_PAIRS ) )
00060                 return ERR;
00061         
00062         cpair = &cpairs[pair];
00063         *fcol = cpair->fcol;
00064         *bcol = cpair->bcol;
00065         return OK;
00066 }

int printw ( char *  ,
  ... 
)

int putp ( const char *   ) 

void qiflush ( void   ) 

int raw ( void   ) 

Referenced by fetchf_hex(), and parse_uri().

int reset_prog_mode ( void   ) 

int reset_shell_mode ( void   ) 

int resetty ( void   ) 

int ripoffline ( int  ,
int(*)(WINDOW *, int)   
)

int savetty ( void   ) 

SCREEN* set_term ( SCREEN  ) 

int setupterm ( char *  ,
int  ,
int *   
)

int slk_attr_off ( const   attr_t,
void *   
)

int slk_attroff ( const chtype  attrs  ) 

Turn off soft function key attributes.

Parameters:
attrs attribute bit mask
Return values:
rc return status code

Definition at line 125 of file slk.c.

References A_ATTRIBUTES, _softlabelkeys::attrs, ERR, NULL, and OK.

Referenced by slk_attr_off().

00125                                        {
00126         if ( slks == NULL ) 
00127                 return ERR;
00128         slks->attrs &= ~( attrs & A_ATTRIBUTES );
00129         return OK;
00130 }

int slk_attr_on ( const   attr_t,
void *   
)

int slk_attron ( const chtype  attrs  ) 

Turn on soft function key attributes.

Parameters:
attrs attribute bit mask
Return values:
rc return status code

Definition at line 138 of file slk.c.

References A_ATTRIBUTES, _softlabelkeys::attrs, ERR, NULL, and OK.

Referenced by slk_attr_on().

00138                                       {
00139         if ( slks == NULL )
00140                 return ERR;
00141         slks->attrs |= ( attrs & A_ATTRIBUTES );
00142         return OK;
00143 }

int slk_attr_set ( const   attr_t,
short  ,
void *   
)

int slk_attrset ( const chtype  attrs  ) 

Set soft function key attributes.

Parameters:
attrs attribute bit mask
Return values:
rc return status code

Definition at line 151 of file slk.c.

References A_ATTRIBUTES, _softlabelkeys::attrs, ERR, NULL, and OK.

00151                                        {
00152         if ( slks == NULL ) 
00153                 return ERR;
00154         slks->attrs = ( attrs & A_ATTRIBUTES );
00155         return OK;
00156 }

int slk_clear ( void   ) 

Clear the soft function key labels from the screen.

Return values:
rc return status code

Definition at line 206 of file slk.c.

References _enter_slk(), _leave_slk(), ERR, NULL, OK, stdscr, and wclrtoeol().

Referenced by slk_refresh().

00206                        {
00207         if ( slks == NULL )
00208                 return ERR;
00209 
00210         _enter_slk();
00211         wclrtoeol ( stdscr );
00212         _leave_slk();
00213 
00214         return OK;
00215 }

int slk_colour ( short   ) 

Set soft label colour pair.

Definition at line 220 of file slk.c.

References A_ATTRIBUTES, _softlabelkeys::attrs, COLORS, CPAIR_SHIFT, ERR, NULL, and OK.

00220                                             {
00221         if ( slks == NULL ) 
00222                 return ERR;
00223         if ( ( unsigned short )colour_pair_number > COLORS )
00224                 return ERR;
00225 
00226         slks->attrs = ( (unsigned short)colour_pair_number << CPAIR_SHIFT )
00227                 | ( slks->attrs & A_ATTRIBUTES );
00228 
00229         return OK;
00230 }

int slk_init ( int  fmt  ) 

Initialise the soft function keys.

Parameters:
fmt format of keys
Return values:
rc return status code

Definition at line 238 of file slk.c.

References A_DEFAULT, _softlabelkeys::attrs, calloc(), COLS, ERR, _softlabelkeys::fmt, LINES, _softlabelkeys::maj_space_len, _softlabelkeys::max_label_len, MIN_SPACE_SIZE, _softlabelkeys::num_labels, _softlabelkeys::num_spaces, OK, and _softlabelkeys::spaces.

00238                          {
00239         unsigned short nmaj, nmin, nblocks, available_width;
00240 
00241         if ( (unsigned)fmt > 3 ) {
00242                 return ERR;
00243         }
00244 
00245         /* There seems to be no API call to free this data structure... */
00246         if ( ! slks )
00247                 slks = calloc(1,sizeof(*slks));
00248         if ( ! slks )
00249                 return ERR;
00250 
00251         slks->attrs = A_DEFAULT;
00252         slks->fmt = fmt;
00253         switch(fmt) {
00254         case 0:
00255                 nblocks = 8; nmaj = 2; nmin = 5;
00256                 slks->spaces[0] = 2; slks->spaces[1] = 4;
00257                 break;
00258         case 1:
00259                 nblocks = 8; nmaj = 1; nmin = 6;
00260                 slks->spaces[0] = 3;
00261                 break;
00262         case 2:
00263                 // same allocations as format 3
00264         case 3:
00265                 nblocks = 12; nmaj = 2; nmin = 9;
00266                 slks->spaces[0] = 3; slks->spaces[1] = 7;
00267                 break;
00268         default:
00269                 nblocks = 0; nmaj = 0; nmin = 0;
00270                 break;
00271         }
00272 
00273         // determine maximum label length and major space size
00274         available_width = COLS - ( ( MIN_SPACE_SIZE * nmaj ) + nmin );
00275         slks->max_label_len = available_width / nblocks;
00276         slks->maj_space_len = MIN_SPACE_SIZE + 
00277                 ( available_width % nblocks ) / nmaj;
00278         slks->num_spaces = nmaj;
00279         slks->num_labels = nblocks;
00280 
00281         // strip a line from the screen
00282         LINES -= 1;
00283 
00284         return OK;
00285 }

char* slk_label ( int  labnum  ) 

Return the label for the specified soft key.

Parameters:
labnum soft key identifier
Return values:
label return label

Definition at line 293 of file slk.c.

References _softlabelkeys::fkeys, _softlabel::label, and NULL.

00293                                {
00294         if ( slks == NULL ) 
00295                 return NULL;
00296 
00297         return slks->fkeys[labnum].label;
00298 }

int slk_noutrefresh ( void   ) 

int slk_restore ( void   ) 

Restore soft function key labels to the screen.

Return values:
rc return status code

Definition at line 305 of file slk.c.

References _enter_slk(), _leave_slk(), _print_label(), _wputch(), _softlabelkeys::attrs, COLS, ERR, _softlabelkeys::fkeys, _softlabelkeys::maj_space_len, _softlabelkeys::max_label_len, NOWRAP, NULL, _softlabelkeys::num_labels, _softlabelkeys::num_spaces, OK, _softlabelkeys::spaces, and stdscr.

Referenced by slk_refresh().

00305                          {
00306         unsigned int i, j, pos_x,
00307                 *next_space, *last_space;
00308         chtype space_ch;
00309 
00310         if ( slks == NULL )
00311                 return ERR;
00312 
00313         pos_x = 0;
00314 
00315         _enter_slk();
00316 
00317         space_ch = (chtype)' ' | slks->attrs;
00318         next_space = &(slks->spaces[0]);
00319         last_space = &(slks->spaces[slks->num_spaces-1]);
00320 
00321         for ( i = 0; i < slks->num_labels ; i++ ) {
00322                 _print_label( slks->fkeys[i] );
00323                 pos_x += slks->max_label_len;
00324 
00325                 if ( i == *next_space ) {
00326                         for ( j = 0; j < slks->maj_space_len; j++, pos_x++ )
00327                                 _wputch ( stdscr, space_ch, NOWRAP );
00328                         if ( next_space < last_space )
00329                                 next_space++;
00330                 } else {
00331                         if ( pos_x < COLS )
00332                                 _wputch ( stdscr, space_ch, NOWRAP );
00333                         pos_x++;
00334                 }
00335         }
00336 
00337         _leave_slk();
00338 
00339         return OK;
00340 }

int slk_set ( int  labnum,
const char *  label,
int  fmt 
)

Configure specified soft key.

Parameters:
labnum soft label position to configure
*label string to use as soft key label
fmt justification format of label
Return values:
rc return status code

Definition at line 350 of file slk.c.

References ERR, _softlabelkeys::fkeys, _softlabel::fmt, _softlabel::label, NULL, _softlabelkeys::num_labels, OK, and strncpy().

00350                                                        {
00351         if ( slks == NULL ) 
00352                 return ERR;
00353         if ( (unsigned short)labnum >= slks->num_labels )
00354                 return ERR;
00355         if ( (unsigned short)fmt >= 3 )
00356                 return ERR;
00357 
00358         strncpy(slks->fkeys[labnum].label, label,
00359                 sizeof(slks->fkeys[labnum].label));
00360         slks->fkeys[labnum].fmt = fmt;
00361 
00362         return OK;
00363 }

int slk_touch ( void   ) 

WINDOW* subwin ( WINDOW parent,
int  nlines,
int  ncols,
int  begin_y,
int  begin_x 
)

Create a new sub-window.

Parameters:
orig parent window
nlines window height
ncols window width
begin_y window y origin (absolute)
begin_x window x origin (absolute)
Return values:
ptr return pointer to child window

Definition at line 147 of file windows.c.

References malloc(), newwin(), NULL, _curses_window::parent, and _curses_window::scr.

00148                                                             {
00149         WINDOW *child;
00150         if ( parent == NULL )
00151                 return NULL;
00152         if ( ( child = malloc( sizeof( WINDOW ) ) ) == NULL )
00153                 return NULL;
00154         child = newwin( nlines, ncols, begin_y, begin_x );
00155         child->parent = parent;
00156         child->scr = parent->scr;
00157         return child;
00158 }

int syncok ( WINDOW ,
bool   
)

chtype termattrs ( void   ) 

attr_t term_attrs ( void   ) 

char* termname ( void   ) 

int tigetflag ( char *   ) 

int tigetnum ( char *   ) 

char* tigetstr ( char *   ) 

void timeout ( int   ) 

char* tparm ( char *  ,
long  ,
long  ,
long  ,
long  ,
long  ,
long  ,
long  ,
long  ,
long   
)

int typeahead ( int   ) 

void use_env ( bool   ) 

int vid_attr ( attr_t  ,
short  ,
void *   
)

int vidattr ( chtype   ) 

int vid_puts ( attr_t  ,
short  ,
void *  ,
int(*)(int)   
)

int vidputs ( chtype  ,
int(*)(int)   
)

int vw_printw ( WINDOW win,
const char *  fmt,
va_list  varglist 
)

Print formatted output in a window.

Parameters:
*win subject window
*fmt formatted string
varglist argument list
Return values:
rc return status code

Definition at line 61 of file print.c.

References _printw_handler(), printw_context::ctx, printf_context::handler, OK, vcprintf(), and printw_context::win.

Referenced by vwprintw(), and wprintw().

00061                                                                  {
00062         struct printw_context wctx;
00063 
00064         wctx.win = win;
00065         wctx.ctx.handler = _printw_handler;
00066         vcprintf ( &(wctx.ctx), fmt, varglist );
00067         return OK;
00068 }

int waddch ( WINDOW win,
const chtype  ch 
)

Add a single-byte character and rendition to a window and advance the cursor.

Parameters:
*win window to be rendered in
ch character to be added at cursor
Return values:
rc return status code

Definition at line 23 of file print.c.

References _wputch(), OK, and WRAP.

Referenced by addch(), mvaddch(), and mvwaddch().

00023                                             {
00024         _wputch( win, ch, WRAP );
00025         return OK;
00026 }

int waddchnstr ( WINDOW win,
const chtype chstr,
int  n 
)

Add string of single-byte characters and renditions to a window.

Parameters:
*win window to be rendered in
*chstr pointer to first chtype in "string"
n max number of chars from chstr to render
Return values:
rc return status code

Definition at line 19 of file print_nadv.c.

References _restore_curs_pos(), _store_curs_pos(), _wputchstr(), NOWRAP, and OK.

Referenced by addchnstr(), addchstr(), mvaddchnstr(), mvaddchstr(), mvwaddchnstr(), mvwaddchstr(), and waddchstr().

00019                                                            {
00020         struct cursor_pos pos;  
00021 
00022         _store_curs_pos( win, &pos );
00023         _wputchstr( win, chstr, NOWRAP, n );
00024         _restore_curs_pos( win, &pos );
00025         return OK;
00026 }

int waddnstr ( WINDOW win,
const char *  str,
int  n 
)

Add string of single-byte characters to a window.

Parameters:
*win window to be rendered in
*str standard c-style string
n max number of chars from string to render
Return values:
rc return status code

Definition at line 36 of file print.c.

References _wputstr(), OK, and WRAP.

Referenced by addnstr(), addstr(), mvaddnstr(), mvaddstr(), mvwaddnstr(), mvwaddstr(), and waddstr().

00036                                                      {
00037         _wputstr( win, str, WRAP, n );
00038         return OK;
00039 }

int wattroff ( WINDOW win,
int  attrs 
)

Turn off attributes in a window.

Parameters:
win subject window
attrs attributes to enable
Return values:
rc return status code

Definition at line 28 of file winattrs.c.

References _curses_window::attrs, and OK.

Referenced by attroff(), and wattr_off().

00028                                         {
00029         win->attrs &= ~attrs;
00030         return OK;
00031 }

int wattron ( WINDOW win,
int  attrs 
)

Turn on attributes in a window.

Parameters:
win subject window
attrs attributes to enable
Return values:
rc return status code

Definition at line 40 of file winattrs.c.

References _curses_window::attrs, and OK.

Referenced by attron(), and wattr_on().

00040                                        {
00041         win->attrs |= attrs;
00042         return OK;
00043 }

int wattrset ( WINDOW win,
int  attrs 
)

Set attributes in a window.

Parameters:
win subject window
attrs attributes to enable
Return values:
rc return status code

Definition at line 52 of file winattrs.c.

References A_COLOR, _curses_window::attrs, and OK.

Referenced by _enter_slk(), attrset(), bkgdset(), wattr_set(), wbkgdset(), wstandend(), and wstandout().

00052                                         {
00053         win->attrs = ( attrs | ( win->attrs & A_COLOR ) );
00054         return OK;
00055 }

int wattr_get ( WINDOW ,
attr_t ,
short *  ,
void *   
)

int int wattr_off ( WINDOW ,
attr_t  ,
void *   
)

int wattr_on ( WINDOW ,
attr_t  ,
void *   
)

int wattr_set ( WINDOW ,
attr_t  ,
short  ,
void *   
)

int wborder ( WINDOW win,
chtype  ls,
chtype  rs,
chtype  ts,
chtype  bs,
chtype  tl,
chtype  tr,
chtype  bl,
chtype  br 
)

Draw borders from single-byte characters and renditions around a window.

Parameters:
*win window to be bordered
ls left side
rs right side
ts top
bs bottom
tl top left corner
tr top right corner
bl bottom left corner
br bottom right corner
Return values:
rc return status code

Definition at line 41 of file edging.c.

References _restore_curs_pos(), _store_curs_pos(), _wputch(), _curses_window::curs_x, _curses_window::curs_y, _curses_window::height, NOWRAP, OK, _curses_window::width, wmove(), and WRAP.

Referenced by border(), and box().

00043                                                 {
00044         struct cursor_pos pos;
00045 
00046         _store_curs_pos( win, &pos );
00047         wmove(win,0,0);
00048 
00049         _wputch(win,tl,WRAP);
00050         while ( ( win->width - 1 ) - win->curs_x ) {
00051                 _wputch(win,ts,WRAP);
00052         }
00053         _wputch(win,tr,WRAP);
00054 
00055         while ( ( win->height - 1 ) - win->curs_y ) {
00056                 _wputch(win,ls,WRAP);
00057                 wmove(win,win->curs_y,(win->width)-1);
00058                 _wputch(win,rs,WRAP);
00059         }
00060 
00061         _wputch(win,bl,WRAP);
00062         while ( ( win->width -1 ) - win->curs_x ) {
00063                 _wputch(win,bs,WRAP);
00064         }
00065         _wputch(win,br,NOWRAP); /* do not wrap last char to leave
00066                                    cursor in last position */
00067         _restore_curs_pos( win, &pos );
00068 
00069         return OK;
00070 }

int wclrtobot ( WINDOW win  ) 

Clear a window to the bottom from current cursor position.

Parameters:
*win subject window
Return values:
rc return status code

Definition at line 19 of file clear.c.

References _restore_curs_pos(), _store_curs_pos(), _wputc(), _curses_window::curs_x, _curses_window::curs_y, OK, and WRAP.

Referenced by clrtobot(), and werase().

00019                               {
00020         struct cursor_pos pos;
00021 
00022         _store_curs_pos( win, &pos );
00023         do {
00024                 _wputc( win, ' ', WRAP );
00025         } while ( win->curs_y + win->curs_x );
00026         _restore_curs_pos( win, &pos );
00027 
00028         return OK;
00029 }

int wclrtoeol ( WINDOW win  ) 

Clear a window to the end of the current line.

Parameters:
*win subject window
Return values:
rc return status code

Definition at line 37 of file clear.c.

References _restore_curs_pos(), _store_curs_pos(), _wputc(), _curses_window::curs_y, OK, WRAP, and cursor_pos::y.

Referenced by clrtoeol(), slk_clear(), and wdeleteln().

00037                               {
00038         struct cursor_pos pos;
00039 
00040         _store_curs_pos( win, &pos );
00041         while ( ( win->curs_y - pos.y ) == 0 ) {
00042                 _wputc( win, ' ', WRAP );
00043         }
00044         _restore_curs_pos( win, &pos );
00045 
00046         return OK;
00047 }

void wcursyncup ( WINDOW  ) 

int wcolour_set ( WINDOW ,
short  ,
void *   
)

int wdelch ( WINDOW win  ) 

Delete character under the cursor in a window.

Parameters:
*win subject window
Return values:
rc return status code

Definition at line 55 of file clear.c.

References _wcursback(), _wputc(), NOWRAP, and OK.

Referenced by delch(), mvdelch(), mvwdelch(), wgetch(), and wgetnstr().

00055                            {
00056         _wputc( win, ' ', NOWRAP );
00057         _wcursback( win );
00058 
00059         return OK;
00060 }

int wdeleteln ( WINDOW win  ) 

Delete line under a window's cursor.

Parameters:
*win subject window
Return values:
rc return status code

Definition at line 68 of file clear.c.

References _restore_curs_pos(), _store_curs_pos(), _curses_window::curs_y, OK, wclrtoeol(), and wmove().

Referenced by deleteln().

00068                               {
00069         struct cursor_pos pos;
00070 
00071         _store_curs_pos( win, &pos );
00072         /* let's just set the cursor to the beginning of the line and
00073            let wclrtoeol do the work :) */
00074         wmove( win, win->curs_y, 0 );
00075         wclrtoeol( win );
00076         _restore_curs_pos( win, &pos );
00077         return OK;
00078 }

int wechochar ( WINDOW ,
const   chtype 
)

int werase ( WINDOW win  ) 

Completely clear a window.

Parameters:
*win subject window
Return values:
rc return status code

Definition at line 86 of file clear.c.

References OK, wclrtobot(), and wmove().

Referenced by erase().

00086                            {
00087         wmove( win, 0, 0 );
00088         wclrtobot( win );
00089         return OK;
00090 }

int wgetch ( WINDOW win  ) 

Pop a character from the FIFO into a window.

Parameters:
*win window in which to echo input
Return values:
c char from input stream

Definition at line 53 of file kb.c.

References _wcursback(), _wgetc(), _wputch(), _curses_window::attrs, beep(), KEY_BACKSPACE, KEY_LEFT, KEY_MIN, m_echo, wdelch(), and WRAP.

Referenced by getch(), mvgetch(), and mvwgetch().

00053                            {
00054         int c;
00055 
00056         c = _wgetc( win );
00057 
00058         if ( m_echo ) {
00059                 if ( c >= KEY_MIN ) {
00060                         switch(c) {
00061                         case KEY_LEFT :
00062                         case KEY_BACKSPACE :
00063                                 _wcursback( win );
00064                                 wdelch( win );
00065                                 break;
00066                         default :
00067                                 beep();
00068                                 break;
00069                         }
00070                 } else {
00071                         _wputch( win, (chtype)( c | win->attrs ), WRAP );
00072                 }
00073         }
00074 
00075         return c;
00076 }

int wgetnstr ( WINDOW win,
char *  str,
int  n 
)

Read at most n characters from the FIFO into a window.

Parameters:
*win window in which to echo input
*str pointer to string in which to store result
n maximum number of characters to read into string (inc. NUL)
Return values:
rc return status code

Definition at line 86 of file kb.c.

References _wcursback(), _wgetc(), beep(), ERR, KEY_BACKSPACE, KEY_ENTER, KEY_LEFT, KEY_MIN, OK, and wdelch().

Referenced by getnstr(), getstr(), mvgetnstr(), mvgetstr(), mvwgetnstr(), mvwgetstr(), and wgetstr().

00086                                                {
00087         char *_str;
00088         int c;
00089 
00090         if ( n == 0 ) {
00091                 str = '\0';
00092                 return OK;
00093         }
00094 
00095         _str = str;
00096 
00097         while ( ( c = _wgetc( win ) ) != ERR ) {
00098                 /* termination enforcement - don't let us go past the
00099                    end of the allocated buffer... */
00100                 if ( n == 0 && ( c >= 32 && c <= 126 ) ) {
00101                         _wcursback( win );
00102                         wdelch( win );
00103                 } else {
00104                         if ( c >= KEY_MIN ) {
00105                                 switch(c) {
00106                                 case KEY_LEFT :
00107                                 case KEY_BACKSPACE :
00108                                         _wcursback( win );
00109                                         wdelch( win );
00110                                         break;
00111                                 case KEY_ENTER :
00112                                         *_str = '\0';
00113                                         return OK;
00114                                 default :
00115                                         beep();
00116                                         break;
00117                                 }
00118                         }
00119                         if ( c >= 32 && c <= 126 ) {
00120                                 *(_str++) = c; n--;
00121                         }
00122                 }
00123         }
00124 
00125         return ERR;
00126 }

int whline ( WINDOW win,
chtype  ch,
int  n 
)

Create a horizontal line in a window.

Parameters:
*win subject window
ch rendition and character
n max number of chars (wide) to render
Return values:
rc return status code

Definition at line 80 of file edging.c.

References _restore_curs_pos(), _store_curs_pos(), _wputch(), _curses_window::curs_x, NOWRAP, OK, and _curses_window::width.

Referenced by hline(), mvhline(), and mvwhline().

00080                                              {
00081         struct cursor_pos pos;
00082 
00083         _store_curs_pos ( win, &pos );
00084         while ( ( win->curs_x - win->width ) && n-- ) {
00085                 _wputch ( win, ch, NOWRAP );
00086         }
00087         _restore_curs_pos ( win, &pos );
00088 
00089         return OK;
00090 }

int wmove ( WINDOW ,
int  ,
int   
)

int wprintw ( WINDOW win,
const char *  fmt,
  ... 
)

Print formatted output to a window.

Parameters:
*win subject window
*fmt formatted string
... string arguments
Return values:
rc return status code

Definition at line 78 of file print.c.

References va_end, va_start, and vw_printw().

00078                                                   {
00079         va_list args;
00080         int i;
00081 
00082         va_start ( args, fmt );
00083         i = vw_printw ( win, fmt, args );
00084         va_end ( args );
00085         return i;
00086 }

void wsyncup ( WINDOW  ) 

void wsyncdown ( WINDOW  ) 

void wtimeout ( WINDOW ,
int   
)

int wvline ( WINDOW win,
chtype  ch,
int  n 
)

Create a vertical line in a window.

Parameters:
*win subject window
ch rendition and character
n max number of chars (high) to render
Return values:
rc return status code

Definition at line 100 of file edging.c.

References _restore_curs_pos(), _store_curs_pos(), _wputch(), _curses_window::curs_y, _curses_window::height, NOWRAP, OK, wmove(), and cursor_pos::x.

Referenced by mvvline(), mvwvline(), and vline().

00100                                              {
00101         struct cursor_pos pos;
00102 
00103         _store_curs_pos ( win, &pos );
00104         while ( ( win->curs_y - win->height ) && n-- ) {
00105                 _wputch ( win, ch, NOWRAP );
00106                 wmove( win, ++(win->curs_y), pos.x);
00107         }
00108         _restore_curs_pos ( win, &pos );
00109 
00110         return OK;
00111 }

static int addch ( const chtype  ch  )  [inline, static]

Definition at line 474 of file curses.h.

References stdscr, and waddch().

00474                                             {
00475         return waddch( stdscr, ch );
00476 }

static int addchnstr ( const chtype chstr,
int  n 
) [inline, static]

Definition at line 478 of file curses.h.

References stdscr, and waddchnstr().

00478                                                            {
00479         return waddchnstr ( stdscr, chstr, n );
00480 }

static int addchstr ( const chtype chstr  )  [inline, static]

Definition at line 482 of file curses.h.

References stdscr, and waddchnstr().

00482                                                    {
00483         return waddchnstr ( stdscr, chstr, -1 );
00484 }

static int addnstr ( const char *  str,
int  n 
) [inline, static]

Definition at line 486 of file curses.h.

References stdscr, and waddnstr().

00486                                                      {
00487         return waddnstr ( stdscr, str, n );
00488 }

static int addstr ( const char *  str  )  [inline, static]

Definition at line 490 of file curses.h.

References stdscr, and waddnstr().

00490                                              {
00491         return waddnstr ( stdscr, str, -1 );
00492 }

static int attroff ( int  attrs  )  [inline, static]

Definition at line 494 of file curses.h.

References stdscr, and wattroff().

Referenced by draw_info_row(), and draw_title_row().

00494                                         {
00495         return wattroff ( stdscr, attrs );
00496 }

static int attron ( int  attrs  )  [inline, static]

Definition at line 498 of file curses.h.

References stdscr, and wattron().

Referenced by draw_info_row(), and draw_title_row().

00498                                        {
00499         return wattron ( stdscr, attrs );
00500 }

static int attrset ( int  attrs  )  [inline, static]

Definition at line 502 of file curses.h.

References stdscr, and wattrset().

Referenced by endwin().

00502                                         {
00503         return wattrset ( stdscr, attrs );
00504 }

static int attr_get ( attr_t attrs,
short *  pair,
void *  opts 
) [inline, static]

Definition at line 506 of file curses.h.

References stdscr, and wattr_get().

00506                                                                       {
00507         return wattr_get ( stdscr, attrs, pair, opts );
00508 }

static int attr_off ( attr_t  attrs,
void *  opts 
) [inline, static]

Definition at line 510 of file curses.h.

References stdscr, and wattr_off().

00510                                                         {
00511         return wattr_off ( stdscr, attrs, opts );
00512 }

static int attr_on ( attr_t  attrs,
void *  opts 
) [inline, static]

Definition at line 514 of file curses.h.

References stdscr, and wattr_on().

00514                                                        {
00515         return wattr_on ( stdscr, attrs, opts );
00516 }

static int attr_set ( attr_t  attrs,
short  cpair,
void *  opts 
) [inline, static]

Definition at line 518 of file curses.h.

References stdscr, and wattr_set().

00518                                                                      {
00519         return wattr_set ( stdscr, attrs, cpair, opts );
00520 }

static void bkgdset ( chtype  ch  )  [inline, static]

Definition at line 522 of file curses.h.

References stdscr, and wattrset().

00522                                          {
00523         wattrset ( stdscr, ch );
00524 }

static int border ( chtype  ls,
chtype  rs,
chtype  ts,
chtype  bs,
chtype  tl,
chtype  tr,
chtype  bl,
chtype  br 
) [inline, static]

Definition at line 526 of file curses.h.

References stdscr, and wborder().

00527                                                                         {
00528         return wborder ( stdscr, ls, rs, ts, bs, tl, tr, bl, br );
00529 }

static bool can_change_colour ( void   )  [inline, static]

Definition at line 531 of file curses.h.

References FALSE.

00531                                               {
00532         return FALSE;
00533 }

static int clrtobot ( void   )  [inline, static]

Definition at line 535 of file curses.h.

References stdscr, and wclrtobot().

00535                                     {
00536         return wclrtobot( stdscr );
00537 }

static int clrtoeol ( void   )  [inline, static]

Definition at line 539 of file curses.h.

References stdscr, and wclrtoeol().

Referenced by clearmsg().

00539                                     {
00540         return wclrtoeol( stdscr );
00541 }

static int colour_set ( short  colour_pair_number,
void *  opts 
) [inline, static]

Definition at line 543 of file curses.h.

References stdscr, and wcolour_set().

00543                                                                       {
00544         return wcolour_set ( stdscr, colour_pair_number, opts );
00545 }

static int delch ( void   )  [inline, static]

Definition at line 547 of file curses.h.

References stdscr, and wdelch().

00547                                  {
00548         return wdelch ( stdscr );
00549 }

static int deleteln ( void   )  [inline, static]

Definition at line 551 of file curses.h.

References stdscr, and wdeleteln().

00551                                     {
00552         return wdeleteln( stdscr );
00553 }

static int erase ( void   )  [inline, static]

Definition at line 555 of file curses.h.

References stdscr, and werase().

Referenced by login_ui(), and settings_ui().

00555                                  {
00556         return werase ( stdscr );
00557 }

static int getch ( void   )  [inline, static]

Definition at line 559 of file curses.h.

References stdscr, and wgetch().

00559                                  {
00560         return wgetch ( stdscr );
00561 }

static int getnstr ( char *  str,
int  n 
) [inline, static]

Definition at line 563 of file curses.h.

References stdscr, and wgetnstr().

00563                                                {
00564         return wgetnstr ( stdscr, str, n );
00565 }

static int getstr ( char *  str  )  [inline, static]

Definition at line 567 of file curses.h.

References stdscr, and wgetnstr().

00567                                        {
00568         return wgetnstr ( stdscr, str, -1 );
00569 }

static bool has_colors ( void   )  [inline, static]

Definition at line 571 of file curses.h.

References TRUE.

00571                                        {
00572         return TRUE;
00573 }

static int has_key ( int kc  __unused  )  [inline, static]

Definition at line 575 of file curses.h.

References TRUE.

00575                                               {
00576         return TRUE;
00577 }

static int hline ( chtype  ch,
int  n 
) [inline, static]

Definition at line 579 of file curses.h.

References stdscr, and whline().

00579                                              {
00580         return whline ( stdscr, ch, n );
00581 }

static int move ( int  y,
int  x 
) [inline, static]

Definition at line 583 of file curses.h.

References stdscr, and wmove().

Referenced by clearmsg(), draw_setting(), initscr(), and pxe_menu_draw_item().

00583                                         {
00584         return wmove ( stdscr, y, x );
00585 }

static int mvaddch ( int  y,
int  x,
const chtype  ch 
) [inline, static]

Definition at line 587 of file curses.h.

References ERR, OK, stdscr, waddch(), and wmove().

00587                                                             {
00588         return ( wmove ( stdscr, y, x ) == OK
00589                  ? waddch( stdscr, ch ) : ERR );
00590 }

static int mvaddchnstr ( int  y,
int  x,
const chtype chstr,
int  n 
) [inline, static]

Definition at line 592 of file curses.h.

References ERR, OK, stdscr, waddchnstr(), and wmove().

00592                                                                            {
00593         return ( wmove ( stdscr, y, x ) == OK
00594                  ? waddchnstr ( stdscr, chstr, n ) : ERR );
00595 }

static int mvaddchstr ( int  y,
int  x,
const chtype chstr 
) [inline, static]

Definition at line 597 of file curses.h.

References ERR, OK, stdscr, waddchnstr(), and wmove().

00597                                                                    {
00598         return ( wmove ( stdscr, y, x ) == OK
00599                  ? waddchnstr ( stdscr, chstr, -1 ) : ERR );
00600 }

static int mvaddnstr ( int  y,
int  x,
const char *  str,
int  n 
) [inline, static]

Definition at line 602 of file curses.h.

References ERR, OK, stdscr, waddnstr(), and wmove().

00602                                                                      {
00603         return ( wmove ( stdscr, y, x ) == OK
00604                  ? waddnstr ( stdscr, str, n ) : ERR );
00605 }

static int mvaddstr ( int  y,
int  x,
const char *  str 
) [inline, static]

Definition at line 607 of file curses.h.

References ERR, OK, stdscr, waddnstr(), and wmove().

00607                                                              {
00608         return ( wmove ( stdscr, y, x ) == OK
00609                  ? waddnstr ( stdscr, str, -1 ) : ERR );
00610 }

static int mvdelch ( int  y,
int  x 
) [inline, static]

Definition at line 612 of file curses.h.

References ERR, OK, stdscr, wdelch(), and wmove().

00612                                            {
00613         return ( wmove ( stdscr, y, x ) == OK
00614                  ? wdelch ( stdscr ) : ERR );
00615 }

static int mvgetch ( int  y,
int  x 
) [inline, static]

Definition at line 617 of file curses.h.

References ERR, OK, stdscr, wgetch(), and wmove().

00617                                            {
00618         return ( wmove ( stdscr, y, x ) == OK
00619                  ? wgetch ( stdscr ) : ERR );
00620 }

static int mvgetnstr ( int  y,
int  x,
char *  str,
int  n 
) [inline, static]

Definition at line 622 of file curses.h.

References ERR, OK, stdscr, wgetnstr(), and wmove().

00622                                                                {
00623         return ( wmove ( stdscr, y, x ) == OK
00624                  ? wgetnstr ( stdscr, str, n ) : ERR );
00625 }

static int mvgetstr ( int  y,
int  x,
char *  str 
) [inline, static]

Definition at line 627 of file curses.h.

References ERR, OK, stdscr, wgetnstr(), and wmove().

00627                                                        {
00628         return ( wmove ( stdscr, y, x ) == OK
00629                  ? wgetnstr ( stdscr, str, -1 ) : ERR );
00630 }

static int mvhline ( int  y,
int  x,
chtype  ch,
int  n 
) [inline, static]

Definition at line 632 of file curses.h.

References ERR, OK, stdscr, whline(), and wmove().

00632                                                              {
00633         return ( wmove ( stdscr, y, x ) == OK
00634                  ? whline ( stdscr, ch, n ) : ERR );
00635 }

static int mvvline ( int  y,
int  x,
chtype  ch,
int  n 
) [inline, static]

Definition at line 642 of file curses.h.

References ERR, OK, stdscr, wmove(), and wvline().

00642                                                              {
00643         return ( wmove ( stdscr, y, x ) == OK
00644                  ? wvline ( stdscr, ch, n ) : ERR );
00645 }

static int mvwaddch ( WINDOW win,
int  y,
int  x,
const chtype  ch 
) [inline, static]

Definition at line 647 of file curses.h.

References ERR, OK, waddch(), and wmove().

00647                                                                           {
00648         return ( wmove( win, y, x ) == OK
00649                  ? waddch ( win, ch ) : ERR );
00650 }

static int mvwaddchnstr ( WINDOW win,
int  y,
int  x,
const chtype chstr,
int  n 
) [inline, static]

Definition at line 652 of file curses.h.

References ERR, OK, waddchnstr(), and wmove().

00652                                                                                          {
00653         return ( wmove ( win, y, x ) == OK
00654                  ? waddchnstr ( win, chstr, n ) : ERR );
00655 }

static int mvwaddchstr ( WINDOW win,
int  y,
int  x,
const chtype chstr 
) [inline, static]

Definition at line 657 of file curses.h.

References ERR, OK, waddchnstr(), and wmove().

00657                                                                                  {
00658         return ( wmove ( win, y, x ) == OK
00659                  ? waddchnstr ( win, chstr, -1 ) : ERR );
00660 }

static int mvwaddnstr ( WINDOW win,
int  y,
int  x,
const char *  str,
int  n 
) [inline, static]

Definition at line 662 of file curses.h.

References ERR, OK, waddnstr(), and wmove().

00662                                                                                    {
00663         return ( wmove ( win, y, x ) == OK
00664                  ? waddnstr ( win, str, n ) : ERR );
00665 }

static int mvwaddstr ( WINDOW win,
int  y,
int  x,
const char *  str 
) [inline, static]

Definition at line 667 of file curses.h.

References ERR, OK, waddnstr(), and wmove().

00667                                                                            {
00668         return ( wmove ( win, y, x ) == OK
00669                  ? waddnstr ( win, str, -1 ) : ERR );
00670 }

static int mvwdelch ( WINDOW win,
int  y,
int  x 
) [inline, static]

Definition at line 672 of file curses.h.

References ERR, OK, wdelch(), and wmove().

00672                                                          {
00673         return ( wmove ( win, y, x ) == OK
00674                  ? wdelch ( win ) : ERR );
00675 }

static int mvwgetch ( WINDOW win,
int  y,
int  x 
) [inline, static]

Definition at line 677 of file curses.h.

References ERR, OK, wgetch(), and wmove().

00677                                                          {
00678         return ( wmove ( win, y, x ) == OK
00679                  ? wgetch ( win ) : ERR );
00680 }

static int mvwgetnstr ( WINDOW win,
int  y,
int  x,
char *  str,
int  n 
) [inline, static]

Definition at line 682 of file curses.h.

References ERR, OK, wgetnstr(), and wmove().

00682                                                                              {
00683         return ( wmove ( win, y, x ) == OK
00684                  ? wgetnstr ( win, str, n ) : ERR );
00685 }

static int mvwgetstr ( WINDOW win,
int  y,
int  x,
char *  str 
) [inline, static]

Definition at line 687 of file curses.h.

References ERR, OK, wgetnstr(), and wmove().

00687                                                                      {
00688         return ( wmove ( win, y, x ) == OK
00689                  ? wgetnstr ( win, str, -1 ) : ERR );
00690 }

static int mvwhline ( WINDOW win,
int  y,
int  x,
chtype  ch,
int  n 
) [inline, static]

Definition at line 692 of file curses.h.

References ERR, OK, whline(), and wmove().

00692                                                                            {
00693         return ( wmove ( win, y, x ) == OK
00694                  ? whline ( win, ch, n ) : ERR );
00695 }

static int mvwvline ( WINDOW win,
int  y,
int  x,
chtype  ch,
int  n 
) [inline, static]

Definition at line 701 of file curses.h.

References ERR, OK, wmove(), and wvline().

00701                                                                            {
00702         return ( wmove ( win, y, x ) == OK
00703                  ? wvline ( win, ch, n ) : ERR );
00704 }

static int slk_refresh ( void   )  [inline, static]

Definition at line 708 of file curses.h.

References ERR, OK, slk_clear(), and slk_restore().

00708                                        {
00709         if ( slk_clear() == OK )
00710                 return slk_restore();
00711         else
00712                 return ERR;
00713 }

static int start_colour ( void   )  [inline, static]

Definition at line 718 of file curses.h.

References OK.

00718                                         {
00719         return OK;
00720 }

static int vline ( chtype  ch,
int  n 
) [inline, static]

Definition at line 722 of file curses.h.

References stdscr, and wvline().

00722                                              {
00723         return wvline ( stdscr, ch, n );
00724 }

static int vwprintw ( WINDOW win,
const char *  fmt,
va_list  varglist 
) [inline, static]

Definition at line 727 of file curses.h.

References vw_printw().

00727                                                                               {
00728         return vw_printw ( win, fmt, varglist );
00729 }

static int waddchstr ( WINDOW win,
const chtype chstr 
) [inline, static]

Definition at line 731 of file curses.h.

References waddchnstr().

00731                                                                  {
00732         return waddchnstr ( win, chstr, -1 );
00733 }

static int waddstr ( WINDOW win,
const char *  str 
) [inline, static]

Definition at line 735 of file curses.h.

References waddnstr().

00735                                                            {
00736         return waddnstr ( win, str, -1 );
00737 }

static int wbkgdset ( WINDOW win,
chtype  ch 
) [inline, static]

Definition at line 739 of file curses.h.

References wattrset().

00739                                                       {
00740         return wattrset( win, ch );
00741 }

static int wgetstr ( WINDOW win,
char *  str 
) [inline, static]

Definition at line 743 of file curses.h.

References wgetnstr().

00743                                                      {
00744         return wgetnstr ( win, str, -1 );
00745 }

static int wstandend ( WINDOW win  )  [inline, static]

Definition at line 747 of file curses.h.

References A_DEFAULT, and wattrset().

00747                                             {
00748         return wattrset ( win, A_DEFAULT );
00749 }

static int wstandout ( WINDOW win  )  [inline, static]

Definition at line 751 of file curses.h.

References A_STANDOUT, and wattrset().

00751                                             {
00752         return wattrset ( win, A_STANDOUT );
00753 }


Variable Documentation

Definition at line 21 of file mucurses.c.

unsigned short _COLS

Definition at line 12 of file ansi_screen.c.

Referenced by ansiscr_putc().

unsigned short _LINES

Definition at line 13 of file ansi_screen.c.


Generated on Tue Apr 6 20:01:47 2010 for gPXE by  doxygen 1.5.7.1