0

What is the proper syntax for adding a dot that is not bold after a word in bold?

I need to write the following sentense without the dot in bold

word_in_bold. Other sentence

But

.B word_in_bold
. Other sentence

does not generate "Other sentence".

2

You can use macros which alternate font styles:

.BR bold .

will produce

bold.

There are other variants, .BI, .IR... man(7) has the details.

2

Typically for mdoc(7) macros one places the punctuation after the term

Lorem ipsum dolor sit
.B amet ,
consectetur adipiscing
.B elit ,
sed do eiusmod tempor incididunt ut labore et dolore magna
.B aliqua .

(Though, not all macros may support this.) To avoid the spaces or otherwise random vanishing of the successive punctuation, a quick review of existing usages

find /usr/src -name "*.1" -exec fgrep ".B " {} + 2>/dev/null

on OpenBSD revealed \c and of course one cannot put . alone at the beginning of a line:

Lorem ipsum dolor sit
.B amet\c
, consectetur adipiscing
.B elit\c
, sed do eiusmod tempor incididunt ut labore et dolore magna
.B aliqua\c
\&.
1
  • I don't want the dot to be bold. Any idea? – user123456 Oct 10 '16 at 17:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.