public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
From: "Alejandro Colomar (man-pages)" <alx.manpages@gmail.com>
To: "G. Branden Robinson" <g.branden.robinson@gmail.com>,
	Jeremy Kerr <jk@codeconstruct.com.au>
Cc: Michael Kerrisk <mtk.manpages@gmail.com>, linux-man@vger.kernel.org
Subject: Re: [PATCH] mctp.7: Add man page for Linux MCTP support
Date: Mon, 18 Oct 2021 09:16:07 +0200	[thread overview]
Message-ID: <c454d2ed-a097-7a42-5300-e4c9775da421@gmail.com> (raw)
In-Reply-To: <20211018055719.i3rjz2brwqsygqrp@localhost.localdomain>

Hi Branden,

On 10/18/21 7:57 AM, G. Branden Robinson wrote:
> Hi Jeremy,
> 
> At 2021-10-18T13:05:25+0800, Jeremy Kerr wrote:
>>>> +Addressing data is passed in socket system calls through
>>>> +.B struct sockaddr\_mctp
>>>
>>> That escape is unnecessary.  Did you see it in another page perhaps?
>>
>> I thought I'd seen some odd line-breaks at the underscore, but can't
>> replicate that now. Will remove.
> 
> My groff experiments don't reveal _ or \_ as being permissible
> break points[1].  However, the structure tag _could_ break like this:
> 
> sock‐addr_mctp
> 
> In other words (if my UTF-8 gets mangled), after "sock".
> 
> To prevent that, you can prefix the word with the hyphenation control
> escape sequence, "\%".  This escape sequence is extremely portable; it
> dates back to 1970s AT&T troff.

Hmm, this is one of the few points we disagree, it seems :)

As I said previously, I think this uglyfies code too much, for something 
that I think should be default (it is rarer to want break points at 
highlighted words than not wanting them).  But, to try to confirm my 
thoughts, I'll accept using this in the man-pages and see what happens 
(maybe some day, a winter day it shall be, you'll wake up and see a cold 
commit reaping them all :p)

> 
> Further, if you wanted to prevent breaking between the "struct" keyword
> and the structure tag, you could use a nonbreaking adjustable space
> escape sequence, "\~".  While this was a groff innovation (about 30
> years ago), it's been adopted by Heirloom Doctools troff and mandoc(1),
> so it's pretty portable to systems likely to install the Linux
> man-pages.

Ah yes, I should have spotted that one :p

> 
> So we might write
> 
> .B struct\~\%sockaddr_mctp

Okay.

> 
> for instance in running text (that is, in sentences).  (When filling is
> off, as in code examples and the synopses of most pages documenting C
> interfaces, neither of these escape sequences is necessary; unfilled
> lines are neither automatically hyphenated nor adjusted.)
> 
> Just a typographical FYI.  I know these issues sometimes frustrate
> people.
> 
> Regards, > Branden

Thanks!

Alex

> 
> [1] I'm using groff's defaults.  It's possible to change the groff
>      "hyphenation code" of any character, but few do so.
> 


-- 
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/

  reply	other threads:[~2021-10-18  7:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-14  7:05 [PATCH] mctp.7: Add man page for Linux MCTP support Jeremy Kerr
2021-10-17 18:49 ` Alejandro Colomar (man-pages)
2021-10-18  5:05   ` Jeremy Kerr
2021-10-18  5:57     ` G. Branden Robinson
2021-10-18  7:16       ` Alejandro Colomar (man-pages) [this message]
2021-10-18  7:53         ` Alejandro Colomar (man-pages)
2021-11-22  1:09           ` Suppressing hyphenation (was: [PATCH] mctp.7: Add man page for Linux MCTP support) G. Branden Robinson
2021-10-18  6:59     ` [PATCH] mctp.7: Add man page for Linux MCTP support Alejandro Colomar (man-pages)
2021-10-18  7:46   ` Alejandro Colomar (man-pages)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c454d2ed-a097-7a42-5300-e4c9775da421@gmail.com \
    --to=alx.manpages@gmail.com \
    --cc=g.branden.robinson@gmail.com \
    --cc=jk@codeconstruct.com.au \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox