From: Stephen Berman <stephen.berman@gmx.net>
To: 14717@debbugs.gnu.org
Subject: bug#14717: 24.3.50; Info-try-follow-nearest-node misses some footnotes
Date: Tue, 25 Jun 2013 20:34:53 +0200 [thread overview]
Message-ID: <87vc52599u.fsf@rosalinde.fritz.box> (raw)
0. emacs -Q
1. Type `C-h i m Elisp RET m Using Interactive RET TAB TAB TAB' to put
point on the left parent of the reference mark for footnote (1) in
this node.
2. Type RET, expecting to jump to the footnote, but instead:
=> user-error: No such node or anchor: It may be a string; its contents
are a sequence of elements
The reason is that in Info-try-follow-nearest-node the search for a node
name succeeds, so it never gets to the footnote search, but the matching
string is not a node name, so user-error is signalled. The following
patch makes the footnote search and hence jumping to the footnote in
that node succeed, but I'll defer to the judgment of the Info or regexp
gurus as to whether it's the best fix.
=== modified file 'lisp/info.el'
*** lisp/info.el 2013-05-27 22:42:11 +0000
--- lisp/info.el 2013-06-25 18:24:56 +0000
***************
*** 3870,3892 ****
((setq node (Info-get-token (point) "\\*note[ \n\t]+"
"\\*note[ \n\t]+\\([^:]*\\):\\(:\\|[ \n\t]*(\\)?"))
(Info-follow-reference node fork))
- ;; menu item: node name
- ((setq node (Info-get-token (point) "\\* +" "\\* +\\([^:]*\\)::"))
- (Info-goto-node node fork))
- ;; menu item: node name or index entry
- ((Info-get-token (point) "\\* +" "\\* +\\(.*\\): ")
- (beginning-of-line)
- (forward-char 2)
- (setq node (Info-extract-menu-node-name nil (Info-index-node)))
- (Info-goto-node node fork))
- ((setq node (Info-get-token (point) "Up: " "Up: \\([^,\n\t]*\\)"))
- (Info-goto-node node fork))
- ((setq node (Info-get-token (point) "Next: " "Next: \\([^,\n\t]*\\)"))
- (Info-goto-node node fork))
- ((setq node (Info-get-token (point) "File: " "File: \\([^,\n\t]*\\)"))
- (Info-goto-node "Top" fork))
- ((setq node (Info-get-token (point) "Prev: " "Prev: \\([^,\n\t]*\\)"))
- (Info-goto-node node fork))
;; footnote
((setq node (Info-get-token (point) "(" "\\(([0-9]+)\\)"))
(let ((old-point (point)) new-point)
--- 3870,3875 ----
***************
*** 3904,3910 ****
(progn
(goto-char new-point)
(setq node t))
! (setq node nil)))))
node))
(defun Info-mouse-follow-link (click)
--- 3887,3910 ----
(progn
(goto-char new-point)
(setq node t))
! (setq node nil))))
! ;; menu item: node name
! ((setq node (Info-get-token (point) "\\* +" "\\* +\\([^:]*\\)::"))
! (Info-goto-node node fork))
! ;; menu item: node name or index entry
! ((Info-get-token (point) "\\* +" "\\* +\\(.*\\): ")
! (beginning-of-line)
! (forward-char 2)
! (setq node (Info-extract-menu-node-name nil (Info-index-node)))
! (Info-goto-node node fork))
! ((setq node (Info-get-token (point) "Up: " "Up: \\([^,\n\t]*\\)"))
! (Info-goto-node node fork))
! ((setq node (Info-get-token (point) "Next: " "Next: \\([^,\n\t]*\\)"))
! (Info-goto-node node fork))
! ((setq node (Info-get-token (point) "File: " "File: \\([^,\n\t]*\\)"))
! (Info-goto-node "Top" fork))
! ((setq node (Info-get-token (point) "Prev: " "Prev: \\([^,\n\t]*\\)"))
! (Info-goto-node node fork)))
node))
(defun Info-mouse-follow-link (click)
In GNU Emacs 24.3.50.2 (x86_64-suse-linux-gnu, GTK+ Version 3.4.4)
of 2013-06-25 on rosalinde
Bzr revision: 113175 lekktu@gmail.com-20130625172019-xiu7eowuwtknvz39
Windowing system distributor `The X.Org Foundation', version 11.0.11203000
System Description: openSUSE 12.2 (x86_64)
Configured using:
`configure --without-toolkit-scroll-bars CFLAGS=-g3 -O0'
Important settings:
value of $LANG: en_US.UTF-8
value of $XMODIFIERS: @im=local
locale-coding-system: utf-8-unix
default enable-multibyte-characters: t
next reply other threads:[~2013-06-25 18:34 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-25 18:34 Stephen Berman [this message]
2013-06-26 23:39 ` bug#14717: 24.3.50; Info-try-follow-nearest-node misses some footnotes Juri Linkov
2013-06-27 9:37 ` Stephen Berman
2013-06-28 21:50 ` Juri Linkov
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=87vc52599u.fsf@rosalinde.fritz.box \
--to=stephen.berman@gmx.net \
--cc=14717@debbugs.gnu.org \
/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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.