unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#5568: Man-follow-manual-reference vs. perl man pages
@ 2010-02-12  6:56 jidanni
  2010-02-12 19:19 ` Juri Linkov
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: jidanni @ 2010-02-12  6:56 UTC (permalink / raw)
  To: 5568

Many man pages have SEE ALSOs like

  SEE ALSO
         XML::Parser::Lite.
  perl v5.10.0 2009-08-23 XML::Parser::Lite::Tree(3pm)

However Man-follow-manual-reference can't figure out that kind of SEE
ALSO item.







^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#5568: Man-follow-manual-reference vs. perl man pages
  2010-02-12  6:56 bug#5568: Man-follow-manual-reference vs. perl man pages jidanni
@ 2010-02-12 19:19 ` Juri Linkov
  2010-02-13 20:19 ` jidanni
  2010-02-14  1:08 ` jidanni
  2 siblings, 0 replies; 5+ messages in thread
From: Juri Linkov @ 2010-02-12 19:19 UTC (permalink / raw)
  To: jidanni; +Cc: 5568

> Many man pages have SEE ALSOs like
>
>   SEE ALSO
>          XML::Parser::Lite.
>   perl v5.10.0 2009-08-23 XML::Parser::Lite::Tree(3pm)
>
> However Man-follow-manual-reference can't figure out that kind of
> SEE ALSO item.

The references in this SEE ALSO section are in a non-standard format.
A reference should be a word followed by the section name in parentheses.
So these man pages should write references in the format
"XML::Parser::Lite(3pm)".

Of course, you can get what you want with the following patch:

=== modified file 'lisp/man.el'
--- lisp/man.el	2010-02-11 20:57:10 +0000
+++ lisp/man.el	2010-02-12 19:18:50 +0000
@@ -1135,7 +1135,7 @@ (defun Man-highlight-references (&option
 	(Man-highlight-references0 nil Man-apropos-regexp 1
 				   'Man-default-man-entry
 				   (or xref-man-type 'Man-xref-man-page)))
-    (Man-highlight-references0 Man-see-also-regexp Man-reference-regexp 1
+    (Man-highlight-references0 Man-see-also-regexp Man-hyphenated-reference-regexp 1
 			       'Man-default-man-entry
 			       (or xref-man-type 'Man-xref-man-page))
     (Man-highlight-references0 Man-synopsis-regexp Man-header-regexp 0 2

But it will also highlight every word in those SEE ALSO sections
that have lengthy text in several paragraphs.  Look for example
`M-x man XML::Twig RET' - there are 60 lines in the SEE ALSO section
where all words will be highlighted as a reference!

-- 
Juri Linkov
http://www.jurta.org/emacs/






^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#5568: Man-follow-manual-reference vs. perl man pages
  2010-02-12  6:56 bug#5568: Man-follow-manual-reference vs. perl man pages jidanni
  2010-02-12 19:19 ` Juri Linkov
@ 2010-02-13 20:19 ` jidanni
  2010-02-14  0:30   ` Juri Linkov
  2010-02-14  1:08 ` jidanni
  2 siblings, 1 reply; 5+ messages in thread
From: jidanni @ 2010-02-13 20:19 UTC (permalink / raw)
  To: juri; +Cc: 5568

JL> Of course, you can get what you want with the following patch
Well I sure hope you commit it.






^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#5568: Man-follow-manual-reference vs. perl man pages
  2010-02-13 20:19 ` jidanni
@ 2010-02-14  0:30   ` Juri Linkov
  0 siblings, 0 replies; 5+ messages in thread
From: Juri Linkov @ 2010-02-14  0:30 UTC (permalink / raw)
  To: jidanni; +Cc: 5568

[-- Attachment #1: Type: text/plain, Size: 405 bytes --]

> JL> Of course, you can get what you want with the following patch
>
> Well I sure hope you commit it.

Sorry, no.  Please see on the screenshot below for `M-x man XML::Twig RET',
how every word becomes a reference when we try to ignore the requirement
of presence of a manpage section within parentheses.

BTW, I think we should handle HTTP links because they have a definite regexp
that we can match.


[-- Attachment #2: man-see-also.png --]
[-- Type: image/png, Size: 2488 bytes --]

[-- Attachment #3: Type: text/plain, Size: 45 bytes --]


-- 
Juri Linkov
http://www.jurta.org/emacs/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#5568: Man-follow-manual-reference vs. perl man pages
  2010-02-12  6:56 bug#5568: Man-follow-manual-reference vs. perl man pages jidanni
  2010-02-12 19:19 ` Juri Linkov
  2010-02-13 20:19 ` jidanni
@ 2010-02-14  1:08 ` jidanni
  2 siblings, 0 replies; 5+ messages in thread
From: jidanni @ 2010-02-14  1:08 UTC (permalink / raw)
  To: juri; +Cc: 5568

JL> BTW, I think we should handle HTTP links because they have a definite regexp
JL> that we can match.
Hmm, maybe anything with :: in them too. However I suppose those perl guys
can't be bothered to put the
$ man encode|sed 's/ .*//;q'
Encode(3perl)
or some other hint there in the SEE ALSOs. I would remind them but I'm
banned for life from mailing *@perl.org because of my crabby personality
or something.






^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-02-14  1:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-02-12  6:56 bug#5568: Man-follow-manual-reference vs. perl man pages jidanni
2010-02-12 19:19 ` Juri Linkov
2010-02-13 20:19 ` jidanni
2010-02-14  0:30   ` Juri Linkov
2010-02-14  1:08 ` jidanni

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).