Re: grohtml: confused about constant-width font handling
"G. Branden Robinson" <[email protected]>
| Newsgroups | gmane.comp.printing.groff.general |
|---|---|
| Message-ID | <20260120174909.etetlemzfnfxglnk@illithid> |
At 2026-01-20T16:18:11+0000, Colin Watson wrote: > Further confusion with groff 1.23.0. ".nf" then ".ft C" results in > <pre>. Taken together, that almost makes sense. But only almost. This was a bad idea because disabling filling does not have the same semantics as HTML's <pre>, even if you ignore font selection issues. (At which point someone says "what? there are semantics other than the font selection?" Whereupon grizzled old text formatting system veterans smile wanly and nod.) When filling is disabled, all *roff formatters still: * apply inter-sentence spacing (groff: if configured); * interpret control lines; and * interpret escape sequences. They also still honor character translations, which isn't very "<pre>" or "\verb". Fortunately, only a madman would use character translations in a man page. People need to not get carried away with what "no-fill" or "disabling filling" means. It *roff systems, it is limited to that and its logical consequences (no automatic breaking, no hyphenation, no adjustment). > ".ft C" on its own does not result in <tt> even though you might think > it would based on the behaviour in combination with ".nf". ".ft CR" > has no effect with or without ".nf". > > I can see why the author of this page decided to use ".ft C" for the > HTML device even though it doesn't seem to actually make any sense, > since it _works_ in 1.23.0 As far as I know, that idiom wasn't _documented_ anywhere. > - but doesn't any more. What's going on? The font name "C" is not portable and is now deprecated. https://cgit.git.savannah.gnu.org/cgit/groff.git/tree/NEWS?h=1.24.0.rc1#n366 Regards, Branden
signature.asc
(application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEh3PWHWjjDgcrENwa0Z6cfXEmbc4FAmlvwA4ACgkQ0Z6cfXEm bc6mCBAAqUHCmNzTmnFu7F1MyTyRkstmyGKz/F04bnBFlQedi3Kzwzf6QjV2uGPG dHvy+tg4YTMpk5XTtMO+17ciolgNtLbZBYjwlGTHmQM5bNyIwBxUfdbUSCm5pKgp ewh4S+fTGolfvLPAukvCQKXDtRynsUUVpka4fVf1lhvTJBOo8dpLrtrfTTxeQz86 MFwftqC8krJ7X6Kvh/5zd4Pj1GjinIkXUYW4FTMo0PC349PTj4y5Jbrr9HUZ/Ff7 16uHfze2AK0lqIPvo5gSgC09r+ozQzLS+bsAd0JJD3qid7bTnsV5txgmxXcNEqiy 1bTtJdSkOXxo++WvxorOtN7XvZUccb6xTu8vkRw1G4TAS4xUB+AhVjrHaEXwzVgN Wt9CUZ6xZroUFE5x1F0YwIRf7Y3Pn5bXem8Bu2MiEPneoagW71MghdRHVXBoozdw m9q7ef34/7ZyVyxUEJzx8YyTe0dBpko9XXIncpgV025vnathgTlGpKyun+11n+Jz yPHDu0LeMQ7fH0x39GCaR9GFK5VnRIMorh/pcZbBIMRdrFSxxFSc7dfuDtLUX6iN PbJ0pIu+jiIh2bWdZyQgc+r2CdX3AU6vS5Lx+ZTLnBM5A3huKhb+Bbf6CrIz39hm 8PrkOJot53kZx79ErUra8Iwh999LMYHoOelT0jnOz5NzrtpWfzw= =bxm3 -----END PGP SIGNATURE-----