[PATCH 08/16] man/curs_add{,_w}ch.3x: Fix content & style nits.

"G. Branden Robinson" <[email protected]>
Newsgroups gmane.comp.lib.ncurses.bugs
Message-ID <20260815122050.6dam3mrkxrb7glqg@illithid>
* Add forward reference regarding what the right margin is.
* Clarify: altering tab stop intervals is not an exhortation, merely an
  option.
* Recast discussion of how curses manages "the bottom rightmost
  character cell problem".  Cross reference relevant terminfo
  capabilities.

Style:
* Replace colon dangling at the end of a sentence with a period.  The
  subsequent use of bulleted paragraphs carrying complete sentences
  makes the structure clear.
* Set "curses" in italics.
---
 man/curs_add_wch.3x | 71 +++++++++++++++++++++++++++++++++------------
 man/curs_addch.3x   | 63 ++++++++++++++++++++++++++++------------
 2 files changed, 96 insertions(+), 38 deletions(-)

diff --git a/man/curs_add_wch.3x b/man/curs_add_wch.3x
index c413fcb1f..f6671a211 100644
--- a/man/curs_add_wch.3x
+++ b/man/curs_add_wch.3x
@@ -208,14 +208,15 @@ .SS wadd_wch
 Carriage return moves the cursor to the left margin on the same line of
 the window.
 .bP
-Line feed does a \fB\%clrtoeol\fP(3X),
-then advances as if from the right margin.
+Line feed performs \fB\%clrtoeol\fP(3X),
+then advances as if from the right margin
+(see below).
 .bP
 Tab advances the cursor to the next tab stop
 (possibly on the next line);
 these are placed at every eighth column by default.
 .IP
-Alter the tab interval with the
+You can alter the tab interval with the
 .B \%TABSIZE
 extension;
 see \fB\%curs_variables\fP(3X).
@@ -231,7 +232,7 @@ .SS wadd_wch
 but its \fB\%wunctrl\fP(3X) representation.
 .PP
 Adding spacing characters with \fB\%wadd_wch\fP
-causes it to wrap at the right margin of the window:
+causes it to wrap at the right margin of the window.
 .bP
 If the cursor is not at the bottom of the scrolling region
 and advancement occurs at the right margin,
@@ -253,29 +254,61 @@ .SS wadd_wch
 A window's margins may coincide with the screen boundaries.
 This may be a problem when
 .I \%ncurses
-updates the screen to match the curses window.
+updates the screen to match the
+.I curses
+window.
 When their right and bottom margins coincide,
 .I \%ncurses
-uses different strategies to handle the variations of scrolling and wrapping
-at the lower-right corner
-by depending on the terminal capabilities:
+employs varying strategies
+to handle the ways in which scrolling and wrapping behaviors
+combine at the lower-right corner of the terminal display
+by detecting and configuring the terminal's capabilities.
 .bP
-If the terminal does not automatically wrap as characters
-are added at the right margin
-(i.e., auto right margins),
+If the terminal does not wrap its cursor to the next line
+when a character is written to the rightmost cell on a line \(em
+.I \%terminfo
+capability
+.B \%auto_right_margin
+.RB ( am )
+\(em
 .I \%ncurses
-writes the character directly.
+simply writes the character.
 .bP
-If the terminal has auto right margins,
-but also has capabilities for turning auto margins off and on,
+If the terminal possesses the \*(lqauto right margin\*(rq
+capability,
+but also enables it to be configured on and off \(em
+.I \%terminfo
+capabilities
+.B \%enter_am_mode
+.RB ( smam )
+and
+.B \%exit_am_mode
+.RB ( rmam )
+\(em
 .I \%ncurses
-turns the auto margin feature off temporarily
-when writing to the lower-right corner.
+disables auto right margin temporarily
+when writing a character to lower-right cell of the terminal display.
 .bP
-If the terminal has an insertion mode which can be turned off and on,
+If the terminal does not permit auto right margin deconfiguration,
+but has an \*(lqinsert mode\*(rq \(em
+.I \%terminfo
+capabilities
+.B \%enter_insert_mode
+.RB ( smir )
+and
+.B \%exit_insert_mode
+.RB ( rmir )
+\(em
 .I \%ncurses
-writes the character just before the lower-right corner,
-and then inserts a character to push the update into the corner.
+saves the contents of the character cell
+preceding that at the bottom right,
+writes the character with which the application wishes to populate
+the bottom right character cell
+to the cell preceding it on the same line,
+then uses the terminal's insert mode to rewrite the contents
+of the saved character cell to that location,
+\*(lqpushing\*(rq the desired character
+into the bottom right cell.
 .SS wecho_wchar
 .B \%echo_wchar
 and
diff --git a/man/curs_addch.3x b/man/curs_addch.3x
index 4fc248015..81aed321d 100644
--- a/man/curs_addch.3x
+++ b/man/curs_addch.3x
@@ -167,14 +167,15 @@ .SS waddch
 Carriage return moves the cursor to the left margin on the same line of
 the window.
 .bP
-Line feed does a \fB\%clrtoeol\fP(3X),
-then advances as if from the right margin.
+Line feed performs \fB\%clrtoeol\fP(3X),
+then advances as if from the right margin
+(see below).
 .bP
 Tab advances the cursor to the next tab stop
 (possibly on the next line);
 these are placed at every eighth column by default.
 .IP
-Alter the tab interval with the
+You can alter the tab interval with the
 .B \%TABSIZE
 extension;
 see \fB\%curs_variables\fP(3X).
@@ -190,7 +191,7 @@ .SS waddch
 but its \fB\%unctrl\fP(3X) representation.
 .PP
 Adding printable characters with \fB\%waddch\fP
-causes it to wrap at the right margin of the window:
+causes it to wrap at the right margin of the window.
 .bP
 If the cursor is not at the bottom of the scrolling region
 and advancement occurs at the right margin,
@@ -212,29 +213,53 @@ .SS waddch
 A window's margins may coincide with the screen boundaries.
 This may be a problem when
 .I \%ncurses
-updates the screen to match the curses window.
+updates the screen to match the
+.I curses
+window.
 When their right and bottom margins coincide,
 .I \%ncurses
-uses different strategies to handle the variations of scrolling and wrapping
-at the lower-right corner
-by depending on the terminal capabilities:
+employs varying strategies
+to handle the ways in which scrolling and wrapping behaviors
+combine at the lower-right corner of the terminal display
+by detecting and configuring the terminal's capabilities.
 .bP
-If the terminal does not automatically wrap as characters
-are added at the right margin
-(i.e., auto right margins),
+If the terminal does not wrap its cursor to the next line
+when a character is written to the rightmost cell on a line \(em
+.RI \%( terminfo
+capability
+.B \%auto_right_margin
+.RB ( am )
+\(em
 .I \%ncurses
-writes the character directly.
+simply writes the character.
 .bP
-If the terminal has auto right margins,
-but also has capabilities for turning auto margins off and on,
+If the terminal possesses the \*(lqauto right margin\*(rq
+capability,
+but also enables it to be configured on and off,
 .I \%ncurses
-turns the auto margin feature off temporarily
-when writing to the lower-right corner.
+disables auto right margin temporarily
+when writing a character to lower-right cell of the terminal display.
 .bP
-If the terminal has an insertion mode which can be turned off and on,
+If the terminal does not permit auto right margin deconfiguration,
+but has an \*(lqinsert mode\*(rq \(em
+.I \%terminfo
+capabilities
+.B \%enter_insert_mode
+.RB ( smir )
+and
+.B \%exit_insert_mode
+.RB ( rmir )
+\(em
 .I \%ncurses
-writes the character just before the lower-right corner,
-and then inserts a character to push the update into the corner.
+saves the contents of the character cell
+preceding that at the bottom right,
+writes the character with which the application wishes to populate
+the bottom right character cell
+to the cell preceding it on the same line,
+then uses the terminal's insert mode to rewrite the contents
+of the saved character cell to that location,
+\*(lqpushing\*(rq the desired character
+into the bottom right cell.
 .SS wechochar
 .B \%echochar
 and
-- 
2.30.2
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEh3PWHWjjDgcrENwa0Z6cfXEmbc4FAmqAWaEACgkQ0Z6cfXEm
bc6qlw//Q5sEWvs2IHJfQygESaSY620E/vDH/VhDq5ugkYHXrUOSFouTf1IMHWLY
oZr2Y5hbWDYVoWro03q8fSTjgyRO9spBhid0mtRkEPRkyelXGo3UtL1R5oGFUtxP
DLqqcb0+UzxQFaiapEpvNnq1UFlmPcMp5VdLSoq41v1hY61eX37q55Yc8xrXgPz/
GRu8QBsP3IhlJ5QYdMGkqK44q8lypz0JaHlWswHSw53VtTl5OdwTjPm4IOcBZBhu
8HHtnPzRS4dj/774mlY/zUn55MuLz2sVq46UtNkigMvIbFZGWYq3UrPXuvkE6gsh
k2br2LWDX2Nt+V6y/Jbj4zyS2iDs9GDssMS/MPAhCYvAtNnndupXch8yaB2O58Dt
0Ft8vGHvObdMpwt+QBAstqF5dgJiW6SkPjQmONY/keIg3nPUVcplBRSWvKQK+9ti
+Cv3XV0ZhUuQbM1WQSHZZInWjY4Oa3dgBEhrp8wLxSb7OOwNXai+AJZwyLPB8fJ8
KHm/3/a6g1SGCfh/Jk/4YDtYcAtfBjJjHTgRJrN8p6ZibsveEX9eWrXBdnnKLB3T
ye2rGUu4A/06qb67wclcBKzJ6uILpBTqJ3K6XH9Agkj/eKFp5dk/KI3u8CBH+N3z
1/GjLUgeFKx6zM0r245NqNNMkhJyRIdf6Gn+Vz7cekwBSVGDFjU=
=ZhAH
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.