@@ -17,6 +17,7 @@ Defined by this header:
1717 Macro | Meaning / value
1818 :--------------|---------------------------------------------------
1919 PDCURSES | PDCurses-only features are available
20+ PDCURSESMOD | PDCursesMod-only features are available
2021 PDC_BUILD | API build version
2122 PDC_VER_MAJOR | major version number
2223 PDC_VER_MINOR | minor version number
@@ -34,11 +35,10 @@ Defined by this header:
3435Text Attributes
3536===============
3637
37- By default, PDCurses uses 64-bit integers for its chtype. All chtypes
38- have bits devoted to character data, attribute data, and color pair data.
39- There are three configurations supported :
38+ All chtypes have bits devoted to character data, attribute data, and color
39+ pair data. There are four configurations supported :
4040
41- Default, 64-bit chtype, both wide- and 8-bit character builds:
41+ ### Default, 64-bit chtype, both wide- and 8-bit character builds:
4242
4343 color pair | unused | modifiers | character eg 'a'
4444 --------------|--------|-----------------------|--------------------
@@ -49,7 +49,11 @@ Default, 64-bit chtype, both wide- and 8-bit character builds:
4949 6 currently unused bits (38-43)
5050 20 color pair bits (44-63), enough for 1048576 color pairs
5151
52- 32-bit chtypes with wide characters (CHTYPE_32 and PDC_WIDE are #defined):
52+ As of 2025 Dec 30, WinGUI, VT, X11 and X11new, Linux framebuffer,
53+ DOSVGA, OpenGL, and SDLn can have COLOR_PAIRS = 1048576. Plan9 and
54+ WinCon may join them. DOS and OS/2 lack full-color capability.
55+
56+ ### 32-bit chtypes with wide characters (CHTYPE_32 and PDC_WIDE are #defined):
5357
5458 color pair | modifiers | character eg 'a'
5559 -----------------|-----------------------|--------------------
@@ -59,28 +63,27 @@ Default, 64-bit chtype, both wide- and 8-bit character builds:
5963 8 attribute bits (16-23)
6064 8 color pair bits (24-31), for 256 color pairs
6165
62- 32-bit chtypes with narrow characters (CHTYPE_32 #defined, PDC_WIDE is not):
66+ ### 32-bit chtypes with narrow characters (CHTYPE_32 #defined, PDC_WIDE is not):
6367
6468 color pair | modifiers |character
6569 --------------------|---------------------|----------------
66- 31 30 29 .. 22 21 20|19 18 17 16 .. 10 9 8|7 6 5 4 3 2 1
70+ 31 30 29 .. 22 21 20|19 18 17 16 .. 10 9 8|7 6 5 4 3 2 1 0
6771
6872 8 character bits (0-7); only 8-bit charsets will work
6973 12 attribute bits (8-19)
7074 12 color pair bits (20-31), for 4096 pairs
7175
72- All attribute modifier schemes include eight "basic" bits: bold, underline,
73- right-line, left-line, italic, reverse and blink attributes, plus the
74- alternate character set indicator. For 32-bit narrow builds, three more
75- bits are used for overlined, dimmed, and strikeout attributes; a fourth
76- bit is reserved.
76+ ### 16-bit chtypes (CHTYPE_16 #defined, must be narrow characters) :
77+
78+ color pair |modifs |character
79+ --------------|-------|---------------
80+ 15 14 13 12 11|10 9 8 |7 6 5 4 3 2 1 0
7781
78- Default chtypes have enough character bits to support the full range of
79- Unicode, all attributes, and 2^20 = 1048576 color pairs. Note, though,
80- that as of 2022 Jun 17, only WinGUI, VT, X11, Linux framebuffer, OpenGL,
81- and SDLn have COLOR_PAIRS = 1048576. Other platforms (DOSVGA, Plan9, WinCon)
82- may join them. Some (DOS, OS/2) simply do not have full-color
83- capability.
82+ 8 character bits (0-7); only 8-bit charsets will work
83+ 3 attribute bits (8-10) : bold, reverse, blink
84+ 5 color pair bits (11-15), for 32 pairs
85+
86+ This is normally used only in very low-memory situations.
8487
8588
8689
@@ -2465,7 +2468,8 @@ printw
24652468### Return Value
24662469
24672470 All functions return the number of characters printed, or ERR on
2468- error.
2471+ error. Note that this is nonstandard; other implementations return
2472+ OK upon successful completion.
24692473
24702474### Portability
24712475 Function | X/Open | ncurses | NetBSD
0 commit comments