Debian Codegraph @

upstream/opensuse-leap-16-1/man3/ncurses.3ncurses

raw
1 '\" t
2 .\"***************************************************************************
3 .\" Copyright 2018-2024,2025 Thomas E. Dickey *
4 .\" Copyright 1998-2015,2017 Free Software Foundation, Inc. *
5 .\" *
6 .\" Permission is hereby granted, free of charge, to any person obtaining a *
7 .\" copy of this software and associated documentation files (the *
8 .\" "Software"), to deal in the Software without restriction, including *
9 .\" without limitation the rights to use, copy, modify, merge, publish, *
10 .\" distribute, distribute with modifications, sublicense, and/or sell *
11 .\" copies of the Software, and to permit persons to whom the Software is *
12 .\" furnished to do so, subject to the following conditions: *
13 .\" *
14 .\" The above copyright notice and this permission notice shall be included *
15 .\" in all copies or substantial portions of the Software. *
16 .\" *
17 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS *
18 .\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF *
19 .\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. *
20 .\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, *
21 .\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR *
22 .\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR *
23 .\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
24 .\" *
25 .\" Except as contained in this notice, the name(s) of the above copyright *
26 .\" holders shall not be used in advertising or otherwise to promote the *
27 .\" sale, use or other dealings in this Software without prior written *
28 .\" authorization. *
29 .\"***************************************************************************
30 .\"
31 .\" $Id: ncurses.3x,v 1.252 2025/04/05 22:54:19 tom Exp $
32 .TH ncurses 3NCURSES 2025-04-05 "ncurses 6.5" "Library calls"
33 .ie \n(.g \{\
34 .ds `` \(lq
35 .ds '' \(rq
36 .\}
37 .el \{\
38 .ie t .ds `` ``
39 .el .ds `` ""
40 .ie t .ds '' ''
41 .el .ds '' ""
42 .\}
43 .
44 .de bP
45 .ie n .IP \(bu 4
46 .el .IP \(bu 2
47 ..
48 .
49 .\" Add supplementary paragraph tag on its own line after TP.
50 .\" Adapted from TQ (which would produce mandoc warnings).
51 .de tQ
52 . br
53 . ns
54 . TP
55 ..
56 .
57 .SH NAME
58 \fB\%ncurses\fP \-
59 character-cell terminal interface with optimized output
60 .SH SYNOPSIS
61 .nf
62 \fB#include <ncursesw/curses.h>
63 .fi
64 .SH DESCRIPTION
65 The \*(``new curses\*('' library offers the programmer a
66 terminal-independent means of reading keyboard and mouse input and
67 writing to character-cell displays with output optimized to minimize
68 screen updates.
69 .I \%ncurses
70 replaces the
71 .I curses
72 libraries from
73 System V Release 4 Unix (\*(``SVr4\*('')
74 and
75 4.4BSD Unix,
76 the development of which ceased in the 1990s.
77 This document describes
78 .I \%ncurses
79 version 6.5
80 (patch 20250531).
81 .PP
82 .I \%ncurses
83 permits control of the terminal screen's contents;
84 abstraction and subdivision thereof with
85 .I windows
86 and
87 .IR pads ;
88 acquisition of keyboard and mouse events;
89 selection of color and rendering attributes
90 (such as bold or underline);
91 the definition and use of
92 .I "soft label"
93 keys;
94 access to the
95 .I \%term\%info
96 terminal capability database;
97 a
98 .I termcap
99 compatibility interface;
100 and an abstraction of the system's API for manipulating the terminal
101 (such as \fI\%termios\fP(3)).
102 .PP
103 .I \%ncurses
104 implements the interface described by X/Open Curses Issue\ 7.
105 In many behavioral details not standardized by X/Open,
106 .I \%ncurses
107 emulates the
108 .I curses
109 library of SVr4 and provides numerous useful extensions.
110 .PP
111 .I \%ncurses
112 man pages employ several sections to clarify matters of usage and
113 interoperability with other
114 .I curses
115 implementations.
116 .bP
117 \*(``NOTES\*('' describes issues and caveats of which any user of the
118 .I \%ncurses
119 API should be aware,
120 such as limitations on the size of an underlying integral type or the
121 availability of a preprocessor macro exclusive of a function definition
122 (which prevents its address from being taken).
123 This section also describes implementation details
124 of significance to the programmer but which are not standardized.
125 .bP
126 \*(``EXTENSIONS\*('' presents
127 .I \%ncurses
128 innovations beyond the X/Open Curses standard and/or the SVr4
129 .I curses
130 implementation.
131 They are termed
132 .I extensions
133 to indicate that they cannot be implemented solely by using the library
134 API,
135 but require access to the library's internal state.
136 .bP
137 \*(``PORTABILITY\*('' discusses matters
138 (beyond the exercise of extensions)
139 that should be considered when writing to a
140 .I curses
141 standard,
142 or for multiple implementations.
143 .bP
144 \*(``HISTORY\*('' examines points of detail in
145 .I \%ncurses
146 and other
147 .I curses
148 implementations over the decades of their development,
149 particularly where precedent or inertia have frustrated better design
150 (and,
151 in a few cases,
152 where such inertia has been overcome).
153 .PP
154 A
155 .I curses
156 application must be linked with the library;
157 use the
158 .B \-lncurses
159 option to your compiler or linker.
160 A debugging version of the library may be available;
161 if so,
162 link with it using
163 .BR \-lncurses_g .
164 (Your system integrator may have installed these libraries such that you
165 can use the options
166 .B \-lcurses
167 and
168 .BR \-lcurses_g ,
169 respectively.)
170 The
171 .I \%ncurses_g
172 library logs events describing
173 .I \%ncurses
174 actions
175 to a file called
176 .I \%trace
177 in the current directory.
178 See section \*(``ALTERNATE CONFIGURATIONS\*('' below.
179 .SS "Application Structure"
180 A
181 .I curses
182 application uses information from the system locale;
183 \fI\%setlocale\fP(3) prepares it for
184 .I curses
185 library calls.
186 .PP
187 .RS 4
188 .EX
189 setlocale(LC_ALL, "");
190 .EE
191 .RE
192 .PP
193 If the locale is not thus initialized,
194 the library assumes that characters are printable as in ISO\ 8859-1,
195 to work with certain legacy programs.
196 You should initialize the locale;
197 do not expect consistent behavior from the library when the locale has
198 not been set up.
199 .PP
200 \fB\%initscr\fP(3NCURSES) or \fB\%newterm\fP(3NCURSES)
201 must be called to initialize
202 .I curses
203 before use of any functions
204 that access or manipulate windows or screens.
205 .PP
206 To get character-at-a-time input without echoing \(em
207 most interactive,
208 screen-oriented programs want this \(em
209 use the following sequence.
210 .PP
211 .RS 4
212 .EX
213 initscr(); cbreak(); noecho();
214 .EE
215 .RE
216 .PP
217 Most applications would perform further setup as follows.
218 .PP
219 .RS 4
220 .EX
221 .nf
222 noqiflush();
223 keypad(stdscr, TRUE);
224 .fi
225 .EE
226 .RE
227 .PP
228 A
229 .I curses
230 program then often enters an event-handling loop.
231 Call \fB\%endwin\fP(3NCURSES) before exiting.
232 .SS Overview
233 A
234 .I curses
235 library abstracts the terminal with a
236 .I \%SCREEN
237 data structure,
238 and represents all or part of its display
239 with
240 .I \%WINDOW
241 structures.
242 Distinct properties apply to each;
243 for example,
244 the
245 .I "line discipline"
246 of a typical Unix terminal driver
247 is in one of three modes:
248 raw,
249 \%cbreak,
250 or canonical (\*(``cooked\*('').
251 In
252 .IR curses ","
253 the line discipline is a property of the screen,
254 applying identically to all windows associated with it.
255 .PP
256 A
257 .I window
258 is a rectangular grid of character cells,
259 addressed by line and column coordinates
260 .RI ( y ,
261 .IR x ),
262 with the upper left corner as (0, 0).
263 A window called
264 .BR \%stdscr ,
265 the same size as the terminal screen,
266 is always available.
267 Create others with \fB\%newwin\fP(3NCURSES).
268 .PP
269 A
270 .I curses
271 library does not manage overlapping windows
272 (but see below).
273 You can either use
274 .B \%stdscr
275 to manage one screen-filling window,
276 or tile the screen into non-overlapping windows and not use
277 .B \%stdscr
278 at all.
279 Mixing the two approaches will result in unpredictable and undesired
280 effects.
281 .PP
282 Functions permit manipulation of a window and the
283 .I cursor
284 identifying the cell within it at which the next operation will occur.
285 Among those,
286 the most basic are \fB\%move\fP(3NCURSES) and \fB\%addch\fP(3NCURSES):
287 these place the cursor within and write a character to
288 .BR \%stdscr ,
289 respectively.
290 .PP
291 Frequent changes to the terminal screen can cause unpleasant flicker or
292 inefficient use of the communication channel to the device,
293 so as a rule the library does not update it automatically.
294 Therefore,
295 after using
296 .I curses
297 functions to accumulate a set of desired updates that make sense to
298 present together,
299 call \fB\%refresh\fP(3NCURSES) to tell the library to make the user's screen
300 look like \fBstdscr\fP.
301 The library
302 .\" X/Open Curses Issue 7 assumes some optimization will be done, but
303 .\" does not mandate it in any way.
304 .I optimizes
305 its output by computing a minimal volume of operations to mutate the
306 screen from its state at the previous refresh to the new one.
307 Effective optimization demands accurate information about the terminal
308 device:
309 the management of such information is the province of the
310 \fB\%terminfo\fP(3NCURSES) API,
311 a feature of every standard
312 .I curses
313 implementation.
314 .PP
315 Special windows called
316 .I pads
317 may also be manipulated.
318 These are not constrained to the size of the terminal screen and their
319 contents need not be completely displayed.
320 See \fB\%pad\fP(3NCURSES).
321 .PP
322 Many terminals support configuration of character cell foreground and
323 background colors as well as
324 .IR attributes ","
325 which cause characters to render in such modes as
326 boldfaced,
327 underlined,
328 or in reverse video.
329 See \fB\%color\fP(3NCURSES) and \fB\%attr\fP(3NCURSES).
330 .PP
331 .I curses
332 predefines constants for a small set of forms-drawing graphics
333 corresponding to the DEC Alternate Character Set (ACS),
334 a feature of VT100 and other terminals.
335 See \fB\%addch\fP(3NCURSES).
336 .PP
337 .I curses
338 is implemented using the operating system's terminal driver;
339 key events are received not as scan codes but as byte sequences.
340 The driver reports graphical keycaps
341 (alphanumeric and punctuation keys,
342 and the space)
343 as-is.
344 Everything else,
345 including the tab,
346 enter/return,
347 keypad,
348 arrow,
349 and function keys,
350 appears to
351 .I curses
352 as a control character or a multibyte
353 .I "escape sequence."
354 .I curses
355 can translate the latter into unique
356 .I "key codes."
357 See \fB\%keypad\fP(3NCURSES) and \fB\%getch\fP(3NCURSES).
358 .PP
359 .I \%ncurses
360 provides reimplementations of the SVr4 \fBpanel\fP(3NCURSES), \fBform\fP(3FORM),
361 and \fBmenu\fP(3MENU) libraries;
362 they permit overlapping windows and ease construction of user interfaces
363 with
364 .IR curses .
365 .SS "Initialization"
366 Beware: the terminal your program is running may or may not have
367 the features you expect. Ncurses makes no attempt to check available
368 features in advance. This is upon the user.
369 .PP
370 The selection of an appropriate value of
371 .I TERM
372 in the process environment is essential to correct
373 .I curses
374 and
375 .I \%term\%info
376 library operation.
377 A well-configured system selects a correct
378 .I TERM
379 value automatically;
380 \fB\%tset\fP(1) may assist with troubleshooting exotic situations.
381 .PP
382 If you change the terminal type,
383 export the shell's
384 .I TERM
385 variable,
386 then run \fB\%tset\fP(1) or the
387 .RB \*(`` "tput init" \*(''
388 command.
389 See subsection \*(``Tabs and Initialization\*('' of \fB\%terminfo\fP(5).
390 .PP
391 If the environment variables
392 .I \%LINES
393 and
394 .I \%COLUMNS
395 are set,
396 or if the
397 .I curses
398 program is executing in a graphical windowing environment,
399 the information obtained thence overrides that obtained by
400 .IR \%term\%info .
401 An
402 .I \%ncurses
403 extension supports resizable terminal displays;
404 see \fB\%wresize\fP(3NCURSES).
405 .PP
406 If the environment variable
407 .I \%TERMINFO
408 is defined,
409 a
410 .I curses
411 program checks first for a terminal type description in the location it
412 identifies.
413 .I \%TERMINFO
414 is useful for developing type descriptions or when write permission to
415 .I \%/usr/share/terminfo
416 is not available.
417 .PP
418 See section \*(``ENVIRONMENT\*('' below.
419 .SS "Naming Conventions"
420 .I curses
421 offers many functions in variant forms using a regular set of
422 alternatives to the name of an elemental one.
423 Those prefixed with \*(``w\*('' require a
424 .I \%WINDOW
425 pointer argument;
426 those with a \*(``mv\*('' prefix first perform cursor movement using
427 \fB\%wmove\fP(3NCURSES);
428 a \*(``mvw\*('' prefix indicates both.
429 The \*(``w\*('' function is typically the elemental one;
430 the removal of this prefix usually indicates operation on
431 .BR \%stdscr .
432 .PP
433 Four functions prefixed with \*(``p\*('' require a
434 .I pad
435 argument;
436 see below.
437 .PP
438 In function synopses,
439 .I \%ncurses
440 man pages apply the following names to parameters.
441 We introduce the character types in the next subsection.
442 .PP
443 .TS
444 center;
445 Li L.
446 bf a \fIbool\fP (\fBTRUE\fP or \fBFALSE\fP)
447 c a \fIchar\fP or \fIint\fP
448 ch a \fIchtype\fP
449 wc a \fIwchar_t\fP or \fIwint_t\fP
450 wch a \fIcchar_t\fP
451 win pointer to a \fIWINDOW\fP
452 pad pointer to a \fIWINDOW\fP that is a pad
453 pair a foreground/background color pair identifier
454 .TE
455 .SS "Wide and Non-wide Character Configurations"
456 This man page primarily surveys functions that appear in any
457 configuration of the library.
458 There are two common configurations;
459 see section \*(``ALTERNATE CONFIGURATIONS\*('' below.
460 .TP 10 \" "ncursesw" + 2n
461 .I \%ncurses
462 is the library in its \*(``non-wide\*('' configuration,
463 handling only eight-bit characters.
464 It stores a character combined with attributes
465 and a color pair identifier
466 in a
467 .I \%chtype
468 datum,
469 which is often an alias of
470 .IR int .
471 A string of
472 .I curses
473 characters is similar to a C
474 .I char
475 string;
476 a
477 .I chtype
478 string ends with an integral
479 .BR 0 ","
480 the null
481 .I curses
482 character.
483 .IP
484 Attributes and a color pair identifier
485 (with no corresponding character)
486 can be stored in variables of
487 .I \%chtype
488 or
489 .I \%attr_t
490 type.
491 In either case,
492 they are accessed via an integral bit mask.
493 .IP
494 .I \%ncurses
495 stores each cell of a
496 .I \%WINDOW
497 as a
498 .IR \%chtype .
499 X/Open Curses does not specify the sizes of the character code or
500 color pair identifier,
501 nor the quantity of attribute bits,
502 in
503 .IR chtype ";"
504 these are implementation-dependent.
505 .I \%ncurses
506 uses eight bits for the character code.
507 An application requiring a wider character type,
508 for instance to represent Unicode,
509 should use the wide-character API.
510 .TP 10
511 .I \%ncursesw
512 is the library in its \*(``wide\*('' configuration,
513 which handles character encodings requiring a larger data type than
514 .I \%char
515 (a byte-sized type)
516 can represent.
517 It provides additional functions that complement those in
518 the non-wide library where the size of the underlying character type is
519 significant.
520 A somewhat regular naming convention relates many of the wide variants
521 to their non-wide counterparts;
522 where a non-wide function name contains \*(``ch\*('' or \*(``str\*('',
523 prefix it with \*(``_w\*('' to obtain the wide counterpart.
524 For example,
525 \fB\%waddch\fP becomes \fB\%wadd_wch\fP.
526 An exception is
527 .B \%ins_nwstr
528 (and its variants),
529 spelled thus instead of \*(``insn_wstr\*(''.
530 (Exceptions that add only \*(``w\*('' comprise
531 .BR \%addwstr ,
532 .BR \%inwstr ,
533 and their variants.)
534 .\" This is because they operate on "plain" wide-character strings
535 .\" (`wchar_t*`) and not curses complex character strings (`cchar_t*`).
536 .\" SVID 4 did specify functions like `addwch()` and `inswch()` that
537 .\" operated on `chtype`s assuming that they were wide enough for a
538 .\" `wchar_t` plus attribute and color pair bits; X/Open Curses did not
539 .\" standardize these.
540 .IP
541 This convention is inapplicable to some non-wide function names,
542 so other transformations are used for the wide configuration:
543 the window background management function \*(``bkgd\*('' becomes
544 \*(``bkgrnd\*('';
545 the window border-drawing and -clearing functions are suffixed with
546 \*(``_set\*('';
547 and character attribute manipulation functions like
548 \*(``attron\*('' become \*(``attr_on\*(''.
549 .RS 10 \" same as foregoing tag width
550 .TP 9 \" "cchar_t" + 2n
551 .I \%cchar_t
552 is a
553 .I "curses complex character"
554 and corresponds to the non-wide configuration's
555 .IR \%chtype .
556 It is a structure type
557 because it requires more storage than a standard scalar type offers.
558 A character code may not be representable as a
559 .IR \%char ,
560 and moreover more than one character may occupy a cell
561 (as with accent marks and other diacritics).
562 Each character is of type
563 .IR \%wchar_t ;
564 a complex character contains one spacing character and zero or more
565 non-spacing characters
566 (see below).
567 A string of complex characters ends with a
568 .I \%cchar_t
569 whose
570 .I \%wchar_t
571 member is the null wide character.
572 Attributes and a color pair identifier are stored in separate fields of
573 the structure,
574 not combined into an integer as in
575 .IR \%chtype .
576 .PP
577 .I \%ncurses
578 stores each cell of a
579 .I \%WINDOW
580 as a
581 .IR \%cchar_t .
582 \fB\%setcchar\fP(3NCURSES) and \fB\%getcchar\fP(3NCURSES)
583 store and retrieve
584 .I \%cchar_t
585 data.
586 .PP
587 The wide library API of
588 .I \%ncurses
589 depends on two data types standardized by ISO C95.
590 .TP 9
591 .I \%wchar_t
592 stores a wide character.
593 Like
594 .IR \%chtype ,
595 it may be an alias of
596 .IR int .
597 Depending on the character encoding,
598 a wide character may be
599 .IR spacing ,
600 meaning that it occupies a character cell by itself and typically
601 accompanies cursor advancement,
602 or
603 .IR non-spacing ,
604 meaning that it occupies the same cell as a spacing character,
605 is often regarded as a \*(``modifier\*('' of the base glyph with which
606 it combines,
607 and typically does not advance the cursor.
608 .TP 9
609 .I \%wint_t
610 can store a
611 .I \%wchar_t
612 or the constant
613 .IR \%WEOF ,
614 analogously to the
615 .IR int -sized
616 character manipulation functions of ISO C and its constant
617 .IR \%EOF .
618 .RE
619 .\"
620 .SS "Function Name Index"
621 The following table lists the
622 .I curses
623 functions provided in the non-wide and wide APIs and the corresponding
624 man pages that describe them.
625 Those flagged with \*(``*\*(''
626 are
627 .IR \%ncurses "-specific,"
628 neither described by X/Open Curses nor present in SVr4.
629 .PP
630 .TS
631 center tab(/);
632 l l .
633 \fIcurses\fP Function Name/Man Page
634 _
635 COLOR_PAIR/\fBcolor\fP(3NCURSES)
636 PAIR_NUMBER/\fBcolor\fP(3NCURSES)
637 add_wch/\fBadd_wch\fP(3NCURSES)
638 add_wchnstr/\fBadd_wchstr\fP(3NCURSES)
639 add_wchstr/\fBadd_wchstr\fP(3NCURSES)
640 addch/\fBaddch\fP(3NCURSES)
641 addchnstr/\fBaddchstr\fP(3NCURSES)
642 addchstr/\fBaddchstr\fP(3NCURSES)
643 addnstr/\fBaddstr\fP(3NCURSES)
644 addnwstr/\fBaddwstr\fP(3NCURSES)
645 addstr/\fBaddstr\fP(3NCURSES)
646 addwstr/\fBaddwstr\fP(3NCURSES)
647 alloc_pair/\fBnew_pair\fP(3NCURSES)*
648 assume_default_colors/\fBdefault_colors\fP(3NCURSES)*
649 attr_get/\fBattr\fP(3NCURSES)
650 attr_off/\fBattr\fP(3NCURSES)
651 attr_on/\fBattr\fP(3NCURSES)
652 attr_set/\fBattr\fP(3NCURSES)
653 attroff/\fBattr\fP(3NCURSES)
654 attron/\fBattr\fP(3NCURSES)
655 attrset/\fBattr\fP(3NCURSES)
656 baudrate/\fBtermattrs\fP(3NCURSES)
657 beep/\fBbeep\fP(3NCURSES)
658 bkgd/\fBbkgd\fP(3NCURSES)
659 bkgdset/\fBbkgd\fP(3NCURSES)
660 bkgrnd/\fBbkgrnd\fP(3NCURSES)
661 bkgrndset/\fBbkgrnd\fP(3NCURSES)
662 border/\fBborder\fP(3NCURSES)
663 border_set/\fBborder_set\fP(3NCURSES)
664 box/\fBborder\fP(3NCURSES)
665 box_set/\fBborder_set\fP(3NCURSES)
666 can_change_color/\fBcolor\fP(3NCURSES)
667 cbreak/\fBinopts\fP(3NCURSES)
668 chgat/\fBattr\fP(3NCURSES)
669 clear/\fBclear\fP(3NCURSES)
670 clearok/\fBoutopts\fP(3NCURSES)
671 clrtobot/\fBclear\fP(3NCURSES)
672 clrtoeol/\fBclear\fP(3NCURSES)
673 color_content/\fBcolor\fP(3NCURSES)
674 color_set/\fBattr\fP(3NCURSES)
675 copywin/\fBoverlay\fP(3NCURSES)
676 curs_set/\fBkernel\fP(3NCURSES)
677 curses_trace/\fBtrace\fP(3NCURSES)*
678 curses_version/\fBextensions\fP(3NCURSES)*
679 def_prog_mode/\fBkernel\fP(3NCURSES)
680 def_shell_mode/\fBkernel\fP(3NCURSES)
681 define_key/\fBdefine_key\fP(3NCURSES)*
682 del_curterm/\fBterminfo\fP(3NCURSES)
683 delay_output/\fButil\fP(3NCURSES)
684 delch/\fBdelch\fP(3NCURSES)
685 deleteln/\fBdeleteln\fP(3NCURSES)
686 delscreen/\fBinitscr\fP(3NCURSES)
687 delwin/\fBwindow\fP(3NCURSES)
688 derwin/\fBwindow\fP(3NCURSES)
689 doupdate/\fBrefresh\fP(3NCURSES)
690 dupwin/\fBwindow\fP(3NCURSES)
691 echo/\fBinopts\fP(3NCURSES)
692 echo_wchar/\fBadd_wch\fP(3NCURSES)
693 echochar/\fBaddch\fP(3NCURSES)
694 endwin/\fBinitscr\fP(3NCURSES)
695 erase/\fBclear\fP(3NCURSES)
696 erasechar/\fBtermattrs\fP(3NCURSES)
697 erasewchar/\fBtermattrs\fP(3NCURSES)
698 exit_curses/\fBmemleaks\fP(3NCURSES)*
699 exit_terminfo/\fBmemleaks\fP(3NCURSES)*
700 extended_color_content/\fBcolor\fP(3NCURSES)*
701 extended_pair_content/\fBcolor\fP(3NCURSES)*
702 extended_slk_color/\fBslk\fP(3NCURSES)*
703 filter/\fButil\fP(3NCURSES)
704 find_pair/\fBnew_pair\fP(3NCURSES)*
705 flash/\fBbeep\fP(3NCURSES)
706 flushinp/\fButil\fP(3NCURSES)
707 free_pair/\fBnew_pair\fP(3NCURSES)*
708 get_escdelay/\fBthreads\fP(3NCURSES)*
709 get_wch/\fBget_wch\fP(3NCURSES)
710 get_wstr/\fBget_wstr\fP(3NCURSES)
711 getattrs/\fBattr\fP(3NCURSES)
712 getbegx/\fBlegacy\fP(3NCURSES)*
713 getbegy/\fBlegacy\fP(3NCURSES)*
714 getbegyx/\fBgetyx\fP(3NCURSES)
715 getbkgd/\fBbkgd\fP(3NCURSES)
716 getbkgrnd/\fBbkgrnd\fP(3NCURSES)
717 getcchar/\fBgetcchar\fP(3NCURSES)
718 getch/\fBgetch\fP(3NCURSES)
719 getcurx/\fBlegacy\fP(3NCURSES)*
720 getcury/\fBlegacy\fP(3NCURSES)*
721 getmaxx/\fBlegacy\fP(3NCURSES)*
722 getmaxy/\fBlegacy\fP(3NCURSES)*
723 getmaxyx/\fBgetyx\fP(3NCURSES)
724 getmouse/\fBmouse\fP(3NCURSES)*
725 getn_wstr/\fBget_wstr\fP(3NCURSES)
726 getnstr/\fBgetstr\fP(3NCURSES)
727 getparx/\fBlegacy\fP(3NCURSES)*
728 getpary/\fBlegacy\fP(3NCURSES)*
729 getparyx/\fBgetyx\fP(3NCURSES)
730 getstr/\fBgetstr\fP(3NCURSES)
731 getsyx/\fBkernel\fP(3NCURSES)
732 getwin/\fButil\fP(3NCURSES)
733 getyx/\fBgetyx\fP(3NCURSES)
734 halfdelay/\fBinopts\fP(3NCURSES)
735 has_colors/\fBcolor\fP(3NCURSES)
736 has_ic/\fBtermattrs\fP(3NCURSES)
737 has_il/\fBtermattrs\fP(3NCURSES)
738 has_key/\fBgetch\fP(3NCURSES)*
739 has_mouse/\fBmouse\fP(3NCURSES)*
740 hline/\fBborder\fP(3NCURSES)
741 hline_set/\fBborder_set\fP(3NCURSES)
742 idcok/\fBoutopts\fP(3NCURSES)
743 idlok/\fBoutopts\fP(3NCURSES)
744 immedok/\fBoutopts\fP(3NCURSES)
745 in_wch/\fBin_wch\fP(3NCURSES)
746 in_wchnstr/\fBin_wchstr\fP(3NCURSES)
747 in_wchstr/\fBin_wchstr\fP(3NCURSES)
748 inch/\fBinch\fP(3NCURSES)
749 inchnstr/\fBinchstr\fP(3NCURSES)
750 inchstr/\fBinchstr\fP(3NCURSES)
751 init_color/\fBcolor\fP(3NCURSES)
752 init_extended_color/\fBcolor\fP(3NCURSES)*
753 init_extended_pair/\fBcolor\fP(3NCURSES)*
754 init_pair/\fBcolor\fP(3NCURSES)
755 initscr/\fBinitscr\fP(3NCURSES)
756 innstr/\fBinstr\fP(3NCURSES)
757 innwstr/\fBinwstr\fP(3NCURSES)
758 ins_nwstr/\fBins_wstr\fP(3NCURSES)
759 ins_wch/\fBins_wch\fP(3NCURSES)
760 ins_wstr/\fBins_wstr\fP(3NCURSES)
761 insch/\fBinsch\fP(3NCURSES)
762 insdelln/\fBdeleteln\fP(3NCURSES)
763 insertln/\fBdeleteln\fP(3NCURSES)
764 insnstr/\fBinsstr\fP(3NCURSES)
765 insstr/\fBinsstr\fP(3NCURSES)
766 instr/\fBinstr\fP(3NCURSES)
767 intrflush/\fBinopts\fP(3NCURSES)
768 inwstr/\fBinwstr\fP(3NCURSES)
769 is_cbreak/\fBinopts\fP(3NCURSES)*
770 is_cleared/\fBopaque\fP(3NCURSES)*
771 is_echo/\fBinopts\fP(3NCURSES)*
772 is_idcok/\fBopaque\fP(3NCURSES)*
773 is_idlok/\fBopaque\fP(3NCURSES)*
774 is_immedok/\fBopaque\fP(3NCURSES)*
775 is_keypad/\fBopaque\fP(3NCURSES)*
776 is_leaveok/\fBopaque\fP(3NCURSES)*
777 is_linetouched/\fBtouch\fP(3NCURSES)
778 is_nl/\fBinopts\fP(3NCURSES)*
779 is_nodelay/\fBopaque\fP(3NCURSES)*
780 is_notimeout/\fBopaque\fP(3NCURSES)*
781 is_pad/\fBopaque\fP(3NCURSES)*
782 is_raw/\fBinopts\fP(3NCURSES)*
783 is_scrollok/\fBopaque\fP(3NCURSES)*
784 is_subwin/\fBopaque\fP(3NCURSES)*
785 is_syncok/\fBopaque\fP(3NCURSES)*
786 is_term_resized/\fBresizeterm\fP(3NCURSES)*
787 is_wintouched/\fBtouch\fP(3NCURSES)
788 isendwin/\fBinitscr\fP(3NCURSES)
789 key_defined/\fBkey_defined\fP(3NCURSES)*
790 key_name/\fButil\fP(3NCURSES)
791 keybound/\fBkeybound\fP(3NCURSES)*
792 keyname/\fButil\fP(3NCURSES)
793 keyok/\fBkeyok\fP(3NCURSES)*
794 keypad/\fBinopts\fP(3NCURSES)
795 killchar/\fBtermattrs\fP(3NCURSES)
796 killwchar/\fBtermattrs\fP(3NCURSES)
797 leaveok/\fBoutopts\fP(3NCURSES)
798 longname/\fBtermattrs\fP(3NCURSES)
799 mcprint/\fBprint\fP(3NCURSES)*
800 meta/\fBinopts\fP(3NCURSES)
801 mouse_trafo/\fBmouse\fP(3NCURSES)*
802 mouseinterval/\fBmouse\fP(3NCURSES)*
803 mousemask/\fBmouse\fP(3NCURSES)*
804 move/\fBmove\fP(3NCURSES)
805 mvadd_wch/\fBadd_wch\fP(3NCURSES)
806 mvadd_wchnstr/\fBadd_wchstr\fP(3NCURSES)
807 mvadd_wchstr/\fBadd_wchstr\fP(3NCURSES)
808 mvaddch/\fBaddch\fP(3NCURSES)
809 mvaddchnstr/\fBaddchstr\fP(3NCURSES)
810 mvaddchstr/\fBaddchstr\fP(3NCURSES)
811 mvaddnstr/\fBaddstr\fP(3NCURSES)
812 mvaddnwstr/\fBaddwstr\fP(3NCURSES)
813 mvaddstr/\fBaddstr\fP(3NCURSES)
814 mvaddwstr/\fBaddwstr\fP(3NCURSES)
815 mvchgat/\fBattr\fP(3NCURSES)
816 mvcur/\fBkernel\fP(3NCURSES)
817 mvdelch/\fBdelch\fP(3NCURSES)
818 mvderwin/\fBwindow\fP(3NCURSES)
819 mvget_wch/\fBget_wch\fP(3NCURSES)
820 mvget_wstr/\fBget_wstr\fP(3NCURSES)
821 mvgetch/\fBgetch\fP(3NCURSES)
822 mvgetn_wstr/\fBget_wstr\fP(3NCURSES)
823 mvgetnstr/\fBgetstr\fP(3NCURSES)
824 mvgetstr/\fBgetstr\fP(3NCURSES)
825 mvhline/\fBborder\fP(3NCURSES)
826 mvhline_set/\fBborder_set\fP(3NCURSES)
827 mvin_wch/\fBin_wch\fP(3NCURSES)
828 mvin_wchnstr/\fBin_wchstr\fP(3NCURSES)
829 mvin_wchstr/\fBin_wchstr\fP(3NCURSES)
830 mvinch/\fBinch\fP(3NCURSES)
831 mvinchnstr/\fBinchstr\fP(3NCURSES)
832 mvinchstr/\fBinchstr\fP(3NCURSES)
833 mvinnstr/\fBinstr\fP(3NCURSES)
834 mvinnwstr/\fBinwstr\fP(3NCURSES)
835 mvins_nwstr/\fBins_wstr\fP(3NCURSES)
836 mvins_wch/\fBins_wch\fP(3NCURSES)
837 mvins_wstr/\fBins_wstr\fP(3NCURSES)
838 mvinsch/\fBinsch\fP(3NCURSES)
839 mvinsnstr/\fBinsstr\fP(3NCURSES)
840 mvinsstr/\fBinsstr\fP(3NCURSES)
841 mvinstr/\fBinstr\fP(3NCURSES)
842 mvinwstr/\fBinwstr\fP(3NCURSES)
843 mvprintw/\fBprintw\fP(3NCURSES)
844 mvscanw/\fBscanw\fP(3NCURSES)
845 mvvline/\fBborder\fP(3NCURSES)
846 mvvline_set/\fBborder_set\fP(3NCURSES)
847 mvwadd_wch/\fBadd_wch\fP(3NCURSES)
848 mvwadd_wchnstr/\fBadd_wchstr\fP(3NCURSES)
849 mvwadd_wchstr/\fBadd_wchstr\fP(3NCURSES)
850 mvwaddch/\fBaddch\fP(3NCURSES)
851 mvwaddchnstr/\fBaddchstr\fP(3NCURSES)
852 mvwaddchstr/\fBaddchstr\fP(3NCURSES)
853 mvwaddnstr/\fBaddstr\fP(3NCURSES)
854 mvwaddnwstr/\fBaddwstr\fP(3NCURSES)
855 mvwaddstr/\fBaddstr\fP(3NCURSES)
856 mvwaddwstr/\fBaddwstr\fP(3NCURSES)
857 mvwchgat/\fBattr\fP(3NCURSES)
858 mvwdelch/\fBdelch\fP(3NCURSES)
859 mvwget_wch/\fBget_wch\fP(3NCURSES)
860 mvwget_wstr/\fBget_wstr\fP(3NCURSES)
861 mvwgetch/\fBgetch\fP(3NCURSES)
862 mvwgetn_wstr/\fBget_wstr\fP(3NCURSES)
863 mvwgetnstr/\fBgetstr\fP(3NCURSES)
864 mvwgetstr/\fBgetstr\fP(3NCURSES)
865 mvwhline/\fBborder\fP(3NCURSES)
866 mvwhline_set/\fBborder_set\fP(3NCURSES)
867 mvwin/\fBwindow\fP(3NCURSES)
868 mvwin_wch/\fBin_wch\fP(3NCURSES)
869 mvwin_wchnstr/\fBin_wchstr\fP(3NCURSES)
870 mvwin_wchstr/\fBin_wchstr\fP(3NCURSES)
871 mvwinch/\fBinch\fP(3NCURSES)
872 mvwinchnstr/\fBinchstr\fP(3NCURSES)
873 mvwinchstr/\fBinchstr\fP(3NCURSES)
874 mvwinnstr/\fBinstr\fP(3NCURSES)
875 mvwinnwstr/\fBinwstr\fP(3NCURSES)
876 mvwins_nwstr/\fBins_wstr\fP(3NCURSES)
877 mvwins_wch/\fBins_wch\fP(3NCURSES)
878 mvwins_wstr/\fBins_wstr\fP(3NCURSES)
879 mvwinsch/\fBinsch\fP(3NCURSES)
880 mvwinsnstr/\fBinsstr\fP(3NCURSES)
881 mvwinsstr/\fBinsstr\fP(3NCURSES)
882 mvwinstr/\fBinstr\fP(3NCURSES)
883 mvwinwstr/\fBinwstr\fP(3NCURSES)
884 mvwprintw/\fBprintw\fP(3NCURSES)
885 mvwscanw/\fBscanw\fP(3NCURSES)
886 mvwvline/\fBborder\fP(3NCURSES)
887 mvwvline_set/\fBborder_set\fP(3NCURSES)
888 napms/\fBkernel\fP(3NCURSES)
889 newpad/\fBpad\fP(3NCURSES)
890 newterm/\fBinitscr\fP(3NCURSES)
891 newwin/\fBwindow\fP(3NCURSES)
892 nl/\fBinopts\fP(3NCURSES)
893 nocbreak/\fBinopts\fP(3NCURSES)
894 nodelay/\fBinopts\fP(3NCURSES)
895 noecho/\fBinopts\fP(3NCURSES)
896 nofilter/\fButil\fP(3NCURSES)*
897 nonl/\fBinopts\fP(3NCURSES)
898 noqiflush/\fBinopts\fP(3NCURSES)
899 noraw/\fBinopts\fP(3NCURSES)
900 notimeout/\fBinopts\fP(3NCURSES)
901 overlay/\fBoverlay\fP(3NCURSES)
902 overwrite/\fBoverlay\fP(3NCURSES)
903 pair_content/\fBcolor\fP(3NCURSES)
904 pecho_wchar/\fBpad\fP(3NCURSES)
905 pechochar/\fBpad\fP(3NCURSES)
906 pnoutrefresh/\fBpad\fP(3NCURSES)
907 prefresh/\fBpad\fP(3NCURSES)
908 printw/\fBprintw\fP(3NCURSES)
909 putp/\fBterminfo\fP(3NCURSES)
910 putwin/\fButil\fP(3NCURSES)
911 qiflush/\fBinopts\fP(3NCURSES)
912 raw/\fBinopts\fP(3NCURSES)
913 redrawwin/\fBrefresh\fP(3NCURSES)
914 refresh/\fBrefresh\fP(3NCURSES)
915 reset_color_pairs/\fBcolor\fP(3NCURSES)*
916 reset_prog_mode/\fBkernel\fP(3NCURSES)
917 reset_shell_mode/\fBkernel\fP(3NCURSES)
918 resetty/\fBkernel\fP(3NCURSES)
919 resize_term/\fBresizeterm\fP(3NCURSES)*
920 resizeterm/\fBresizeterm\fP(3NCURSES)*
921 restartterm/\fBterminfo\fP(3NCURSES)
922 ripoffline/\fBkernel\fP(3NCURSES)
923 savetty/\fBkernel\fP(3NCURSES)
924 scanw/\fBscanw\fP(3NCURSES)
925 scr_dump/\fBscr_dump\fP(3NCURSES)
926 scr_init/\fBscr_dump\fP(3NCURSES)
927 scr_restore/\fBscr_dump\fP(3NCURSES)
928 scr_set/\fBscr_dump\fP(3NCURSES)
929 scrl/\fBscroll\fP(3NCURSES)
930 scroll/\fBscroll\fP(3NCURSES)
931 scrollok/\fBoutopts\fP(3NCURSES)
932 set_curterm/\fBterminfo\fP(3NCURSES)
933 set_escdelay/\fBthreads\fP(3NCURSES)*
934 set_tabsize/\fBthreads\fP(3NCURSES)*
935 set_term/\fBinitscr\fP(3NCURSES)
936 setcchar/\fBgetcchar\fP(3NCURSES)
937 setscrreg/\fBoutopts\fP(3NCURSES)
938 setsyx/\fBkernel\fP(3NCURSES)
939 setupterm/\fBterminfo\fP(3NCURSES)
940 slk_attr/\fBslk\fP(3NCURSES)*
941 slk_attr_off/\fBslk\fP(3NCURSES)
942 slk_attr_on/\fBslk\fP(3NCURSES)
943 slk_attr_set/\fBslk\fP(3NCURSES)
944 slk_attroff/\fBslk\fP(3NCURSES)
945 slk_attron/\fBslk\fP(3NCURSES)
946 slk_attrset/\fBslk\fP(3NCURSES)
947 slk_clear/\fBslk\fP(3NCURSES)
948 slk_color/\fBslk\fP(3NCURSES)
949 slk_init/\fBslk\fP(3NCURSES)
950 slk_label/\fBslk\fP(3NCURSES)
951 slk_noutrefresh/\fBslk\fP(3NCURSES)
952 slk_refresh/\fBslk\fP(3NCURSES)
953 slk_restore/\fBslk\fP(3NCURSES)
954 slk_set/\fBslk\fP(3NCURSES)
955 slk_touch/\fBslk\fP(3NCURSES)
956 slk_wset/\fBslk\fP(3NCURSES)
957 standend/\fBattr\fP(3NCURSES)
958 standout/\fBattr\fP(3NCURSES)
959 start_color/\fBcolor\fP(3NCURSES)
960 subpad/\fBpad\fP(3NCURSES)
961 subwin/\fBwindow\fP(3NCURSES)
962 syncok/\fBwindow\fP(3NCURSES)
963 term_attrs/\fBtermattrs\fP(3NCURSES)
964 termattrs/\fBtermattrs\fP(3NCURSES)
965 termname/\fBtermattrs\fP(3NCURSES)
966 tgetent/\fBtermcap\fP(3NCURSES)
967 tgetflag/\fBtermcap\fP(3NCURSES)
968 tgetnum/\fBtermcap\fP(3NCURSES)
969 tgetstr/\fBtermcap\fP(3NCURSES)
970 tgoto/\fBtermcap\fP(3NCURSES)
971 tigetflag/\fBterminfo\fP(3NCURSES)
972 tigetnum/\fBterminfo\fP(3NCURSES)
973 tigetstr/\fBterminfo\fP(3NCURSES)
974 timeout/\fBinopts\fP(3NCURSES)
975 tiparm/\fBterminfo\fP(3NCURSES)
976 tiparm_s/\fBterminfo\fP(3NCURSES)*
977 tiscan_s/\fBterminfo\fP(3NCURSES)*
978 touchline/\fBtouch\fP(3NCURSES)
979 touchwin/\fBtouch\fP(3NCURSES)
980 tparm/\fBterminfo\fP(3NCURSES)
981 tputs/\fBtermcap\fP(3NCURSES)
982 tputs/\fBterminfo\fP(3NCURSES)
983 trace/\fBtrace\fP(3NCURSES)*
984 typeahead/\fBinopts\fP(3NCURSES)
985 unctrl/\fButil\fP(3NCURSES)
986 unget_wch/\fBget_wch\fP(3NCURSES)
987 ungetch/\fBgetch\fP(3NCURSES)
988 ungetmouse/\fBmouse\fP(3NCURSES)*
989 untouchwin/\fBtouch\fP(3NCURSES)
990 use_default_colors/\fBdefault_colors\fP(3NCURSES)*
991 use_env/\fButil\fP(3NCURSES)
992 use_extended_names/\fBextensions\fP(3NCURSES)*
993 use_legacy_coding/\fBlegacy_coding\fP(3NCURSES)*
994 use_screen/\fBthreads\fP(3NCURSES)*
995 use_tioctl/\fButil\fP(3NCURSES)*
996 use_window/\fBthreads\fP(3NCURSES)*
997 vid_attr/\fBterminfo\fP(3NCURSES)
998 vid_puts/\fBterminfo\fP(3NCURSES)
999 vidattr/\fBterminfo\fP(3NCURSES)
1000 vidputs/\fBterminfo\fP(3NCURSES)
1001 vline/\fBborder\fP(3NCURSES)
1002 vline_set/\fBborder_set\fP(3NCURSES)
1003 vw_printw/\fBprintw\fP(3NCURSES)
1004 vw_scanw/\fBscanw\fP(3NCURSES)
1005 vwprintw/\fBprintw\fP(3NCURSES)
1006 vwscanw/\fBscanw\fP(3NCURSES)
1007 wadd_wch/\fBadd_wch\fP(3NCURSES)
1008 wadd_wchnstr/\fBadd_wchstr\fP(3NCURSES)
1009 wadd_wchstr/\fBadd_wchstr\fP(3NCURSES)
1010 waddch/\fBaddch\fP(3NCURSES)
1011 waddchnstr/\fBaddchstr\fP(3NCURSES)
1012 waddchstr/\fBaddchstr\fP(3NCURSES)
1013 waddnstr/\fBaddstr\fP(3NCURSES)
1014 waddnwstr/\fBaddwstr\fP(3NCURSES)
1015 waddstr/\fBaddstr\fP(3NCURSES)
1016 waddwstr/\fBaddwstr\fP(3NCURSES)
1017 wattr_get/\fBattr\fP(3NCURSES)
1018 wattr_off/\fBattr\fP(3NCURSES)
1019 wattr_on/\fBattr\fP(3NCURSES)
1020 wattr_set/\fBattr\fP(3NCURSES)
1021 wattroff/\fBattr\fP(3NCURSES)
1022 wattron/\fBattr\fP(3NCURSES)
1023 wattrset/\fBattr\fP(3NCURSES)
1024 wbkgd/\fBbkgd\fP(3NCURSES)
1025 wbkgdset/\fBbkgd\fP(3NCURSES)
1026 wbkgrnd/\fBbkgrnd\fP(3NCURSES)
1027 wbkgrndset/\fBbkgrnd\fP(3NCURSES)
1028 wborder/\fBborder\fP(3NCURSES)
1029 wborder_set/\fBborder_set\fP(3NCURSES)
1030 wchgat/\fBattr\fP(3NCURSES)
1031 wclear/\fBclear\fP(3NCURSES)
1032 wclrtobot/\fBclear\fP(3NCURSES)
1033 wclrtoeol/\fBclear\fP(3NCURSES)
1034 wcolor_set/\fBattr\fP(3NCURSES)
1035 wcursyncup/\fBwindow\fP(3NCURSES)
1036 wdelch/\fBdelch\fP(3NCURSES)
1037 wdeleteln/\fBdeleteln\fP(3NCURSES)
1038 wecho_wchar/\fBadd_wch\fP(3NCURSES)
1039 wechochar/\fBaddch\fP(3NCURSES)
1040 wenclose/\fBmouse\fP(3NCURSES)*
1041 werase/\fBclear\fP(3NCURSES)
1042 wget_wch/\fBget_wch\fP(3NCURSES)
1043 wget_wstr/\fBget_wstr\fP(3NCURSES)
1044 wgetbkgrnd/\fBbkgrnd\fP(3NCURSES)
1045 wgetch/\fBgetch\fP(3NCURSES)
1046 wgetdelay/\fBopaque\fP(3NCURSES)*
1047 wgetn_wstr/\fBget_wstr\fP(3NCURSES)
1048 wgetnstr/\fBgetstr\fP(3NCURSES)
1049 wgetparent/\fBopaque\fP(3NCURSES)*
1050 wgetscrreg/\fBopaque\fP(3NCURSES)*
1051 wgetstr/\fBgetstr\fP(3NCURSES)
1052 whline/\fBborder\fP(3NCURSES)
1053 whline_set/\fBborder_set\fP(3NCURSES)
1054 win_wch/\fBin_wch\fP(3NCURSES)
1055 win_wchnstr/\fBin_wchstr\fP(3NCURSES)
1056 win_wchstr/\fBin_wchstr\fP(3NCURSES)
1057 winch/\fBinch\fP(3NCURSES)
1058 winchnstr/\fBinchstr\fP(3NCURSES)
1059 winchstr/\fBinchstr\fP(3NCURSES)
1060 winnstr/\fBinstr\fP(3NCURSES)
1061 winnwstr/\fBinwstr\fP(3NCURSES)
1062 wins_nwstr/\fBins_wstr\fP(3NCURSES)
1063 wins_wch/\fBins_wch\fP(3NCURSES)
1064 wins_wstr/\fBins_wstr\fP(3NCURSES)
1065 winsch/\fBinsch\fP(3NCURSES)
1066 winsdelln/\fBdeleteln\fP(3NCURSES)
1067 winsertln/\fBdeleteln\fP(3NCURSES)
1068 winsnstr/\fBinsstr\fP(3NCURSES)
1069 winsstr/\fBinsstr\fP(3NCURSES)
1070 winstr/\fBinstr\fP(3NCURSES)
1071 winwstr/\fBinwstr\fP(3NCURSES)
1072 wmouse_trafo/\fBmouse\fP(3NCURSES)*
1073 wmove/\fBmove\fP(3NCURSES)
1074 wnoutrefresh/\fBrefresh\fP(3NCURSES)
1075 wprintw/\fBprintw\fP(3NCURSES)
1076 wredrawln/\fBrefresh\fP(3NCURSES)
1077 wrefresh/\fBrefresh\fP(3NCURSES)
1078 wresize/\fBwresize\fP(3NCURSES)*
1079 wscanw/\fBscanw\fP(3NCURSES)
1080 wscrl/\fBscroll\fP(3NCURSES)
1081 wsetscrreg/\fBoutopts\fP(3NCURSES)
1082 wstandend/\fBattr\fP(3NCURSES)
1083 wstandout/\fBattr\fP(3NCURSES)
1084 wsyncdown/\fBwindow\fP(3NCURSES)
1085 wsyncup/\fBwindow\fP(3NCURSES)
1086 wtimeout/\fBinopts\fP(3NCURSES)
1087 wtouchln/\fBtouch\fP(3NCURSES)
1088 wunctrl/\fButil\fP(3NCURSES)
1089 wvline/\fBborder\fP(3NCURSES)
1090 wvline_set/\fBborder_set\fP(3NCURSES)
1091 .TE
1092 .PP
1093 .IR \%ncurses 's
1094 .I "screen-pointer extension"
1095 adds additional functions corresponding to many of the above,
1096 each with an \*(``_sp\*('' suffix;
1097 see \fBsp_funcs\fP(3NCURSES).
1098 .PP
1099 The availability of some extensions is configurable when
1100 .I \%ncurses
1101 is compiled;
1102 see sections \*(``ALTERNATE CONFIGURATIONS\*('' and \*(``EXTENSIONS\*(''
1103 below.
1104 .SH RETURN VALUE
1105 Unless otherwise noted,
1106 functions that return integers return the constants
1107 .B OK
1108 on success and
1109 .B ERR
1110 on failure;
1111 see \fB\%curses_variables\fP(3NCURSES).
1112 Functions that return pointers return
1113 .I NULL
1114 on failure.
1115 Typically,
1116 .I \%ncurses
1117 treats a null pointer passed as a function parameter as a failure.
1118 Functions prefixed with \*(``mv\*('' first perform cursor movement and
1119 fail if the position
1120 .RI ( y ,
1121 .IR x )
1122 is outside the window boundaries.
1123 .SH ENVIRONMENT
1124 The following symbols from the process environment customize the
1125 runtime behavior of
1126 .I \%ncurses
1127 applications.
1128 The library may be configured to disregard the variables
1129 .IR \%TERMINFO ,
1130 .IR \%TERMINFO_DIRS ,
1131 .IR \%TERMPATH ,
1132 and
1133 .IR HOME ,
1134 if the user is the superuser (root),
1135 or the application uses \fI\%setuid\fP(2) or \fI\%setgid\fP(2).
1136 .SS "\fIBAUDRATE\fP"
1137 The debugging library checks this variable when the application has
1138 redirected output to a file.
1139 .I \%ncurses
1140 interprets its integral value as the terminal's line speed
1141 in bits per second.
1142 If that value is absent or invalid,
1143 .I \%ncurses
1144 uses 9600.
1145 This feature allows developers to construct repeatable test cases
1146 that take into account optimization decisions that depend
1147 on the terminal's line speed.
1148 .SS "\fICC\fP (command character)"
1149 When set,
1150 the
1151 .B \%command_character
1152 .RB \%( cmdch )
1153 capability value of loaded
1154 .I \%term\%info
1155 entries changes to the value of this variable.
1156 Very few
1157 .I \%term\%info
1158 entries provide this feature.
1159 .PP
1160 Because this name is also used in development environments to store the
1161 C compiler's name,
1162 .I \%ncurses
1163 ignores its value if it is not one character in length.
1164 .SS "\fICOLUMNS\fP"
1165 This variable specifies the width of the screen in characters.
1166 Applications running in a windowing environment usually are able to
1167 obtain the width of the window in which they are executing.
1168 .I \%ncurses
1169 enforces an upper limit of 512 when reading the value.
1170 If
1171 .I \%COLUMNS
1172 is not defined and the terminal's screen size is not available from the
1173 terminal driver,
1174 .I \%ncurses
1175 uses the size specified by the
1176 .B \%columns
1177 .RB \%( cols )
1178 capability of the terminal type's entry in the
1179 .I \%term\%info
1180 database,
1181 if any.
1182 .PP
1183 It is important that your application use the correct screen size.
1184 Automatic detection thereof is not always possible because an
1185 application may be running on a host that does not honor NAWS
1186 (Negotiations About Window Size)
1187 or as a different user ID than the owner of the terminal device file.
1188 Setting
1189 .I \%COLUMNS
1190 and/or
1191 .I \%LINES
1192 overrides the library's use of the screen size obtained from the
1193 operating system.
1194 .PP
1195 The
1196 .I \%COLUMNS
1197 and
1198 .I \%LINES
1199 variables may be specified independently.
1200 This property is useful to circumvent misfeatures of legacy terminal
1201 type descriptions;
1202 \fI\%xterm\fP(1) descriptions specifying 65 lines were once notorious.
1203 For best results,
1204 avoid specifying
1205 .B cols
1206 and
1207 .B lines
1208 capability codes in
1209 .I \%term\%info
1210 descriptions of terminal emulators.
1211 .PP
1212 \fBuse_env\fP(3NCURSES) can disable use of the process environment
1213 in determining the screen size.
1214 \fBuse_tioctl\fP(3NCURSES) can update
1215 .I \%COLUMNS
1216 and
1217 .I \%LINES
1218 to match the screen size obtained from system calls or the terminal
1219 database.
1220 .SS "\fIESCDELAY\fP"
1221 For
1222 .I curses
1223 to distinguish the ESC character resulting from a user's press of the
1224 \*(``Escape\*('' key on the input device from one beginning an
1225 .I "escape sequence"
1226 (as commonly produced by function keys),
1227 it waits after receiving the escape character to see if further
1228 characters are available on the input stream within a short interval.
1229 A global variable
1230 .B \%ESCDELAY
1231 stores this interval in milliseconds.
1232 The default value of 1000
1233 (one second)
1234 is adequate for most uses.
1235 This environment variable overrides it;
1236 .I \%ncurses
1237 enforces an upper limit of 30,000
1238 (30 seconds)
1239 when reading the value.
1240 .PP
1241 The most common instance where you may wish to change this value
1242 is to work with a remote host over a slow communication channel.
1243 If the host running a
1244 .I curses
1245 application does not receive the characters of an escape sequence in a
1246 timely manner,
1247 the library can interpret them as multiple key stroke events.
1248 .PP
1249 \fI\%xterm\fP(1) mouse events are a form of escape sequence;
1250 therefore,
1251 if your application makes heavy use of multiple-clicking,
1252 you may wish to lengthen the default value because the delay applies
1253 to the composite multi-click event as well as the individual clicks.
1254 .PP
1255 Portable applications should not rely upon the presence of
1256 .B \%ESCDELAY
1257 in either form,
1258 but setting the environment variable rather than the global variable
1259 does not create problems when compiling an application.
1260 .PP
1261 If \fB\%keypad\fP(3NCURSES) is disabled for the
1262 .I curses
1263 window receiving input,
1264 a program must disambiguate escape sequences itself.
1265 .SS "\fIHOME\fP"
1266 .I \%ncurses
1267 may read and write auxiliary terminal descriptions in
1268 .I \%.termcap
1269 and
1270 .I \%.terminfo
1271 files in the user's home directory.
1272 .SS "\fILINES\fP"
1273 This counterpart to
1274 .I \%COLUMNS
1275 specifies the height of the screen in characters.
1276 The corresponding
1277 .I \%term\%info
1278 capability and code is
1279 .BR \%lines .
1280 See the description of the
1281 .I \%COLUMNS
1282 variable above.
1283 .SS "\fIMOUSE_BUTTONS_123\fP"
1284 (OS/2 EMX port only)
1285 OS/2 numbers a three-button mouse inconsistently with other platforms,
1286 such that 1 is the left button,
1287 2 the right,
1288 and 3 the middle.
1289 This variable customizes the mouse button numbering.
1290 Its value must be three digits 1\-3 in any order.
1291 By default,
1292 .I \%ncurses
1293 assumes a numbering of \*(``132\*(''.
1294 .SS "\fINCURSES_ASSUMED_COLORS\fP"
1295 If set,
1296 this variable overrides the
1297 .I \%ncurses
1298 library's compiled-in assumption that the terminal's default colors are
1299 white on black;
1300 see \fB\%default_colors\fP(3NCURSES).
1301 Set the foreground and background color values with this environment
1302 variable by assigning it two integer values separated by a comma,
1303 indicating foregound and background color numbers,
1304 respectively.
1305 .PP
1306 For example,
1307 to tell
1308 .I \%ncurses
1309 not to assume anything about the colors,
1310 use a value of \*(``\-1,\-1\*(''.
1311 To make the default color scheme green on black,
1312 use \*(``2,0\*(''.
1313 .I \%ncurses
1314 accepts integral values from \-1 up to the value of the
1315 .I \%term\%info
1316 .B \%max_colors
1317 .RB ( colors )
1318 capability.
1319 .SS "\fINCURSES_CONSOLE2\fP"
1320 (MinGW port only)
1321 The
1322 .I \%Console2
1323 .\" https://www.hanselman.com/blog/console2-a-better-windows-command-prompt
1324 program defectively handles the Microsoft Console API call
1325 .IR \%Create\%Console\%Screen\%Buffer .
1326 Applications that use it will hang.
1327 However,
1328 it is possible to simulate the action of this call by mapping
1329 coordinates,
1330 explicitly saving and restoring the original screen contents.
1331 Setting the environment variable
1332 .I \%NCGDB
1333 has the same effect.
1334 .SS "\fINCURSES_GPM_TERMS\fP"
1335 (Linux only)
1336 When
1337 .I \%ncurses
1338 is configured to use the GPM interface,
1339 this variable may list one or more terminal type names,
1340 delimited by vertical bars
1341 .RB ( | )
1342 or colons
1343 .RB ( : ),
1344 against which the
1345 .I TERM
1346 variable
1347 (see below)
1348 is matched.
1349 An empty value disables the GPM interface,
1350 using
1351 .IR \%ncurses 's
1352 built-in support for \fI\%xterm\fP(1) mouse protocols instead.
1353 If the variable is absent,
1354 .I \%ncurses
1355 attempts to open GPM if
1356 .I TERM
1357 contains \*(``linux\*(''.
1358 .SS "\fINCURSES_NO_HARD_TABS\fP"
1359 .I \%ncurses
1360 may use tab characters in cursor movement optimization.
1361 In some cases,
1362 your terminal driver may not handle them properly.
1363 Set this environment variable to any value to disable the feature.
1364 You can also adjust your \fI\%stty\fP(1) settings to avoid the problem.
1365 .SS "\fINCURSES_NO_MAGIC_COOKIE\fP"
1366 Many terminals store video attributes as a property of a character cell,
1367 as
1368 .I curses
1369 does.
1370 Historically,
1371 some recorded changes in video attributes as data that logically
1372 .I occupies
1373 character cells on the display,
1374 switching attributes on or off,
1375 similarly to tags in a markup language;
1376 these are termed \*(``magic cookies\*('',
1377 and must be subsequently overprinted.
1378 If the
1379 .I \%term\%info
1380 entry for your terminal type does not adequately describe its handling
1381 of magic cookies,
1382 set this variable to any value to instruct
1383 .I \%ncurses
1384 to disable attributes entirely.
1385 .SS "\fINCURSES_NO_PADDING\fP"
1386 Most terminal type descriptions in the
1387 .I \%term\%info
1388 database detail hardware devices.
1389 Many people use
1390 .IR curses -based
1391 applications in terminal emulator programs that run in a windowing
1392 environment.
1393 These programs can duplicate all of the important features of a hardware
1394 terminal,
1395 but often lack their limitations.
1396 Chief among these absent drawbacks is the problem of data flow
1397 management;
1398 that is,
1399 limiting the speed of communication to what the hardware could handle.
1400 Unless a hardware terminal is interfaced into a terminal concentrator
1401 (which does flow control),
1402 an application must manage flow itself to prevent overruns and data
1403 loss.
1404 .PP
1405 A solution that comes at no hardware cost is for an application to pause
1406 after directing a terminal to execute an operation that it performs
1407 slowly,
1408 such as clearing the display.
1409 Many terminal type descriptions,
1410 including that for the VT100,
1411 embed delay specifications in capabilities.
1412 You may wish to use these terminal descriptions without paying the
1413 performance penalty.
1414 Set
1415 .I \%NCURSES_NO_PADDING
1416 to any value to disable all but mandatory padding.
1417 Mandatory padding is used by such terminal capabilities as
1418 .B \%flash_screen
1419 .RB ( flash ).
1420 .SS "\fINCURSES_NO_SETBUF\fP"
1421 (Obsolete)
1422 Prior to internal changes developed in
1423 .I \%ncurses
1424 5.9
1425 (patches 20120825 through 20130126),
1426 the library used \fI\%setbuf\fP(3) to enable fully buffered output when
1427 initializing the terminal.
1428 This was done,
1429 as in SVr4
1430 .IR curses ,
1431 to increase performance.
1432 For testing purposes,
1433 both of
1434 .I \%ncurses
1435 and of certain applications,
1436 this feature was made optional.
1437 Setting this variable disabled output buffering,
1438 leaving the output stream in the original
1439 (usually line-buffered)
1440 mode.
1441 .PP
1442 Nowadays,
1443 .I \%ncurses
1444 performs its own buffering and does not require this workaround;
1445 it does not modify the buffering of the standard output stream.
1446 This approach makes signal handling,
1447 as for interrupts,
1448 more robust.
1449 A drawback is that certain unconventional programs mixed
1450 \fI\%stdio\fP(3) calls with
1451 .I \%ncurses
1452 calls and (usually)
1453 got the behavior they expected.
1454 This is no longer the case;
1455 .I \%ncurses
1456 does not write to the standard output file descriptor through a
1457 .IR stdio -buffered
1458 stream.
1459 .PP
1460 As a special case,
1461 low-level API calls such as \fB\%putp\fP(3NCURSES) still use the
1462 standard output stream.
1463 High-level
1464 .I curses
1465 calls such as \fB\%printw\fP(3NCURSES) do not.
1466 .SS "\fINCURSES_NO_UTF8_ACS\fP"
1467 At initialization,
1468 .I \%ncurses
1469 inspects the
1470 .I TERM
1471 environment variable for special cases where VT100 forms-drawing
1472 characters
1473 (and the corresponding alternate character set
1474 .I \%term\%info
1475 capabilities)
1476 are known to be unsupported by terminal types that otherwise claim VT100
1477 compatibility.
1478 Specifically,
1479 when running in a UTF-8 locale,
1480 the Linux virtual console device and the GNU \fI\%screen\fP(1)
1481 program ignore them.
1482 Set this variable to a nonzero value to instruct
1483 .I \%ncurses
1484 that the terminal's ACS support is broken;
1485 the library then outputs Unicode code points that correspond to the
1486 forms-drawing
1487 characters.
1488 Set it to zero
1489 (or a non-integer)
1490 to disable the special check for terminal type names matching
1491 \*(``linux\*('' or \*(``screen\*('',
1492 directing
1493 .I \%ncurses
1494 to assume that the ACS feature works if the terminal type description
1495 advertises it.
1496 .PP
1497 As an alternative to use of this variable,
1498 .I \%ncurses
1499 checks for an extended
1500 .I \%term\%info
1501 numeric capability \fBU8\fP
1502 that can be compiled using
1503 .RB \*(`` "tic \-x" \*(''.
1504 Examples follow.
1505 .PP
1506 .RS 3
1507 .EX
1508 .nf
1509 # linux console, if patched to provide working
1510 # VT100 shift\-in/shift\-out, with corresponding font.
1511 linux\-vt100|linux console with VT100 line\-graphics,
1512 U8#0, use=linux,
1513 \&
1514 # uxterm with vt100Graphics resource set to false
1515 xterm\-utf8|xterm relying on UTF\-8 line\-graphics,
1516 U8#1, use=xterm,
1517 .nf
1518 .EE
1519 .RE
1520 .PP
1521 The two-character name \*(``U8\*('' was chosen to permit its use via
1522 .IR \%ncurses 's
1523 .I termcap
1524 interface.
1525 .SS "\fINCURSES_TRACE\fP"
1526 At initialization,
1527 .I \%ncurses
1528 (in its debugging configuration)
1529 checks for this variable's presence.
1530 If defined with an integral value,
1531 the library calls \fB\%curses_trace\fP(3NCURSES) with that value as the
1532 argument.
1533 .SS "\fITERM\fP"
1534 The
1535 .I TERM
1536 variable denotes the terminal type.
1537 Each is distinct,
1538 though many are similar.
1539 It is commonly set by terminal emulators to help applications find a
1540 workable terminal description.
1541 Some choose a popular approximation such as \*(``ansi\*('',
1542 \*(``vt100\*('', or \*(``xterm\*('' rather than an exact fit to their
1543 capabilities.
1544 Not infrequently,
1545 an application will have problems with that approach;
1546 for example,
1547 a key stroke may not operate correctly,
1548 or produce no effect but seeming garbage characters on the screen.
1549 .PP
1550 Setting
1551 .I TERM
1552 has no effect on hardware operation;
1553 it affects the way applications communicate with the terminal.
1554 Likewise,
1555 as a general rule
1556 (\fIxterm\fP(1) being a rare exception),
1557 terminal emulators that allow you to specify
1558 .I TERM
1559 as a parameter or configuration value do not change their behavior to
1560 match that setting.
1561 .SS "\fITERMCAP\fP"
1562 If
1563 .I \%ncurses
1564 is configured with
1565 .I termcap
1566 support,
1567 it checks for a terminal type description in
1568 .I termcap
1569 format if one in
1570 .I \%term\%info
1571 format is not available.
1572 Setting this variable directs
1573 .I \%ncurses
1574 to ignore the usual
1575 .I termcap
1576 database location,
1577 .IR \%/etc/termcap ;
1578 see
1579 .I \%TERMPATH
1580 below.
1581 .I \%TERMCAP
1582 should contain either a terminal description
1583 (with newlines stripped out),
1584 or a file name indicating where the information required by the
1585 .I TERM
1586 environment variable is stored.
1587 .SS "\fITERMINFO\fP"
1588 .I \%ncurses
1589 can be configured to read terminal type description databases in various
1590 locations using different formats.
1591 This variable overrides the default location.
1592 .bP
1593 Descriptions in
1594 .I \%term\%info
1595 format are normally stored in a directory tree using subdirectories
1596 named for the common first letters of the terminal types named therein.
1597 System\ V used this scheme.
1598 .bP
1599 If
1600 .I \%ncurses
1601 is configured to use hashed databases,
1602 then
1603 .I \%TERM\%INFO
1604 may name its location,
1605 such as
1606 .IR \%/usr/share/terminfo.db ,
1607 rather than
1608 .IR \%/usr/share/terminfo/ .
1609 .PP
1610 The hashed database uses less disk space and is a little faster than the
1611 directory tree.
1612 However,
1613 some applications assume the existence of the directory tree,
1614 and read it directly
1615 rather than using the
1616 .I \%term\%info
1617 API.
1618 .bP
1619 If
1620 .I \%ncurses
1621 is configured with
1622 .I termcap
1623 support,
1624 this variable may contain the location of a
1625 .I \%termcap
1626 file.
1627 .bP
1628 If the value of
1629 .I \%TERM\%INFO
1630 begins with \*(``hex:\*('' or \*(``b64:\*('',
1631 .I \%ncurses
1632 uses the remainder of the value as a compiled
1633 .I \%term\%info
1634 description.
1635 You might produce the base64 format using \fB\%infocmp\fP(1).
1636 .RS 4
1637 .IP
1638 .EX
1639 .nf
1640 TERMINFO=$(infocmp \-0 \-Q2 \-q)
1641 export TERMINFO
1642 .fi
1643 .EE
1644 .RE
1645 .IP
1646 .I \%ncurses
1647 uses the compiled description only if it corresponds
1648 to the terminal type identified by
1649 .IR TERM .
1650 .PP
1651 Setting
1652 .I \%TERM\%INFO
1653 is the simplest,
1654 but not the only,
1655 way to direct
1656 .I \%ncurses
1657 to a terminal database.
1658 The search path is as follows.
1659 .bP
1660 the last terminal database to which the running
1661 .I \%ncurses
1662 application wrote,
1663 if any
1664 .bP
1665 the location specified by the
1666 .I \%TERM\%INFO
1667 environment variable
1668 .bP
1669 .I $HOME/.terminfo
1670 .bP
1671 locations listed in the
1672 .I \%TERMINFO_DIRS
1673 environment variable
1674 .ds td \" empty
1675 .if !'/etc/terminfo:/usr/share/terminfo'no default value' .as td /etc/terminfo:/usr/share/terminfo
1676 .if !'/usr/share/terminfo\*(td'' \{\
1677 .bP
1678 location(s) configured and compiled into
1679 .I \%ncurses
1680 .RS
1681 .if !'\*(td'' \{\
1682 .bP
1683 .I \%/etc/terminfo:/usr/share/terminfo
1684 .\}
1685 .if !'@TERMINFO'' .if !'\*(td'/usr/share/terminfo' \{\
1686 .bP
1687 .I \%/usr/share/terminfo
1688 .\}
1689 .\}
1690 .RE
1691 .SS "\fITERMINFO_DIRS\fP"
1692 This variable specifies a list of locations,
1693 akin to
1694 .IR PATH ,
1695 in which
1696 .I \%ncurses
1697 searches for the terminal type descriptions described by
1698 .I \%TERMINFO
1699 above.
1700 The list items are separated by colons on Unix
1701 and semicolons on OS/2 EMX.
1702 System\ V
1703 .I \%term\%info
1704 lacks a corresponding feature;
1705 .I \%TERMINFO_DIRS
1706 is an
1707 .I \%ncurses
1708 extension.
1709 .SS "\fITERMPATH\fP"
1710 If
1711 .I \%TERMCAP
1712 does not hold a terminal type description or file name,
1713 then
1714 .I \%ncurses
1715 checks the contents of
1716 .IR \%TERMPATH ,
1717 a list of locations,
1718 akin to
1719 .IR PATH ,
1720 in which it searches for
1721 .I termcap
1722 terminal type descriptions.
1723 The list items are separated by colons on Unix
1724 and semicolons on OS/2 EMX.
1725 .PP
1726 If both
1727 .I \%TERMCAP
1728 and
1729 .I \%TERMPATH
1730 are unset or invalid,
1731 .I \%ncurses
1732 searches for the files
1733 .IR \%/etc/termcap ,
1734 .IR \%/usr/share/misc/termcap ,
1735 and
1736 .IR \%$HOME/.termcap ,
1737 in that order.
1738 .SH "ALTERNATE CONFIGURATIONS"
1739 Many different
1740 .I \%ncurses
1741 configurations are possible,
1742 determined by the options given to the
1743 .I \%configure
1744 script when building the library.
1745 Run the script with the
1746 .B \%\-\-help
1747 option to peruse them all.
1748 A few are of particular significance to the application developer
1749 employing
1750 .IR \%ncurses .
1751 .TP 5
1752 .B \-\-disable\-overwrite
1753 The standard C preprocessor inclusion for the
1754 .I curses
1755 library is as follows.
1756 .RS 5
1757 .PP
1758 .RS 4
1759 .EX
1760 .nf
1761 .\" The dummy character prevents undesired rewriting of the next line on
1762 .\" installation of the man page.
1763 \fB#\&include <curses.h>\fP
1764 .fi
1765 .EE
1766 .RE
1767 .PP
1768 This option is used to avoid file name conflicts between
1769 .I \%ncurses
1770 and an existing
1771 .I curses
1772 installation on the system.
1773 If
1774 .I \%ncurses
1775 is installed disabling overwrite,
1776 it puts its header files in a subdirectory.
1777 Here is an example.
1778 .PP
1779 .RS 4
1780 .EX
1781 .\" The dummy character prevents undesired rewriting of the next line on
1782 .\" installation of the man page.
1783 \fB#\&include <ncurses/curses.h>\fP
1784 .EE
1785 .RE
1786 .PP
1787 Installation also omits a symbolic link that would cause the compiler's
1788 .B \%\-lcurses
1789 option to link object files with
1790 .I \%ncurses
1791 instead of the system
1792 .I curses
1793 library.
1794 .PP
1795 The directory used by this configuration of
1796 .I \%ncurses
1797 is shown in section \*(``SYNOPSIS\*('' above.
1798 .RE
1799 .TP 5
1800 .B \-\-enable\-widec
1801 The configure script renames the library and
1802 (if the
1803 .B \%\-\-disable\-overwrite
1804 option is used)
1805 puts the header files in a different subdirectory.
1806 All of the library names have a \*(``w\*('' appended to them,
1807 i.e., instead of
1808 .RS 5
1809 .PP
1810 .RS 4
1811 .EX
1812 .B \-lncurses
1813 .EE
1814 .RE
1815 .PP
1816 you link with
1817 .PP
1818 .RS 4
1819 .EX
1820 .B \-lncursesw
1821 .EE
1822 .RE
1823 .PP
1824 You must also enable the wide-character features in the header file
1825 when compiling for the wide-character library
1826 to use the extended (wide-character) functions.
1827 The symbol which enables these features has changed
1828 since X/Open Curses Issue\ 4:
1829 .bP
1830 Originally,
1831 the wide-character feature required the symbol
1832 .B \%_XOPEN_SOURCE_EXTENDED
1833 but that was only valid for XPG4 (1996).
1834 .bP
1835 Later,
1836 that was deemed conflicting with an
1837 .B \%_XOPEN_SOURCE
1838 value of 500.
1839 .bP
1840 As of mid-2018,
1841 none of the features in this implementation require a
1842 .B \%_XOPEN_SOURCE
1843 feature greater than 600.
1844 However,
1845 X/Open Curses Issue\ 7 (2009) recommends defining it to 700.
1846 .bP
1847 Alternatively,
1848 you can enable the feature by defining
1849 .B \%NCURSES_WIDECHAR
1850 with the caveat that some header file other than
1851 .I \%curses.h
1852 may require a specific value for
1853 .B \%_XOPEN_SOURCE
1854 (or a system-specific symbol).
1855 .PP
1856 The
1857 .I \%curses.h
1858 header file installed
1859 for the wide-character library
1860 is designed to be compatible with the non-wide library's header.
1861 Only the size of the
1862 .I \%WINDOW
1863 structure differs;
1864 few applications require more than pointers to
1865 .IR \%WINDOW "."
1866 .PP
1867 If the headers are installed allowing overwrite,
1868 the wide-character library's headers should be installed last,
1869 to allow applications to be built using either library
1870 from the same set of headers.
1871 .RE
1872 .TP 5
1873 .B \-\-with\-pthread
1874 The configure script renames the library.
1875 All of the library names have a \*(``t\*('' appended to them
1876 (before any \*(``w\*('' added by
1877 .BR \%\-\-enable\-widec ).
1878 .IP
1879 .I \%ncursest
1880 and
1881 .I \%ncursestw
1882 replace global variables such as
1883 .B \%LINES
1884 with macros allowing read-only access.
1885 At the same time,
1886 they provide functions to set these values.
1887 Very few applications require changes
1888 to work with this convention.
1889 .\" see definition of NCURSES_WRAPPED_VAR
1890 .TP 5
1891 .B \-\-with\-shared
1892 .tQ
1893 .B \-\-with\-normal
1894 .tQ
1895 .B \-\-with\-debug
1896 .tQ
1897 .B \-\-with\-profile
1898 The shared and normal (static) library names differ by their suffixes,
1899 e.g.,
1900 .I \%libncurses.so
1901 and
1902 .IR \%libncurses.a "."
1903 The debug and profiling libraries add a \*(``_g\*(''
1904 and a \*(``_p\*('' to the roots of these respective names,
1905 forming
1906 .I \%libncurses_g.so
1907 and
1908 .IR \%libncurses_p.a ","
1909 for example.
1910 .TP 5
1911 .B \-\-with\-termlib
1912 This option configures
1913 .I \%ncurses
1914 to provide low-level functions that do not depend
1915 upon wide-character support in a library names
1916 .IR \%tinfo "."
1917 .IP
1918 This arrangement enables
1919 .I \%tinfo
1920 to be shared between
1921 .I \%ncurses
1922 and
1923 .I \%ncursesw
1924 libraries as well as application linking and/or loading times
1925 when it requires only low-level functions.
1926 .IP
1927 The following pages describe low-level
1928 .I curses
1929 functions.
1930 .RS
1931 .bP
1932 \fB\%extensions\fP(3NCURSES) \- miscellaneous \fIcurses\fP extensions
1933 .bP
1934 \fB\%inopts\fP(3NCURSES) \- \fIcurses\fP input options
1935 .bP
1936 \fB\%kernel\fP(3NCURSES) \- low-level \fIcurses\fP routines
1937 .bP
1938 \fB\%termattrs\fP(3NCURSES) \- \fIcurses\fP environment query routines
1939 .bP
1940 \fB\%termcap\fP(3NCURSES) \- \fIcurses\fP emulation of \fItermcap\fP
1941 .bP
1942 \fB\%terminfo\fP(3NCURSES) \- \fIcurses\fP interface to \fIterminfo\fP
1943 database
1944 .bP
1945 \fB\%util\fP(3NCURSES) \- miscellaneous \fIcurses\fP utility routines
1946 .RE
1947 .TP 5
1948 .B \-\-with\-trace
1949 The
1950 .B trace
1951 function normally resides in the debug library,
1952 but it is sometimes useful to expose it in the shared or static library.
1953 Configuration scripts should check for the function's existence rather
1954 than assuming it is confined to the debug library.
1955 .SH FILES
1956 .TP
1957 .I /usr/share/tabset
1958 tab stop initialization database
1959 .TP
1960 .I /usr/share/terminfo
1961 compiled terminal capability database
1962 .SH NOTES
1963 X/Open Curses permits most functions it specifies to be made available
1964 as macros as well.
1965 .\" See X/Open Curses Issue 4, Version 2, pp. 227-234.
1966 .\" See X/Open Curses Issue 7, pp. 311-318.
1967 \fI\%ncurses\fP does so
1968 .bP
1969 for functions that return values via their parameters,
1970 .bP
1971 to support obsolete features,
1972 .bP
1973 to reuse functions
1974 (for example,
1975 those that move the cursor before another operation),
1976 and
1977 .bP
1978 in a few special cases.
1979 .PP
1980 If the standard output file descriptor of an
1981 .I \%ncurses
1982 program is redirected to something that is not a terminal device,
1983 the library writes screen updates to the standard error file descriptor.
1984 This was an undocumented feature of SVr3
1985 .IR curses .
1986 .PP
1987 See subsection \*(``Header Files\*('' below regarding symbols exposed by
1988 inclusion of \fI\%curses.h\fP.
1989 .SH EXTENSIONS
1990 .I \%ncurses
1991 enables an application to capture mouse events on certain terminals,
1992 including \fI\%xterm\fP(1);
1993 see \fB\%mouse\fP(3NCURSES).
1994 .PP
1995 .I \%ncurses
1996 provides a means of responding to window resizing events,
1997 as when running in a GUI terminal emulator application such as
1998 .IR \%xterm ;
1999 see \fB\%resizeterm\fP(3NCURSES) and \fB\%wresize\fP(3NCURSES).
2000 .PP
2001 .I \%ncurses
2002 allows an application to query the terminal for the presence of a wide
2003 variety of special keys;
2004 see \fB\%has_key\fP(3NCURSES).
2005 .PP
2006 .I \%ncurses
2007 extends the fixed set of function key capabilities specified by X/Open
2008 Curses by allowing the application programmer to define additional key
2009 events at runtime;
2010 see
2011 \fB\%define_key\fP(3NCURSES),
2012 \fB\%key_defined\fP(3NCURSES),
2013 \fB\%keybound\fP(3NCURSES),
2014 and
2015 \fB\%keyok\fP(3NCURSES).
2016 .PP
2017 .I \%ncurses
2018 can exploit the capabilities of terminals implementing ISO\ 6429/ECMA-48
2019 SGR\ 39 and SGR\ 49 sequences,
2020 which allow an application to reset the terminal to its original
2021 foreground and background colors.
2022 From a user's perspective,
2023 the application is able to draw colored text on a background whose color
2024 is set independently,
2025 providing better control over color contrasts.
2026 See \fB\%default_colors\fP(3NCURSES).
2027 .PP
2028 An
2029 .I \%ncurses
2030 application can eschew knowledge of
2031 .I \%SCREEN
2032 and
2033 .I \%WINDOW
2034 structure internals,
2035 instead using accessor functions such as
2036 \fB\%is_cbreak\fP(3NCURSES) and
2037 \fB\%is_scrollok\fP(3NCURSES).
2038 .PP
2039 .I \%ncurses
2040 enables an application to direct its output to a printer attached to the
2041 terminal device;
2042 see \fB\%print\fP(3NCURSES).
2043 .PP
2044 .I \%ncurses
2045 offers \fB\%slk_attr\fP(3NCURSES) as a counterpart of \fB\%attr_get\fP(3NCURSES) for
2046 soft-label key lines,
2047 and \fB\%extended_slk_color\fP(3NCURSES) as a form of \fB\%slk_color\fP(3NCURSES)
2048 that can gather color information from them when many colors are
2049 supported.
2050 .PP
2051 .I \%ncurses
2052 permits modification of \fB\%unctrl\fP(3NCURSES)'s behavior;
2053 see \fB\%use_legacy_coding\fP(3NCURSES).
2054 .PP
2055 Rudimentary support for multi-threaded applications may be available;
2056 see \fBthreads\fP(3NCURSES).
2057 .PP
2058 Functions that ease the management of multiple screens can be exposed;
2059 see \fBsp_funcs\fP(3NCURSES).
2060 .PP
2061 To aid applications to debug their memory usage,
2062 .I \%ncurses
2063 optionally offers functions to more aggressively free memory it
2064 dynamically allocates itself;
2065 see \fBmemleaks\fP(3NCURSES).
2066 .PP
2067 The library facilitates auditing and troubleshooting of its behavior;
2068 see \fBtrace\fP(3NCURSES).
2069 .PP
2070 Compiling
2071 .I \%ncurses
2072 with the option
2073 .B \%\-DUSE_GETCAP
2074 causes it to fall back to reading
2075 .I \%/etc/termcap
2076 if the terminal setup code cannot find a
2077 .I \%term\%info
2078 entry corresponding to
2079 .IR TERM .
2080 Use of this feature is not recommended,
2081 as it essentially includes an entire
2082 .I termcap
2083 compiler in the
2084 .I \%ncurses
2085 startup code,
2086 at a cost in memory usage and application launch latency.
2087 .PP
2088 .I \%PDCurses
2089 and NetBSD
2090 .I curses
2091 incorporate some
2092 .I \%ncurses
2093 extensions.
2094 Individual man pages indicate where this is the case.
2095 .SH PORTABILITY
2096 X/Open Curses defines two levels of conformance,
2097 \*(``base\*('' and \*(``enhanced\*(''.
2098 The latter includes several additional features,
2099 such as wide-character and color support.
2100 .I \%ncurses
2101 intends base-level conformance with X/Open Curses,
2102 and supports all features of its enhanced level
2103 except the
2104 .I \%untic
2105 utility.
2106 .PP
2107 Differences between X/Open Curses and
2108 .I \%ncurses
2109 are documented in the \*(``PORTABILITY\*('' sections of applicable man
2110 pages.
2111 .SS "Error Checking"
2112 In many cases, X/Open Curses is vague about error conditions,
2113 omitting some of the SVr4 documentation.
2114 .PP
2115 Unlike other implementations,
2116 .I \%ncurses
2117 checks pointer parameters,
2118 such as those to
2119 .I \%WINDOW
2120 structures,
2121 to ensure that they are not null.
2122 This is done primarily to guard against programmer error.
2123 The standard interface does not provide a way for the library
2124 to tell an application which of several possible errors occurred.
2125 An application that relies on
2126 .I \%ncurses
2127 to check its function parameters for validity limits its portability and
2128 robustness.
2129 .SS "Padding Differences"
2130 In historical
2131 .I curses
2132 implementations,
2133 delays embedded in the
2134 .I \%term\%info
2135 capabilities
2136 .B \%carriage_return
2137 .RB ( cr ),
2138 .B \%scroll_forward
2139 .RB ( ind ),
2140 .B \%cursor_left
2141 .RB ( cub1 ),
2142 .B \%form_feed
2143 .RB ( ff ),
2144 and
2145 .B \%tab
2146 .RB ( ht )
2147 activated corresponding delay bits in the Unix terminal driver.
2148 .I \%ncurses
2149 performs all padding by sending NUL bytes to the device.
2150 This method is slightly more expensive,
2151 but narrows the interface to the Unix kernel significantly and
2152 correspondingly increases the package's portability.
2153 .SS "Header Files"
2154 The header file
2155 .I \%curses.h
2156 itself includes the header files
2157 .I \%stdio.h
2158 and
2159 .IR \%unctrl.h .
2160 .PP
2161 X/Open Curses has more to say,
2162 .RS 4
2163 .PP
2164 The inclusion of
2165 .I \%curses.h
2166 may make visible all symbols from the headers
2167 .IR \%stdio.h ,
2168 .IR \%term.h ,
2169 .IR \%termios.h ,
2170 and
2171 .IR \%wchar.h .
2172 .RE
2173 .PP
2174 but does not finish the story.
2175 A more complete account follows.
2176 .bP
2177 The first
2178 .IR curses ","
2179 in 4BSD,
2180 provided a
2181 .I \%curses.h
2182 file.
2183 .IP
2184 BSD
2185 .I curses
2186 code included
2187 .I \%curses.h
2188 and
2189 .I \%unctrl.h
2190 from an internal header file
2191 .IR \%curses.ext ,
2192 where
2193 \*(``ext\*('' abbreviated \*(``externs\*(''.
2194 .IP
2195 The implementations of
2196 .I \%printw
2197 and
2198 .I \%scanw
2199 used undocumented internal functions of the standard I/O library
2200 .RI ( _doprnt
2201 and
2202 .IR _doscan ),
2203 but nothing in
2204 .I \%curses.h
2205 itself relied upon
2206 .IR \%stdio.h .
2207 .bP
2208 SVr2
2209 .I curses
2210 added
2211 .IR \%newterm ,
2212 which relies upon
2213 .I \%stdio.h
2214 because its function prototype employs the
2215 .I FILE
2216 type.
2217 .IP
2218 SVr4
2219 .I curses
2220 added
2221 .I \%putwin
2222 and
2223 .IR \%getwin ,
2224 which also use
2225 .IR \%stdio.h .
2226 .IP
2227 X/Open Curses specifies all three of these functions.
2228 .IP
2229 SVr4
2230 .I curses
2231 and X/Open Curses do not require the developer to include
2232 .I \%stdio.h
2233 before
2234 .IR \%curses.h .
2235 Both document use of
2236 .I curses
2237 as requiring only
2238 .IR \%curses.h .
2239 .IP
2240 As a result,
2241 standard
2242 .I \%curses.h
2243 always includes
2244 .IR \%stdio.h .
2245 .bP
2246 X/Open Curses and SVr4
2247 .I curses
2248 are inconsistent with respect to
2249 .IR \%unctrl.h .
2250 .IP
2251 As noted in \fButil\fP(3NCURSES),
2252 .I \%ncurses
2253 includes
2254 .I \%unctrl.h
2255 from
2256 .I \%curses.h
2257 (as SVr4 does).
2258 .bP
2259 X/Open Curses's comments about
2260 .I \%term.h
2261 and
2262 .I \%termios.h
2263 may refer to HP-UX and AIX.
2264 .IP
2265 HP-UX
2266 .I curses
2267 includes
2268 .I \%term.h
2269 from
2270 .I \%curses.h
2271 to declare
2272 .I \%setupterm
2273 in
2274 .IR \%curses.h ,
2275 but
2276 .I \%ncurses
2277 and Solaris
2278 .I curses
2279 do not.
2280 .IP
2281 AIX
2282 .I curses
2283 includes
2284 .I \%term.h
2285 and
2286 .IR \%termios.h .
2287 Again,
2288 .I \%ncurses
2289 and Solaris
2290 .I curses
2291 do not.
2292 .bP
2293 X/Open Curses says that
2294 .I \%curses.h
2295 .B may
2296 include
2297 .IR \%term.h ,
2298 but does not require it to do so.
2299 .IP
2300 Some programs use functions declared in both
2301 .I \%curses.h
2302 and
2303 .IR \%term.h ,
2304 and must include both header files in the same module.
2305 Very old versions of AIX
2306 .I curses
2307 required inclusion of
2308 .I \%curses.h
2309 before
2310 .IR \%term.h .
2311 .IP
2312 The header files supplied by
2313 .I \%ncurses
2314 include the standard library headers required for its declarations,
2315 so
2316 .IR \%ncurses 's
2317 own header files can be included in any order.
2318 For portability even to old AIX systems,
2319 include
2320 .I \%curses.h
2321 before
2322 .IR \%term.h .
2323 .bP
2324 X/Open Curses says \*(``may make visible\*('' because including a header
2325 file does not necessarily make visible all of the symbols in it
2326 (consider
2327 .B \%#ifdef
2328 and similar).
2329 .IP
2330 For instance,
2331 .IR \%ncurses 's
2332 .I \%curses.h
2333 .B may \" bold to contrast with preceding italic
2334 include
2335 .I \%wchar.h
2336 if the proper symbol is defined,
2337 and if
2338 .I \%ncurses
2339 is configured for wide-character support.
2340 If
2341 .I \%wchar.h
2342 is included,
2343 its symbols
2344 .B may \" bold for consistency in this paragraph
2345 be made visible depending on the value of the
2346 .B _XOPEN_SOURCE
2347 feature test macro.
2348 .bP
2349 X/Open Curses mandates an application's inclusion of one standard C
2350 library header in a special case:
2351 .I \%stdarg.h
2352 before
2353 .I \%curses.h
2354 to prototype the functions
2355 .I \%vw_printw
2356 and
2357 .I \%vw_scanw
2358 (as well as the obsolete
2359 .I \%vwprintw
2360 and
2361 .IR \%vwscanw ).
2362 Each of these takes a variadic argument list,
2363 a
2364 .I \%va_list
2365 parameter,
2366 like that of \fI\%printf\fP(3).
2367 .IP
2368 SVr3
2369 .I curses
2370 introduced
2371 the two obsolete functions,
2372 and X/Open Curses the others.
2373 In between,
2374 SVr4
2375 .I curses
2376 provided for the possibility that an application might include either
2377 .I \%varargs.h
2378 or
2379 .IR \%stdarg.h .
2380 These represented contrasting approaches to handling variadic
2381 argument lists.
2382 The older interface,
2383 .IR \%varargs.h ,
2384 used a pointer to
2385 .I char \" V7, 32V, System III, 3BSD
2386 for variadic functions'
2387 .I \%va_list
2388 parameter.
2389 Later,
2390 the list acquired its own standard data type,
2391 .IR \%va_list ,
2392 defined in
2393 .IR \%stdarg.h ,
2394 empowering the compiler to check the types of a function call's actual
2395 parameters against the formal ones declared in its prototype.
2396 .IP
2397 No conforming implementations of X/Open Curses require an application
2398 to include
2399 .I \%stdarg.h
2400 before
2401 .I \%curses.h
2402 because they either have allowed for a special type,
2403 or,
2404 like
2405 .IR \%ncurses ,
2406 they include
2407 .I \%stdarg.h
2408 themselves to provide a portable interface.
2409 .SH AUTHORS
2410 Zeyd M. Ben-Halim,
2411 Eric S. Raymond,
2412 Thomas E. Dickey.
2413 Based on
2414 .I \%pcurses
2415 by Pavel Curtis.
2416 .SH SEE ALSO
2417 \fB\%curses_variables\fP(3NCURSES),
2418 \fB\%terminfo\fP(5),
2419 \fB\%user_caps\fP(5)