bugGNU roff - Bugs: bug #63764, tmac/an.tmac: translate font CW to...

 
 

bug #63764: tmac/an.tmac: translate font CW to R in nroff mode

Submitter:  Bjarni Ingi Gislason <bjarniig>
Submitted:  Sun 05 Feb 2023 09:41:27 PM UTC
   
 
Category:  Macro package man Severity:  1 - Wish
Item Group:  Warning/Suspicious behaviour Status:  Duplicate
Privacy:  Public Assigned to:  gbranden
Open/Closed:  Closed Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 30 Mar 2023 05:40:40 PM UTC, comment #3: 

This is effectively a duplicate of bug #51362.

G. Branden Robinson <gbranden>
Group administrator
Mon 06 Feb 2023 06:14:30 PM UTC, comment #2: 

I am however doing the following.


commit 35c2fea2dca9ae71fb59ad045f32cf279881b0f8 (HEAD -> master)
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
Date:   Mon Feb 6 12:11:43 2023 -0600

    tmac/{man,mdoc}.local: Add "CW" font advice.

    Add commented-out technique for coping with this unportable font name.

    Prompted by Bjarni Ingi Gislason in
    <https://savannah.gnu.org/bugs/?63768>.

diff --git a/tmac/man.local b/tmac/man.local
index da7cd6c9c..ed5706b41 100644
--- a/tmac/man.local
+++ b/tmac/man.local
@@ -8,6 +8,12 @@
 .  if !r U \
 .    nr U 0
 .\"
+.\" "CW" is not a portable font name, but some man pages use it anyway.
+.\" Uncomment this to suppress warnings produced by such pages.  This
+.\" test remaps the font to roman ("R") on nroff (terminal) devices. You
+.\" might prefer to remap it to bold ("B") instead.
+.\" .if n .ftr CW R
+.\"
 .\" Local Variables:
 .\" mode: nroff
 .\" fill-column: 72
diff --git a/tmac/mdoc.local b/tmac/mdoc.local
index b219285d1..94688aba0 100644
--- a/tmac/mdoc.local
+++ b/tmac/mdoc.local
@@ -2,6 +2,12 @@
 .\"
 .\" Put local modifications to groff_mdoc(7)'s behavior here.
 .\"
+.\" "CW" is not a portable font name, but some man pages use it anyway.
+.\" Uncomment this to suppress warnings produced by such pages.  This
+.\" test remaps the font to roman ("R") on nroff (terminal) devices. You
+.\" might prefer to remap it to bold ("B") instead.
+.\" .if n .ftr CW R
+.\"
 .\" Local Variables:
 .\" mode: nroff
 .\" fill-column: 72


G. Branden Robinson <gbranden>
Group administrator
Mon 06 Feb 2023 05:56:59 PM UTC, comment #1: 

I'm rejecting this.

The font name "CW" is not generally portable across *roff implementations.

CW is not a name we use except on the "dvi" device.

The name "CW" doesn't unambiguously identify a font on terminals (of course), nor on HTML, PostScript, PDF, Canon LBP, or LaserJet 4 device.

People can perform the font remapping in their man.local files.


.if !'\*(.T'dvi' .ftr CW R


People might also prefer to remap "CW" to "B" instead of "R", so that it stands out.  I found this useful in the "ms.ms" document, for example.

>   So add
>
> .if n \{\
> .  ftr CB B
> .  ftr CBI BI
> .  ftr CI I
> .  ftr CR R
> .  ftr CW R
> .\}
>
> to "tmac/an.tmac".


I get the feeling you haven't looked at groff's "an.tmac" lately.


.\" Map monospaced fonts to standard styles for groff's nroff devices.
.if n \{\
.  ftr CR R
.  ftr CI I
.  ftr CB B
.  ftr CBI BI
.\}


...and for what it's worth, here's "mdoc/doc-nroff".


.\" Map monospaced fonts to standard styles.
.ftr CR R
.ftr CI I
.ftr CB B
.ftr CBI BI


G. Branden Robinson <gbranden>
Group administrator
Sun 05 Feb 2023 09:41:27 PM UTC, original submission:  

Subject: tmac/an.tmac: translate font CW to R in nroff mode

  Many manuals use the 'CW' font, which in nroff mode causes warnings
of type

cannot select font 'CW'

  An example is ascii(7).

  So add

.if n \{\
.  ftr CB B
.  ftr CBI BI
.  ftr CI I
.  ftr CR R
.  ftr CW R
.\}

to "tmac/an.tmac".

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 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2023-03-30 gbranden StatusRejected Duplicate
    2023-02-06 gbranden Open/ClosedOpen Closed
    2023-02-06 gbranden Severity3 - Normal 1 - Wish
        StatusNone Rejected
        Assigned toNone gbranden

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code