unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Ihor Radchenko <yantar92@posteo.net>
Cc: 59293-done@debbugs.gnu.org
Subject: bug#59293: 28.1.90; Erroneous footnote link in Org info manual
Date: Thu, 17 Nov 2022 09:11:40 +0200	[thread overview]
Message-ID: <83o7t6dphv.fsf@gnu.org> (raw)
In-Reply-To: <87wn7ub0cz.fsf@localhost> (message from Ihor Radchenko on Thu, 17 Nov 2022 05:45:16 +0000)

> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: 59293@debbugs.gnu.org
> Date: Thu, 17 Nov 2022 05:45:16 +0000
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > It's a bug in info.el: it fontifies the footnote references, but the
> > detection of footnote cannot distinguish between "(1)" that is a
> > reference to a footnote and "(1)" that just stands for itself.
> 
> Thanks for clarification. Is it something known but difficult to fix?

AFAIU the code, it detects footnote references by looking for [0-9]+
in parentheses, then fontifies those of the references whose numbers
are smaller than the number of footnotes actually present in the node.
So, for example, if a node has 5 footnotes, "(6)" will not be
fontified, but each occurrence of "(4)" will be fontified.

The comment there says:

              ;; Don't fontify parenthesized numbers that cannot
              ;; possibly be one of this node's footnotes.  This still
              ;; doesn't catch unrelated numbers that happen to be
              ;; small enough, but in that case they should use
              ;; "@footnotestyle separate" in the Texinfo sources.

> > My suggestion is to modify the example in the manual to avoid the
> > false match, for example use "runif(3)" if possible.  Alternatively,
> > remove the real footnotes and make them notes in parentheses.  Or
> > just live with the problem...
> 
> I went with runif(+1).
> https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=79c64d8c3ac66e13a333a4cbc8ba15e242bc01fb

That's a good solution, thanks.

So I'm closing this bug report.





      reply	other threads:[~2022-11-17  7:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-16  1:22 bug#59293: 28.1.90; Erroneous footnote link in Org info manual Ihor Radchenko
2022-11-16 12:42 ` Eli Zaretskii
2022-11-17  5:45   ` Ihor Radchenko
2022-11-17  7:11     ` Eli Zaretskii [this message]

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=83o7t6dphv.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=59293-done@debbugs.gnu.org \
    --cc=yantar92@posteo.net \
    /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 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).