GNU bug report logs -
#16333
24.3.50; Info manuals: link defined terms to their glossary entries
Previous Next
Reported by: Drew Adams <drew.adams <at> oracle.com>
Date: Fri, 3 Jan 2014 21:51:02 UTC
Severity: wishlist
Tags: wontfix
Found in version 24.3.50
Done: Stefan Kangas <stefan <at> marxist.se>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
> Date: Fri, 30 Oct 2020 14:14:54 -0700 (PDT)
> From: Drew Adams <drew.adams <at> oracle.com>
> Cc: stefan <at> marxist.se, 16333 <at> debbugs.gnu.org
>
> > Here's a suggestion, to make this less rigid/fragile:
> > Substitute for "mouse-2" everywhere in the help text,
> > as follows.
> >
> > (defun mouse-fixup-help-message (msg)
> > "Fix help message MSG for `mouse-1-click-follows-link'."
> > (let (mp pos)
> > (when (and mouse-1-click-follows-link
> > (stringp msg)
> > (string-match-p "mouse-2" msg)
> > (setq mp (mouse-pixel-position))
> > (consp (setq pos (cdr mp)))
> > (car pos) (>= (car pos) 0)
> > (cdr pos) (>= (cdr pos) 0)
> > (setq pos (posn-at-x-y (car pos) (cdr pos) (car mp)))
> > (windowp (posn-window pos)))
> > (with-current-buffer (window-buffer (posn-window pos))
> > (when (mouse-on-link-p pos)
> > (setq msg (replace-regexp-in-string
> > "mouse-2"
> > (concat
> > (cond ((eq mouse-1-click-follows-link 'double)
> > "double-")
> > ((and (integerp mouse-1-click-follows-link)
> > (< mouse-1-click-follows-link 0))
> > "Long ")
> > (t ""))
> > "mouse-1")
> > msg))))))
> > msg)
> > ___
> >
> > Or if you think it's more appropriate for some reason,
> > then substitute only the first occurrence of "mouse-2".
> >
> > Of if you think we should let users specify exactly
> > which occurrences of "mouse-2" to substitute, then
> > define a formatting escape for that (e.g. "%m"), so
> > only "mouse-2" occurrences preceded by that escape get
> > substituted. E.g., "xxx%mmouse-2" would substitute
> > the "mouse-2", but "xxxmouse-2" would not.
>
>
> Actually, the following is much better. It lets code
> use different patterns in different contexts, by binding
> the variable.
>
> Should I submit this as a separate bug report, or can it
> be considered in the context of this one?
Please be sure to grep all our Lisp sources and make sure this change
won't replace stuff in places we don't want. Please don't push this
before this check is complete, thanks.
This bug report was last modified 3 years and 223 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.