X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=doc%2Fhtml%2Fman%2Fcurs_variables.3x.html;h=616d96e0f8cc11a2c6968857f15f45a0c6ede8a3;hp=ed617925dfe01eeb30647559f318b31acf203dff;hb=159cd0555e0efc14be66c9c3a1548f58908b6a1d;hpb=d90067f9008bb8338a77c1ed519bc108c275ed04 diff --git a/doc/html/man/curs_variables.3x.html b/doc/html/man/curs_variables.3x.html index ed617925..616d96e0 100644 --- a/doc/html/man/curs_variables.3x.html +++ b/doc/html/man/curs_variables.3x.html @@ -27,19 +27,20 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_variables.3x,v 1.35 2023/12/16 21:05:52 tom Exp @ + * @Id: curs_variables.3x,v 1.40 2023/12/23 23:10:13 tom Exp @ + * SVID 4, Volume 3, p. 408 -->
-curs_variables(3x) Library calls curs_variables(3x) @@ -47,9 +48,9 @@
- bool, chtype, cchar_t, attr_t, WINDOW, TRUE, FALSE, ERR, OK, COLORS, - COLOR_PAIRS, COLS, ESCDELAY, LINES, TABSIZE, curscr, newscr, stdscr - - curses data types, constants, and global variables + bool, chtype, cchar_t, attr_t, SCREEN, WINDOW, TRUE, FALSE, ERR, OK, + curscr, newscr, stdscr, COLORS, COLOR_PAIRS, COLS, LINES, ESCDELAY, + TABSIZE - curses data types, constants, and global variables
@@ -60,6 +61,7 @@ typedef /* ... */ chtype; typedef /* ... */ cchar_t; typedef /* ... */ attr_t; + typedef /* ... */ SCREEN; typedef /* ... */ WINDOW; /* constants */ @@ -70,12 +72,13 @@ const /* ... */ OK; /* variables */ - int COLOR_PAIRS; int COLORS; + int COLOR_PAIRS; int COLS; int LINES; WINDOW * curscr; WINDOW * stdscr; + /* extensions */ int ESCDELAY; int TABSIZE; @@ -93,11 +96,11 @@ library. -
- X/Open Issue 4 curses (1996) preceded the ISO C99 and ISO C++98 - standards, each of which also defined a Boolean data type. The curses - library requires an integral type bool and constants TRUE and FALSE to - store its two possible values. +
+ +
+ The curses library defines TRUE and FALSE to represent the values of + the Boolean data type.
@@ -105,109 +108,113 @@ values indicating failure and success, respectively. +
+ +
+ X/Open Issue 4 curses (1996) preceded the ISO C99 and ISO C++98 + standards, each of which also defined a Boolean data type. The curses + library requires an integral type bool. + + ncurses' configure script attempts to discover the data type used by + the system's C and C++ compilers, to reuse for the curses bool. + +
- The chtype integral type combines a ("narrow", 8-bit) character with - attributes encoding the character's rendition, such as the styling of + The chtype integral type combines a ("narrow", 8-bit) character with + attributes encoding the character's rendition, such as the styling of its typeface and/or foreground and background colors. See, for example, addch(3x), attron(3x), and inch(3x).
- chtype is too small for the standard C library's wide-character type, - wchar_t. cchar_t is a type that can accommodate an attr_t and enough - wide characters to store what Unicode terms a grapheme cluster (a - "user-perceived character" [UAX #29], which may nevertheless require - several character encoding units to represent). attr_t is an integral - type storing "wide" attributes that apply to cchar_ts. See, for + chtype is too small for the standard C library's wide-character type, + wchar_t. cchar_t is a type that can accommodate an attr_t and enough + wide characters to store what Unicode terms a grapheme cluster (a + "user-perceived character" [UAX #29], which may nevertheless require + several character encoding units to represent). attr_t is an integral + type storing "wide" attributes that apply to cchar_ts. See, for example, add_wch(3x), attr_on(3x), and in_wch(3x). -
- Once curses is initialized, COLOR_PAIRS contains the number of color - pairs supported by the terminal. Often, its value is the product - COLORS x COLORS, but this is not always true. +
+ curses manages a terminal device with this structure type; see + initscr(3x). + - o A few terminals use HLS colors, ignoring this rule; and +
+ curses represents rectangular portions of the terminal screen with the + WINDOW structure type; see subsection "Overview" of ncurses(3x). - o terminals supporting a large number of colors are limited by the - number of color pairs that a signed short value can represent. + +
+ +
+ The library records updates to the terminal screen in a window named + curscr. This object is referred to as the "physical screen" in + curs_refresh(3x) and curs_outopts(3x). + + ncurses collects pending updates to the terminal screen in a window + named newscr. This object is referred to as the "virtual screen" in + the curs_kernel(3x), curs_refresh(3x), and curs_outopts(3x). When the + screen is refreshed, curses determines a minimal set of updates using + the terminal's capabilities to make curscr look like newscr. + + Once curses is initialized, it creates a window named stdscr. It is + the same size as the terminal screen and is the default window used by + routines that do not take a parameter identifying one. Many curses + functions use this window.
- Once curses is initialized, COLORS contains the number of colors - supported by the terminal. + Once curses is initialized, COLORS contains the number of colors + supported by the terminal; see curs_color(3x). -
- Once curses is initialized, COLS contains the screen's width in - character cells; that is, the number of columns. +
+ Once curses is initialized, COLOR_PAIRS contains the number of color + pairs supported by the terminal; see curs_color(3x). + + +
+ Once curses is initialized, COLS and LINES contain the screen's width + and height in character cells, respectively; that is, the number of + columns and lines.
For curses to distinguish an escape character corresponding to a user's - press of an "Escape" key on the input device from one included in a + press of an "Escape" key on the input device from one included in a control sequence used by a cursor movement or function key, the library - waits to see if another key event occurs after the escape character. + waits to see if another key event occurs after the escape character. ESCDELAY stores this interval in milliseconds. -
- Once curses is initialized, LINES contains the screen's height in - character cells; that is, the number of lines. - -
The curses library converts a tab character to this number of spaces as it adds a tab to a window; see curs_addch(3x). -
- curses records updates to the terminal screen in a WINDOW structure - named curscr. - - This object is referred to as the "physical screen" in curs_refresh(3x) - and curs_outopts(3x). - - -
- ncurses collects pending updates to the terminal screen in a WINDOW - structure named newscr. - - This object is referred to as the "virtual screen" in the - curs_kernel(3x), curs_refresh(3x), and curs_outopts(3x). When the - screen is refreshed, curses determines a minimal set of updates using - the terminal's capabilities to make curscr look like newscr. - - -
- Once curses is initialized, it creates a WINDOW structure named stdscr. - It is the same size as the terminal screen and is the default window - used by routines that do not take a parameter identifying one. Many - curses functions use this window. - -
Either initscr(3x) or newterm(3x) initializes curses. - If ncurses is configured to provide separate curses and terminfo + If ncurses is configured to provide separate curses and terminfo libraries, most of these variables reside in the curses library.
- The X/Open Curses standard documents all of the foregoing types and + The X/Open Curses standard documents all of the foregoing types and symbols except for newscr, TABSIZE, and ESCDELAY. - X/Open Curses describes curscr only as "an internal data structure"; - SVID gave more details, noting its use "for certain low-level - operations like clearing and redrawing a screen containing garbage". + X/Open Curses describes curscr only as "an internal data structure"; + SVr4 gave more details, noting its use "for certain low-level + operations like clearing and redrawing a screen containing garbage". Neither specified its interaction with the rest of the interface beyond use as an argument to clearok(3x) and wrefresh(3x). - newscr is a feature of SVr4 curses. When refreshing the screen, this - window is used as a working area for combining the standard screen - stdscr with any other windows which the application may have created - with newwin(3x). When the updated newscr is complete, curses updates - curscr to match newscr. + newscr is a feature of SVr4 curses. When refreshing the screen, it is + used as a working area for combining the standard window stdscr with + any others the application may have created with newwin(3x). When the + update of newscr is complete, curses modifies curscr to match newscr. TABSIZE is a feature of SVr4 curses. @@ -248,35 +255,44 @@
- curses(3x), curs_opaque(3x), curs_terminfo(3x), curs_threads(3x), - term_variables(3x), terminfo(5) + curses(3x), curs_color(3x), curs_opaque(3x), curs_terminfo(3x), + curs_threads(3x), term_variables(3x), terminfo(5) [UAX #29] "Unicode Standard Annex #29: Unicode Text Segmentation"; <https://unicode.org/reports/tr29/> -ncurses 6.4 2023-12-16 curs_variables(3x) +ncurses 6.4 2023-12-23 curs_variables(3x)