[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 30/42] man/curs_color.3x: Fix content and style nits.
From: |
G. Branden Robinson |
Subject: |
[PATCH 30/42] man/curs_color.3x: Fix content and style nits. |
Date: |
Sat, 16 Dec 2023 11:47:03 -0600 |
Content:
* Declare type of parameter to `PAIR_NUMBER()` macro in synopsis.
* Respell same parameter as `attr`, rather than `attrs`. An integer is
still a singular item even if you can decompose it with bitwise
operators.
Style:
* Describe macros in the same sequence they appear in the synopsis.
---
man/curs_color.3x | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/man/curs_color.3x b/man/curs_color.3x
index 71541a2ca..0b3bded26 100644
--- a/man/curs_color.3x
+++ b/man/curs_color.3x
@@ -96,7 +96,7 @@ .SH SYNOPSIS
\fBvoid reset_color_pairs(void);
.PP
\fBint COLOR_PAIR(int \fIn\fP);
-\fBPAIR_NUMBER(\fIattrs\fP);
+\fBPAIR_NUMBER(int \fIattr\fP);
.fi
.SH DESCRIPTION
.SS Overview
@@ -376,16 +376,18 @@ .SS reset_color_pairs
all of the color-pair information which was set with \fB\%init_pair\fP.
It also touches the current- and standard-screens, allowing an application to
switch color palettes rapidly.
-.SS PAIR_NUMBER
-\fB\%PAIR_NUMBER(\fIattrs\fR) extracts the color
-value from its \fIattrs\fP parameter and returns it as a color pair number.
.SS COLOR_PAIR
-Its inverse \fB\%COLOR_PAIR(\fIn\fB)\fR converts a color pair number
-to an attribute.
+\fB\%COLOR_PAIR(\fIn\fB)\fR converts a color pair number to an
+attribute.
Attributes can hold color pairs in the range 0 to 255.
-If you need a color pair larger than that, you must use functions
-such as \fB\%attr_set\fP (which pass the color pair as a separate parameter)
+If you need a color pair larger than that,
+you must use functions such as \fB\%attr_set\fP
+(which pass the color pair as a separate parameter)
rather than the legacy functions such as \fB\%attrset\fP.
+.SS PAIR_NUMBER
+\fB\%PAIR_NUMBER(\fIattr\fR) extracts the color information from its
+\fIattr\fP parameter and returns it as a color pair number;
+it is the inverse operation of \fB\%COLOR_PAIR\fP.
.SH RETURN VALUE
The routines \fB\%can_change_color\fP and \fB\%has_colors\fP return \fBTRUE\fP
or \fBFALSE\fP.
--
2.30.2
signature.asc
Description: PGP signature
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH 30/42] man/curs_color.3x: Fix content and style nits.,
G. Branden Robinson <=