bugGNU roff - Bugs: bug #53788, afmtodit.1.man: Split long strings...

 
 

bug #53788: afmtodit.1.man: Split long strings to avoid repetition and a warning

Submitter:  Bjarni Ingi Gislason <bjarniig>
Submitted:  Sun 29 Apr 2018 09:35:26 PM UTC
   
 
Category:  Font devps Severity:  2 - Minor
Item Group:  Documentation Status:  Fixed
Privacy:  Public Assigned to:  gbranden
Open/Closed:  Closed Planned Release:  1.22.4
* Mandatory Fields

Add a New Comment Rich Markup
   

Wed 15 Jun 2022 02:29:02 PM UTC, comment #2: 

I applied my own fixes, preserving the textual replacement of special sequences like @FONTDIR@ with the values of Make macros in man page sources.


commit 1816eac38dc831030ec8a203e114ed9a28776a4f
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
Date:   Mon Nov 5 04:55:23 2018 -0500

    afmtodit(1): Make style fixes.

            * src/utils/afmtodit/afmtodit.1.man:
              + Use hyphens instead of underscores in option argument names;
                they are prose, not C identifiers.
              + Capitalize "Perl" except when referring to its man page.
              + Mark up short character literals with single quotation
                marks, not bold (e.g., '#', '\N', '-1').
              + Fix direct object confusion: "searched" -> "searched for".
              + Mark up file/path names in italics, not with quotation
                marks.
              + Clarify: "troff" -> "a roff document".
              + Clarify recognition of glyph variant names.
              + Mark up section titles and very short examples with double
                quotation marks.
              + Use comma before "which" in nonrestrictive dependent clause;
                see <https://www.grammarly.com/blog/comma-before-which/>.
              + Move notice of optional whitespace between options and their
                arguments from Synopsis to Options section.
              + Capitalize "AFM" when used as an initialism.
              + Change the one occurrence of "PS" to PostScript; the full
                term is ubiquitous throughout the page.
              + Tighten descriptions of -k and -n options.
              + Consistently use the phrase "monospaced (constant-width)",
                making their synonymy clear, instead of using one or the
                other variously.
              + Clarify that the -v option exits the program without
                performing its usual operations.
              + Use .EX/.EE to mark up example of AFM file contents.
              + Add hyphenless discretionary breaks to filename components
                (i.e., after each "/").  Thanks to Bjarni Ingi Gislason for
                noticing the problem here.  Fixes
                <https://savannah.gnu.org/bugs/index.php?53788>.
              + Cite groff Texinfo manual more completely in "See Also"
                section.  Tell readers how to load the referenced node.
              + Add cross-reference to gropdf(1) to "See Also" section.


G. Branden Robinson <gbranden>
Group administrator
Mon 05 Nov 2018 10:43:41 AM UTC, comment #1: 

Fixed in 1816eac38dc831030ec8a203e114ed9a28776a4f.

G. Branden Robinson <gbranden>
Group administrator
Sun 29 Apr 2018 09:35:26 PM UTC, original submission:  


From 3bd1dc59ec4bef578969e1acf754cb6a58c830ba Mon Sep 17 00:00:00 2001
From: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
Date: Sun, 29 Apr 2018 21:29:16 +0000
Subject: [PATCH] afmtodit.1.man: Split long strings to avoid repetition and a
 warning

  Warning from "test-groff":

troff: afmtodit.1:363: warning [p 3, 4.2i, div 'an-div', 0.0i]: cannot adjust line
.B /usr/local/share/groff/1.22.3.real.441-d6ec5-dirty/font/devps/generate/textmap

###

  Remove the internal macro "Tp" as it is no longer needed.
A long (repeated) string (path) was separated from the rest (file name).

  Add '\:' to a long (when expanded) single string.

  Split long strings with the same prefix (path) into

1) the prefix (path)

2) the rest,

  to avoid unnecessary repetitions (and warning).

Signed-off-by: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
---
 src/utils/afmtodit/afmtodit.1.man | 27 ++++++++++-----------------
 1 file changed, 10 insertions(+), 17 deletions(-)

diff --git a/src/utils/afmtodit/afmtodit.1.man b/src/utils/afmtodit/afmtodit.1.man
index c7c1b691..1398acc0 100644
--- a/src/utils/afmtodit/afmtodit.1.man
+++ b/src/utils/afmtodit/afmtodit.1.man
@@ -25,16 +25,6 @@ afmtodit \- create font files for use with groff \-Tps and \-Tpdf
 .
 .
 .\" ====================================================================
-.\" Definitions
-.
-.\" Like TP, but if specified indent is more than half
-.\" the current line-length - indent, use the default indent.
-.de Tp
-.  ie \\n(.$=0:((0\\$1)*2u>(\\n(.lu-\\n(.iu)) .TP
-.  el .TP "\\$1"
-..
-.
-.\" ====================================================================
 .SH SYNOPSIS
 .\" ====================================================================
 .
@@ -157,7 +147,7 @@ option is used.
 .LP
 If there is a downloadable font file for the font, it may be listed in
 the file
-.BR @FONTDIR@/devps/download ;
+.BR @FONTDIR@/\:devps/\:download ;
 see
 .BR grops (@MAN1EXT@).
 .
@@ -342,25 +332,28 @@ Don't use the built-in Adobe Glyph List.
 .SH FILES
 .\" ====================================================================
 .
-.Tp \w'\fB@FONTDIR@/devps/download'u+2n
-.B @FONTDIR@/devps/DESC
+.LP
+In the directory
+.BR @FONTDIR@/devps/ :
+.TP \w'download'u+2n
+.B DESC
 Device description file.
 .
 .TP
-.BI @FONTDIR@/devps/ F
+.I F
 Font description file for font
 .IR F .
 .
 .TP
-.B @FONTDIR@/devps/download
+.B download
 List of downloadable fonts.
 .
 .TP
-.B @FONTDIR@/devps/text.enc
+.B text.enc
 Encoding used for text fonts.
 .
 .TP
-.B @FONTDIR@/devps/generate/textmap
+.B generate/textmap
 Standard mapping.
 .
 .
--
2.17.0


Bjarni Ingi Gislason <bjarniig>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by gbranden (Posted a comment)
  • -email is unavailable- added by bjarniig (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-06-15 gbranden CategoryNone Font devps
        Summary[PATCH] afmtodit.1.man: Split long strings to avoid repetition and a warning afmtodit.1.man: Split long strings to avoid repetition and a warning
    2018-11-05 gbranden Severity3 - Normal 2 - Minor
        StatusNone Fixed
        Assigned toNone gbranden
        Open/ClosedOpen Closed
        Planned ReleaseNone 1.22.4

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code