groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Man page customization after 1.23?


From: Nate Bargmann
Subject: Re: Man page customization after 1.23?
Date: Thu, 3 Aug 2023 18:56:54 -0500

* On 2023 08 Jul 18:22 -0500, G. Branden Robinson wrote:
> Hi Nate,

I had some time and inclination to experiment today on my Arch laptop.

> At 2023-07-08T18:02:34-0500, Nate Bargmann wrote:
> > * On 2023 08 Jul 17:22 -0500, Ronan Pigott via wrote:
> > > Ok. For now I've decided to export MANROFFOPT="-c" along with MANPAGER.
> 
> Shouldn't this be MANROFFOPT="-P -c"?

Probably if one is being pedantic but plain '-c' works as groff(1) shows
it as a transparent option that disables color output, presumably no
matter which output driver will be called.

> If I do _this_, by contrast:
> 
> $ MANROFFOPT="-P -i" man man
> 
> I get man(1)'s own man page using real italics in my xterm.

As it does on Arch with 1.23.  On the console the text is rendered as
green on black, of course no italics there.

> > Thanks for that tip, Ronan.  I just updated my Arch VM and Groff 1.23
> > was installed and bold text was shown as emboldened bright white but
> > Italics were simply underlined.  Exporting that option results in my man
> > pages being shown as before with Groff <= 1.22.4 n and with an
> > additional side effect that the page name on the first and last lines on
> > the screen might be shown with my chosen color for Italics and
> > Italicized (not all pages show in that manner).
> 
> Just keep in mind that other output drivers don't recognize '-c' (or
> '-i' for that matter), so if you ever use man(1)'s '-T' option to format
> for a non-terminal device, you will get complaints.
> 
> And if you say you never do that, I will cry, but will understand.

Rarely, but prepending the command as:

MANROFFOPT='' man -Tpdf man > man_1.pdf

seems to work as expected, at least on my Arch.  However, I don't see
that OSC 8 links work in evince.  Hmmm.

Now, for the *real* reason of my reply.

Are there plans to give users access to coloring the various text styles
when grotty is set to generate SGR output?  Right now only the -i option
is available.  The reason I ask is that even though italics catch my eye
in a PDF or on the printed page, they seem to slip by when mixed with
normal text in a terminal.  Perhaps that is mostly because I've gotten
used to man pages on the display having such emphasized text in color or
my preferred Gnome Terminal doesn't stylize the characters enough.  More
than likely it's a matter of training.

As noted above, italicized text on the console is colored green on black
which I presume is a choice of grotty, but perhaps it is a function of
the console hardware driver.

- Nate

-- 
"The optimist proclaims that we live in the best of all
possible worlds.  The pessimist fears this is true."
Web: https://www.n0nb.us
Projects: https://github.com/N0NB
GPG fingerprint: 82D6 4F6B 0E67 CD41 F689 BBA6 FB2C 5130 D55A 8819

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]