-The
-\fBadd_wch\fP,
-\fBwadd_wch\fP,
-\fBmvadd_wch\fP, and
-\fBmvwadd_wch\fP
-functions put the complex character \fIwch\fP into the given
-window at its current position,
-which is then advanced.
-These functions perform
-wrapping and special-character processing as follows:
-.TP 5
-\-
-If \fIwch\fP refers to a spacing character,
-then any previous character at that location is removed.
-A new character specified by \fIwch\fP is
-placed at that location with rendition specified by \fIwch\fP.
-The cursor then advances to
-the next spacing character on the screen.
-.TP 5
-\-
-If \fIwch\fP refers to a non-spacing character,
-all previous characters at that location are preserved.
-The non-spacing characters of \fIwch\fP
-are added to the spacing complex character,
-and the rendition specified by \fIwch\fP is ignored.
-.TP 5
-\-
-If the character part of \fIwch\fP is
-a tab, newline, backspace or other control character,
-the window is updated and the cursor moves as if \fBaddch\fR were called.
-.PP
-The \fBecho_wchar\fP
-function is functionally equivalent to a call to
-\fBadd_wch\fP
-followed by a call to
-\fBrefresh\fP.
-Similarly, the
-\fBwecho_wchar\fP
-is functionally equivalent to a call to
-\fBwadd_wch\fP
-followed by a call to
-\fBwrefresh\fP.
-The knowledge
-that only a single character is being output is taken into consideration and,
-for non-control characters, a considerable performance gain might be seen
-by using the *\fBecho\fP* functions instead of their equivalents.
-.SH RETURN VALUES
-.PP
-All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success.
-.SH NOTES
+Much behavior depends on whether the wide characters in
+.I wch
+are spacing or non-spacing;
+see subsection \*(``Complex Characters\*('' below.
+.bP
+If
+.I wch
+contains a spacing character,
+then any character at the cursor is first removed.
+The complex character
+.IR wch ","
+with its attributes and color pair identifier,
+becomes the
+.I base
+of the
+.IR "active complex character" "."
+.bP
+If
+.I wch
+contains only non-spacing characters,
+.\" XXX: see wadd_wch_literal (the beginning of the array may be nonspacing)
+they are combined with the active complex character.
+.I curses
+ignores its attributes and color pair identifier,
+and does not advance the cursor.
+.PP
+Further non-spacing characters added with
+.B \%wadd_wch
+are not written at the new cursor position but combine with the active
+complex character until another spacing character is written to the
+window or the cursor is moved.
+.PP
+If advancement occurs at the right margin,
+.bP
+the cursor automatically wraps to the beginning of the next line,
+then,
+.bP
+if it was at the bottom of the scrolling region,
+and if \fB\%scrollok\fP(3X) is enabled for
+.IR win ,
+the scrolling region scrolls up one line.
+.PP
+If
+.I wch
+is a
+backspace,
+carriage return,
+line feed,
+or
+tab,
+the cursor moves appropriately within the window.
+.bP
+Backspace moves the cursor one character left;
+at the left margin of a window,
+it does nothing.
+.bP
+Carriage return moves the cursor to the left margin on the current line
+of the window.
+.bP
+Line feed does a \fB\%clrtoeol\fP(3X),
+then advances as if from the right margin.
+.bP
+Tab advances the cursor to the next tab stop
+(possibly on the next line);
+these are placed at every eighth column by default.
+Alter the tab interval with the
+.B \%TABSIZE
+extension;
+see \fB\%curs_variables\fP(3X).
+.PP
+If
+.I wch
+is any other nonprintable character,
+it is drawn in printable form using the same convention as
+\fB\%wunctrl\fP(3X).
+Calling \fB\%win_wch\fP(3X) on the location of a nonprintable character
+does not return the character itself,
+but its \fB\%wunctrl\fP(3X) representation.
+.PP
+A
+.I \%cchar_t
+can be copied from place to place using \fB\%win_wch\fP(3X) and
+.BR \%wadd_wch "."
+.SS wecho_wchar
+.B \%echo_wchar
+and
+.B \%wecho_wchar
+are equivalent to calling
+.RB \%( w ) add_wch
+followed by
+.RB \%( w ) refresh .
+.I curses
+interprets these functions as a hint that only a single (complex)
+character is being output;
+for non-control characters,
+a considerable performance gain may be enjoyed by employing them.
+.\" TODO: Combine the following with the "Line Drawing" subsection of
+.\" terminfo(5) and replace this with a cross reference there.
+.SS "Forms-Drawing Characters"
+.I curses
+defines macros starting with
+.B \%WACS_
+that can be used with
+.B \%wadd_wch
+to write line-drawing and other special characters to the screen.
+.I \%ncurses
+terms these
+.I "forms-drawing characters."
+The ACS default listed below is used if the
+.B \%acs_chars
+.RB \%( acsc )
+.I \%term\%info
+capability does not define a terminal-specific replacement for it,
+or if the terminal and locale configuration requires Unicode to access
+these characters but the library is unable to use Unicode.
+The \*(``acsc char\*('' column corresponds to how the characters are
+specified in the
+.B \%acs_chars
+.RB \%( acsc )
+string capability,
+and the characters in it may appear on the screen if the terminal type's
+database entry incorrectly advertises ACS support.
+The name \*(``ACS\*('' originates in the Alternate Character Set feature
+of the DEC VT100 terminal.
+.PP
+.ie t .ne 4v
+.el .ne 5v
+.TS
+Lb Lb Lb Lb Lb
+Lb Lb Lb Lb Lb
+Lb L L L Lx.
+\& Unicode ACS acsc \&
+Symbol Default Default char Glyph Name
+_
+WACS_BLOCK 0x25ae # 0 T{
+solid square block
+T}
+WACS_BOARD 0x2592 # h board of squares
+WACS_BTEE 0x2534 + v bottom tee
+WACS_BULLET 0x00b7 o ~ bullet
+WACS_CKBOARD 0x2592 : a T{
+checker board (stipple)
+T}
+WACS_DARROW 0x2193 v . T{
+arrow pointing down
+T}
+WACS_DEGREE 0x00b0 ' f degree symbol
+WACS_DIAMOND 0x25c6 + \(ga diamond
+WACS_GEQUAL 0x2265 > > T{
+greater-than-or-equal-to
+T}
+WACS_HLINE 0x2500 \- q horizontal line
+WACS_LANTERN 0x2603 # i lantern symbol
+WACS_LARROW 0x2190 < , T{
+arrow pointing left
+T}
+WACS_LEQUAL 0x2264 < y T{
+less-than-or-equal-to
+T}
+WACS_LLCORNER 0x2514 + m T{
+lower left-hand corner
+T}
+WACS_LRCORNER 0x2518 + j T{
+lower right-hand corner
+T}
+WACS_LTEE 0x2524 + t left tee
+WACS_NEQUAL 0x2260 ! | not-equal
+WACS_PI 0x03c0 * { greek pi
+WACS_PLMINUS 0x00b1 # g plus/minus
+WACS_PLUS 0x253c + n plus
+WACS_RARROW 0x2192 > + T{
+arrow pointing right
+T}
+WACS_RTEE 0x251c + u right tee
+WACS_S1 0x23ba \- o scan line 1
+WACS_S3 0x23bb \- p scan line 3
+WACS_S7 0x23bc \- r scan line 7
+WACS_S9 0x23bd \&_ s scan line 9
+WACS_STERLING 0x00a3 f } T{
+pound-sterling symbol
+T}
+WACS_TTEE 0x252c + w top tee
+WACS_UARROW 0x2191 ^ \- T{
+arrow pointing up
+T}
+WACS_ULCORNER 0x250c + l T{
+upper left-hand corner
+T}
+WACS_URCORNER 0x2510 + k T{
+upper right-hand corner
+T}
+WACS_VLINE 0x2502 | x vertical line
+.TE
+.PP
+The wide-character configuration of \fI\%ncurses\fP also defines symbols
+for thick lines (\fBacsc\fP \*(``J\*('' to \*(``V\*(''):
+.PP
+.TS
+Lb Lb Lb Lb Lb
+Lb Lb Lb Lb Lb
+Lb L L L Lx.
+\& Unicode ASCII acsc \&
+ACS Name Default Default Char Glyph Name
+_
+WACS_T_BTEE 0x253b + V T{
+thick tee pointing up
+T}
+WACS_T_HLINE 0x2501 - Q T{
+thick horizontal line
+T}
+WACS_T_LLCORNER 0x2517 + M T{
+thick lower left corner
+T}
+WACS_T_LRCORNER 0x251b + J T{
+thick lower right corner
+T}
+WACS_T_LTEE 0x252b + T T{
+thick tee pointing right
+T}
+WACS_T_PLUS 0x254b + N T{
+thick large plus
+T}
+WACS_T_RTEE 0x2523 + U T{
+thick tee pointing left
+T}
+WACS_T_TTEE 0x2533 + W T{
+thick tee pointing down
+T}
+WACS_T_ULCORNER 0x250f + L T{
+thick upper left corner
+T}
+WACS_T_URCORNER 0x2513 + K T{
+thick upper right corner
+T}
+WACS_T_VLINE 0x2503 | X T{
+thick vertical line
+T}
+.TE