develooper Front page | perl.perl5.porters | Postings from May 2008

[perl #53910] pod2man loses =head2 starting ' or .

From:
Bram via RT
Date:
May 17, 2008 18:54
Subject:
[perl #53910] pod2man loses =head2 starting ' or .
Message ID:
rt-3.6.HEAD-11257-1211027825-1495.53910-15-0@perl.org
On Thu May 08 18:08:42 2008, kryde wrote:
> The file foo.pod below processed with
> 
> 	pod2man foo.pod | man -l -
> 
> produces
> 
> 	Some text.
> 
> 	Some text.
> 
> where I hoped it would include the two =head2 lines as headings.
> 
> I noticed this in the docs of Gtk2::Ex::DBI (from cpan) where the
> "'destroy' method" subheading under the BUGS section doesn't come out.
> 
> 
> I think the troff generated by pod2man ends up with the heading text
>    at
> the start of a line, so a leading . or ' is interpreted as a request.
> Groff in compatibility mode ignores unknown requests apparently, but
>    you
> can see errors with say
> 
> 	pod2man foo.pod | groff -man >/dev/null
> 
> giving
> 
> 	<standard input>:140: warning: `destroy'' not defined (probable
>    missing space after `de')
> 	<standard input>:143: warning: `deb' not defined (probable 
missing
>    space after `de')
> 
> 
> I think pod2man's .Sh macro can avoid the problem with a \& zero-width
> space, per diff below.  This would be like what groff's .SH does (in
> an-old.tmac).
> 
> Although .Sh has \fB as the start of the line, apparently troff, and
> that includes groff in compatibility mode, will "see through" such a
> font setting and consider what follows to still be at the start of the
> line.  The groff manual under "Implementation Differences" has a note
>    on
> that.
> 
> 
> [Please do not change anything below this line]
> -----------------------------------------------------------------

Thank you for your bug report and patch.

If you have any further bug reports and/or patches with regards to 
Pod::Man then please submit them to http://rt.cpan.org/Public/Dist/
Display.html?Name=podlators

Pod::Man is a dual-lived module meaning that it is both in the CORE and 
on CPAN.
Maintance for these modules, normally, gets done on CPAN after which 
they are synced with the core.

Your bug report and patch in the CPAN RT queue: http://rt.cpan.org/
Public/Bug/Display.html?id=35876


Kind regards,

Bram




nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About