Package: alsa-utils
Version: 1.2.11-1
Severity: minor
Tags: patch

Dear Maintainer,

   * What led up to the situation?

     Checking for defects with

[test-]groff -mandoc -t -K utf8 -ww -b -z < "man page"

  [test-groff is a script in the repository for "groff"]

   * What was the outcome of this action?

troff: backtrace: file '<stdin>':79
troff:<stdin>:79: warning: trailing space in the line
troff: backtrace: file '<stdin>':86
troff:<stdin>:86: warning: trailing space in the line
troff: backtrace: file '<stdin>':142
troff:<stdin>:142: warning: trailing space in the line
troff: backtrace: file '<stdin>':296
troff:<stdin>:296: warning: trailing space in the line
troff: backtrace: file '<stdin>':392
troff:<stdin>:392: warning: trailing space in the line

   * What outcome did you expect instead?

     No output (warnings).

-.-

  Remarks and a patch are in the attachments.

-- System Information:
Debian Release: trixie/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 6.7.12-amd64 (SMP w/2 CPU threads; PREEMPT)
Locale: LANG=is_IS.iso88591, LC_CTYPE=is_IS.iso88591 (charmap=ISO-8859-1), 
LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: sysvinit (via /sbin/init)

Versions of packages alsa-utils depends on:
ii  kmod              32+20240327-1
ii  libasound2t64     1.2.11-1+b1
ii  libatopology2t64  1.2.11-1+b1
ii  libc6             2.38-12
ii  libfftw3-single3  3.3.10-1+b2
ii  libncursesw6      6.5-2
ii  libsamplerate0    0.2.2-4+b1
ii  libtinfo6         6.5-2

alsa-utils recommends no packages.

Versions of packages alsa-utils suggests:
pn  dialog  <none>

-- no debconf information
  Any program (person), that produces man pages, should check its content for
defects by using

groff -mandoc -t -ww -b -z [ -K utf8 | k ] <man page>

  The same goes for man pages that are used as an input.

  For a style guide use

  mandoc -T lint

-.-

  So any generator should check its products with the above mentioned
'groff' and additionally with 'nroff ...'.

  This is just a simple quality control measure.

  The generator may have to be corrected to get a better man page,
the source file may, and any additional file may.

  Common errors:

  Not removing trailing spaces (in in- and output).
  The reason for these trailing spaces should be found and eliminated.

  Not beginning each input sentence
(that is not confined to a markup)
in the first column.
Line length should thus be reduced.

-.-

The difference between the formatted outputs can be seen with:

  nroff -mandoc <file1> > <out1>
  nroff -mandoc <file2> > <out2>
  diff -u <out1> <out2>

and for groff, using

"printf '%s\n%s\n' '.kern 0' '.ss 12 0' | groff -mandoc -Z - "

instead of "nroff -mandoc"

  Add the option "-t", if the file contains a table.

  Read the output of "diff -u" with "less -R" or similar.

-.-.

  If "man" (man-db) is used to check the manual for warnings,
the following must be set:

  The option "-warnings=w"

  The environmental variable:

export MAN_KEEP_STDERR=yes (or any non-empty value)

  or

  (produce only warnings):

export MANROFFOPT="-ww -z"

export MAN_KEEP_STDERR=yes (or any non-empty value)

-.-.

Output from "mandoc -T lint alsamixer.1": (possibly shortened list)

mandoc: alsamixer.1:29:81: STYLE: input text line longer than 80 bytes: Select 
the starting ...
mandoc: alsamixer.1:79:67: STYLE: whitespace at end of input line
mandoc: alsamixer.1:86:85: STYLE: whitespace at end of input line
mandoc: alsamixer.1:142:70: STYLE: whitespace at end of input line
mandoc: alsamixer.1:192:130: STYLE: input text line longer than 80 bytes: Valid 
values for \fI...
mandoc: alsamixer.1:194:91: STYLE: input text line longer than 80 bytes: Valid 
values for \fI...
mandoc: alsamixer.1:207:104: STYLE: input text line longer than 80 bytes: If 
enabled (\fI1\fP)...
mandoc: alsamixer.1:296:57: STYLE: whitespace at end of input line

-.-.

Remove space characters at the end of lines.

Use "git apply ... --whitespace=fix" to fix extra space issues, or use
global configuration "core.whitespace".

79:The default view mode is the playback view.  You can change it via 
86:\fBalsamixer\fP recognizes the following keyboard commands to control the 
soundcard. 
142:[\fIZ\fP | \fIX\fP | \fIC\fP ] -- turn DOWN [ left | both | right ]   
296:Increase volume of current control by \fI<N>\fP percent. 

-.-.

Change two HYPHEN-MINUSES (code 0x2D) to an em-dash (\(em),
if one is intended.  An en-dash is usually surrounded by a space,
while an em-dash is used without spaces.
"man" (1 byte characters in input) transforms an en-dash (\(en) to one
HYPHEN-MINUS,
and an em-dash to two HYPHEN-MINUSES without considering the space
around it.
If "--" are two single "-" (end of options) then use "\-\-".

alsamixer.1:140:[\fIQ\fP | \fIW\fP | \fIE\fP ]  -- turn UP [ left | both | 
right ]
alsamixer.1:142:[\fIZ\fP | \fIX\fP | \fIC\fP ] -- turn DOWN [ left | both | 
right ]   

-.-.

Mark a full stop (.) and the exclamation mark (!) with "\&",
if it does not mean an end of a sentence.
This is a preventive action,
the paragraph could be reshaped, e.g., after changes.

When typing, one does not always notice when the line wraps after the
period.
There are too many examples of input lines in manual pages,
that end with an abbreviation point.

This marking is robust, and independent of the position on the line.

It corresponds to "\ " in TeX, and to "@:" in Texinfo.


168:it, i.e. the position is the cubic root of the linear sample

-.-.

Remove space in the first column, if not indented.
Use ".in +<number>n" and ".in" to end it; ".nf" and ".fi" to end
it, for an extra indention.

alsamixer.1:217:   - a single character
alsamixer.1:218:   - a combination with control: C-a
alsamixer.1:219:   - a combination with alt: M-a
alsamixer.1:220:   - a special keyname: Enter, Escape, PageUp, PageDown, Left, 
Down, Right, Up, Home, End, Backspace, F1 .. F12

-.-.

Change a HYPHEN-MINUS (code 0x2D) to a minus(-dash) (\-),
if it
is in front of a name for an option,
is a symbol for standard input,
is a single character used to indicate an option,
or is in the NAME section (man-pages(7)).
N.B. - (0x2D), processed as a UTF-8 file, is changed to a hyphen
(0x2010, groff \[u2010] or \[hy]) in the output.

80:\fI-V\fP option.
140:[\fIQ\fP | \fIW\fP | \fIE\fP ]  -- turn UP [ left | both | right ]
142:[\fIZ\fP | \fIX\fP | \fIC\fP ] -- turn DOWN [ left | both | right ]   
217:   - a single character
218:   - a combination with control: C-a
219:   - a combination with alt: M-a
220:   - a special keyname: Enter, Escape, PageUp, PageDown, Left, Down, Right, 
Up, Home, End, Backspace, F1 .. F12

-.-.

Add a comma (or \&) after "e.g." and "i.e.", or use English words
(man-pages(7)).
Abbreviation points should be protected against being interpreted as
an end of sentence, if they are not, and that independent of the
current place on the line.

168:it, i.e. the position is the cubic root of the linear sample

-.-.

Wrong distance between sentences.

  Separate the sentences and subordinate clauses; each begins on a new
line.  See man-pages(7) ("Conventions for source file layout") and
"info groff" ("Input Conventions").

  The best procedure is to always start a new sentence on a new line,
at least, if you are typing on a computer.

Remember coding: Only one command ("sentence") on each (logical) line.

E-mail: Easier to quote exactly the relevant lines.

Generally: Easier to edit the sentence.

Patches: Less unaffected text.

Search for two adjacent words is easier, when they belong to the same line,
and the same phrase.

  The amount of space between sentences in the output can then be
controlled with the ".ss" request.

N.B.

  The number of lines affected can be too large to be in the patch.

10:soundcard drivers. It supports multiple soundcards with multiple devices.
20:Select the soundcard to use, if you have more than one. Cards are
94:channel (or device, depending on your preferred terminology). You can
98:currently selected device. You can also use \fI+\fP or \fI\-\fP for the
99:same purpose. Both the left and right signals are affected. For
110:\fISPACE\fP enables recording for the current channel. If any other
112:disabled first. This only works for valid input channels, of course.
168:it, i.e. the position is the cubic root of the linear sample
220:   - a special keyname: Enter, Escape, PageUp, PageDown, Left, Down, Right, 
Up, Home, End, Backspace, F1 .. F12

-.-.

Split lines longer than 80 characters into two or more lines.
Appropriate break points are the end of a sentence and a subordinate
clause; after punctuation marks.

N.B.

  The number of lines affected can be too large to be in the patch.


Line 29, length 81

Select the starting view mode, either \fIplayback\fP, \fIcapture\fP or 
\fIall\fP.

Line 86, length 85

\fBalsamixer\fP recognizes the following keyboard commands to control the 
soundcard. 

Line 192, length 130

Valid values for \fIforeground\fP and \fIbackground\fP are: red, green, yellow, 
blue, magenta, cyan, white, black, none / default.

Line 194, length 91

Valid values for \fIattribute\fP are: bold, normal, reverse, underline, dim, 
italic, blink.

Line 207, length 104

If enabled (\fI1\fP), mixer controls can be changed by hovering over them and 
scrolling the mouse wheel.

Line 220, length 111

   - a special keyname: Enter, Escape, PageUp, PageDown, Left, Down, Right, Up, 
Home, End, Backspace, F1 .. F12

-.-.

Use \(en (en-dash) for a dash between space characters,
not a minus (\-) or a hyphen (-), except in the NAME section.

alsamixer.1:217:   - a single character
alsamixer.1:218:   - a combination with control: C-a
alsamixer.1:219:   - a combination with alt: M-a
alsamixer.1:220:   - a special keyname: Enter, Escape, PageUp, PageDown, Left, 
Down, Right, Up, Home, End, Backspace, F1 .. F12

-.-.

Protect a period (.) or an apostrophe (') with '\&' from becoming a
control character, if it could end up at the start of a line
(by splitting the line into more lines).

187:Comments start with '#'.
220:   - a special keyname: Enter, Escape, PageUp, PageDown, Left, Down, Right, 
Up, Home, End, Backspace, F1 .. F12

-.-.

Name of a manual is set in bold, the section in roman.
See man-pages(7).

391:arecord(1)

-.-.

Change a HYPHEN-MINUS (code 0x55, 2D) to a dash
(\-, minus) if it matches "[[:alph:]]-[[:alpha:]]" in the name of an
option).
Facilitates the copy and paste of an option in UTF-8 text.
Is not needed in ordinary words like "mother-in-law", that are not
copied and pasted to a command line (which needs ASCII code)

32:\fI\-B, \-\-black-background\fP

-.-.

Output from "test-groff -b -mandoc -rF0 -rHY=0 -K utf8 -t -ww -z ":

troff: backtrace: file '<stdin>':79
troff:<stdin>:79: warning: trailing space in the line
troff: backtrace: file '<stdin>':86
troff:<stdin>:86: warning: trailing space in the line
troff: backtrace: file '<stdin>':142
troff:<stdin>:142: warning: trailing space in the line
troff: backtrace: file '<stdin>':296
troff:<stdin>:296: warning: trailing space in the line
troff: backtrace: file '<stdin>':392
troff:<stdin>:392: warning: trailing space in the line

--- alsamixer.1 2024-06-11 14:20:35.165362104 +0000
+++ alsamixer.1.new     2024-06-11 22:05:25.914012508 +0000
@@ -7,7 +7,8 @@ alsamixer \- soundcard mixer for ALSA so
 
 .SH DESCRIPTION
 \fBalsamixer\fP is an ncurses mixer program for use with the ALSA
-soundcard drivers. It supports multiple soundcards with multiple devices.
+soundcard drivers.
+It supports multiple soundcards with multiple devices.
 
 .SH OPTIONS
 
@@ -17,8 +18,8 @@ Help: show available flags.
 
 .TP
 \fI\-c, \-\-card\fP <card number or identification>
-Select the soundcard to use, if you have more than one. Cards are
-numbered from 0 (the default).
+Select the soundcard to use, if you have more than one.
+Cards are numbered from 0 (the default).
 
 .TP
 \fI\-D, \-\-device\fP <device identification>
@@ -26,10 +27,11 @@ Select the mixer device to control.
 
 .TP
 \fI\-V, \-\-view\fP <mode>
-Select the starting view mode, either \fIplayback\fP, \fIcapture\fP or 
\fIall\fP.
+Select the starting view mode, either \fIplayback\fP, \fIcapture\fP or
+\fIall\fP.
 
 .TP
-\fI\-B, \-\-black-background\fP
+\fI\-B, \-\-black\-background\fP
 Use the black background color.
 
 .TP
@@ -73,17 +75,19 @@ item via up/down keys.
 \fBalsamixer\fP has three view modes: playback, capture and all.
 In the playback view, only the controls related with playback are shown.
 Similarly, only the controls for capture (recording) are shown in the capture
-view.  The all view mode shows all controls.  The current view mode is 
displayed
-in the top-left position together with the mixer name, etc.
+view.  The all view mode shows all controls.
+The current view mode is displayed in the top-left position together with
+the mixer name, etc.
 
-The default view mode is the playback view.  You can change it via 
-\fI-V\fP option.
+The default view mode is the playback view.  You can change it via
+\fI\-V\fP option.
 
 Each view mode can be switched via keyboard commands, too.
 See the next section.
 
 .SH KEYBOARD COMMANDS
-\fBalsamixer\fP recognizes the following keyboard commands to control the 
soundcard. 
+\fBalsamixer\fP recognizes the following keyboard commands to control the
+soundcard.
 Commands shown here in upper case can also be given in lower case.
 To be reminded of these keystrokes, hit the \fIh\fP key.
 
@@ -91,13 +95,14 @@ To be reminded of these keystrokes, hit
 General Controls
 
 The \fILeft\fP and \fIright arrow\fP keys are used to select the
-channel (or device, depending on your preferred terminology). You can
-also use \fIn\fP ("next") and \fIp\fP ("previous").
+channel (or device, depending on your preferred terminology).
+You can also use \fIn\fP ("next") and \fIp\fP ("previous").
 
 The \fIUp\fP and \fIDown Arrows\fP control the volume for the
-currently selected device. You can also use \fI+\fP or \fI\-\fP for the
-same purpose. Both the left and right signals are affected. For
-independent left and right control, see below.
+currently selected device.
+You can also use \fI+\fP or \fI\-\fP for the same purpose.
+Both the left and right signals are affected.
+For independent left and right control, see below.
  
 The \fIB\fP or \fI=\fP key adjusts the balance of volumes on left and
 right channels.
@@ -107,9 +112,10 @@ If the hardware supports it, you can
 mute left and right independently by using \fI,\fP (or \fI<\fP) and
 \fI.\fP (or \fI>\fP) respectively.
 
-\fISPACE\fP enables recording for the current channel. If any other
-channels have recording enabled, they will have their recording function
-disabled first. This only works for valid input channels, of course.
+\fISPACE\fP enables recording for the current channel.
+If any other channels have recording enabled,
+they will have their recording function disabled first.
+This only works for valid input channels, of course.
 
 \fIL\fP re-draws the screen.
 
@@ -137,9 +143,9 @@ Quick Volume Changes
 You can also control left & right levels for the current channel
 independently, as follows:
 
-[\fIQ\fP | \fIW\fP | \fIE\fP ]  -- turn UP [ left | both | right ]
+[\fIQ\fP | \fIW\fP | \fIE\fP ] \(en turn UP [ left | both | right ]
 
-[\fIZ\fP | \fIX\fP | \fIC\fP ] -- turn DOWN [ left | both | right ]   
+[\fIZ\fP | \fIX\fP | \fIC\fP ] \(en turn DOWN [ left | both | right ]
 
 If the currently selected mixer channel is not a stereo channel, then
 all UP keys will work like \fIW\fP, and all DOWN keys will work like \fIX\fP.
@@ -163,9 +169,10 @@ since it's regarded as a prefix key.
 
 .SH VOLUME MAPPING
 In \fBalsamixer\fP, the volume is mapped to a value that is more natural
-for a human ear.  The mapping is designed so that the position in the
-interval is proportional to the volume as a human ear would perceive
-it, i.e. the position is the cubic root of the linear sample
+for a human ear.
+The mapping is designed so that the position in the interval is proportional
+to the volume as a human ear would perceive it,
+i.e., the position is the cubic root of the linear sample
 multiplication factor.  For controls with a small range (24 dB or
 less), the mapping is linear in the dB values so that each step has
 the same size visually.
@@ -189,9 +196,11 @@ Comments start with '#'.
 .TP
 \fBcolor\fP \fIelement\fP \fIforeground\fP \fIbackground\fP 
[\fIattribute...\fP]
 
-Valid values for \fIforeground\fP and \fIbackground\fP are: red, green, 
yellow, blue, magenta, cyan, white, black, none / default.
+Valid values for \fIforeground\fP and \fIbackground\fP are:
+red, green, yellow, blue, magenta, cyan, white, black, none / default.
 
-Valid values for \fIattribute\fP are: bold, normal, reverse, underline, dim, 
italic, blink.
+Valid values for \fIattribute\fP are:
+bold, normal, reverse, underline, dim, italic, blink.
 
 See section \fBTHEME ELEMENTS\fP for a list of \fIelements\fP.
 
@@ -204,7 +213,9 @@ Set the mouse wheel step to \fI<N>\fP
 
 \fBmouse_wheel_focuses_control\fP \fI0|1\fP
 
-If enabled (\fI1\fP), mixer controls can be changed by hovering over them and 
scrolling the mouse wheel.
+If enabled (\fI1\fP),
+mixer controls can be changed by hovering over them
+and scrolling the mouse wheel.
 
 \fBbackground\fP \fIcolor\fP
 
@@ -214,12 +225,22 @@ Set the default background color
 \fBbind\fP \fIkey_definition\fP \fIcommand\fP
 
 A \fIkey_definition\fP may be:
-   - a single character
-   - a combination with control: C-a
-   - a combination with alt: M-a
-   - a special keyname: Enter, Escape, PageUp, PageDown, Left, Down, Right, 
Up, Home, End, Backspace, F1 .. F12
-
+.RS 7m
+.PD 0
+.IP \(en 2m
+a single character
+.IP \(en 2m
+a combination with control: C-a
+.IP \(en 2m
+a combination with alt: M-a
+.IP \(en 2m
+a special keyname: Enter, Escape, PageUp, PageDown, Left, Down, Right,
+Up, Home, End, Backspace, F1 \&..\& F12
+.PD 0
+.IP "" 0m
 See section \fBCOMMANDS\fP for a list of \fIcommands\fP.
+.RE
+.PD
 
 .SS COMMANDS
 
@@ -293,7 +314,7 @@ Change volume of current control to \fI<
 
 .TP
 \fImixer_control_up_<N>\fP[\fI_left\fP|\fI_right\fP]
-Increase volume of current control by \fI<N>\fP percent. 
+Increase volume of current control by \fI<N>\fP percent.
 
 .TP
 \fImixer_control_down_<N>\fP[\fI_left\fP|\fI_right\fP]
@@ -385,11 +406,10 @@ Show system information
 \fImenu_selected\fP Color used for selected entry in menu
 
 .SH SEE ALSO
-\fB
-amixer(1),
-aplay(1),
-arecord(1)
-\fP
+
+.BR amixer (1),
+.BR aplay (1),
+.BR arecord (1)
 
 .SH AUTHOR
 .B alsamixer

Reply via email to