#include <curses.h>
Go to the source code of this file.
Functions | |
| FILE_LICENCE (GPL2_OR_LATER) | |
| chtype | getbkgd (WINDOW *win) |
| Get the background rendition attributes for a window. | |
| int | wattroff (WINDOW *win, int attrs) |
| Turn off attributes in a window. | |
| int | wattron (WINDOW *win, int attrs) |
| Turn on attributes in a window. | |
| int | wattrset (WINDOW *win, int attrs) |
| Set attributes in a window. | |
| int | wattr_get (WINDOW *win, attr_t *attrs, short *pair, void *opts __unused) |
| Get attributes and colour pair information. | |
| int | wattr_off (WINDOW *win, attr_t attrs, void *opts __unused) |
| Turn off attributes in a window. | |
| int | wattr_on (WINDOW *win, attr_t attrs, void *opts __unused) |
| Turn on attributes in a window. | |
| int | wattr_set (WINDOW *win, attr_t attrs, short cpair, void *opts __unused) |
| Set attributes and colour pair information in a window. | |
| int | wcolour_set (WINDOW *win, short colour_pair_number, void *opts __unused) |
| Set colour pair for a window. | |
Definition in file winattrs.c.
| FILE_LICENCE | ( | GPL2_OR_LATER | ) |
Get the background rendition attributes for a window.
| *win | subject window |
| ch | chtype rendition representation |
Definition at line 17 of file winattrs.c.
References _curses_window::attrs.
00017 { 00018 return win->attrs; 00019 }
| int wattroff | ( | WINDOW * | win, | |
| int | attrs | |||
| ) |
Turn off attributes in a window.
| win | subject window | |
| attrs | attributes to enable |
| rc | return status code |
Definition at line 28 of file winattrs.c.
References _curses_window::attrs, and OK.
Referenced by attroff(), and wattr_off().
| int wattron | ( | WINDOW * | win, | |
| int | attrs | |||
| ) |
Turn on attributes in a window.
| win | subject window | |
| attrs | attributes to enable |
| rc | return status code |
Definition at line 40 of file winattrs.c.
References _curses_window::attrs, and OK.
Referenced by attron(), and wattr_on().
| int wattrset | ( | WINDOW * | win, | |
| int | attrs | |||
| ) |
Set attributes in a window.
| win | subject window | |
| attrs | attributes to enable |
| 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().
Get attributes and colour pair information.
| *win | window to obtain information from | |
| *attrs | address in which to store attributes | |
| *pair | address in which to store colour pair | |
| *opts | undefined (for future implementation) |
| rc | return status cude |
Definition at line 66 of file winattrs.c.
References A_ATTRIBUTES, _curses_window::attrs, OK, and PAIR_NUMBER.
Referenced by _enter_slk(), and attr_get().
00067 { 00068 *attrs = win->attrs & A_ATTRIBUTES; 00069 *pair = PAIR_NUMBER ( win->attrs ); 00070 return OK; 00071 }
Turn off attributes in a window.
| *win | subject window | |
| attrs | attributes to toggle | |
| *opts | undefined (for future implementation) |
| rc | return status code |
Definition at line 81 of file winattrs.c.
References OK, and wattroff().
Referenced by attr_off().
Turn on attributes in a window.
| *win | subject window | |
| attrs | attributes to toggle | |
| *opts | undefined (for future implementation) |
| rc | return status code |
Definition at line 95 of file winattrs.c.
Referenced by attr_on().
Set attributes and colour pair information in a window.
| *win | subject window | |
| attrs | attributes to set | |
| cpair | colour pair to set | |
| *opts | undefined (for future implementation) |
| rc | return status code |
Definition at line 110 of file winattrs.c.
References COLOUR_PAIR, OK, and wattrset().
Referenced by _leave_slk(), and attr_set().
00111 { 00112 wattrset( win, attrs | COLOUR_PAIR ( cpair ) ); 00113 return OK; 00114 }
| int wcolour_set | ( | WINDOW * | win, | |
| short | colour_pair_number, | |||
| void *opts | __unused | |||
| ) |
Set colour pair for a window.
| *win | subject window | |
| colour_pair_number | colour pair integer | |
| *opts | undefined (for future implementation) |
| rc | return status code |
Definition at line 124 of file winattrs.c.
References A_ATTRIBUTES, _curses_window::attrs, COLOUR_PAIR, COLOUR_PAIRS, ERR, and OK.
Referenced by colour_set().
00125 { 00126 if ( ( unsigned short )colour_pair_number > COLOUR_PAIRS ) 00127 return ERR; 00128 00129 win->attrs = ( ( win->attrs & A_ATTRIBUTES ) | 00130 COLOUR_PAIR ( colour_pair_number ) ); 00131 return OK; 00132 }
1.5.7.1