bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#60587: Patch for adding links to symbols' help documentation


From: H. Dieter Wilhelm
Subject: bug#60587: Patch for adding links to symbols' help documentation
Date: Wed, 25 Jan 2023 22:29:31 +0100
User-agent: Gnus/5.13 (Gnus v5.13)

Eli Zaretskii <eliz@gnu.org> writes:

>> Unfortunately I also need to investigate the code anew.  Yesterday I
>> realised a regression starting with Emacs-29!  `Tab' and `S-Tab' aren't
>> working any longer for Info references.  (E.g. the `Tab' keybinding is
>> switched from `Info-next-reference' to `forward-button'..)
>
> So I guess you will be submitting a new patch soon?

Below it is (based on a recent master commit).

> I think the first sentence should be rewritten as describing a
> separate feature, not "the same as" something else.  Just say that
> symbols are converted into buttons that lead to their doc strings.
>
> Also, the option which controls this should be mentioned and indexed.

Please have a look at a further documentation patch.

>From 2e1f604c0923d39bbbc9314903622b92b3118830 Mon Sep 17 00:00:00 2001
From: Dieter Wilhelm <dieter@duenenhof-wilhelm.de>
Date: Mon, 23 Jan 2023 21:13:54 +0100
Subject: [PATCH] Documentation of Info providing buttons on quoted symbols
 (bug#60587)

*etc/NEWS: Mention implementation
*doc/emacs/help.texi: Describe implementation and how to switch off
 button creation
---
 doc/emacs/help.texi | 13 +++++++++++++
 etc/NEWS            | 11 +++++++++++
 2 files changed, 24 insertions(+)

diff --git a/doc/emacs/help.texi b/doc/emacs/help.texi
index 2513e6be271..02b8962c360 100644
--- a/doc/emacs/help.texi
+++ b/doc/emacs/help.texi
@@ -653,6 +653,19 @@ Misc Help
 K @var{key}}, described above, enter Info and go straight to the
 documentation of @var{function} or @var{key}.
 
+  In Info buffers quoted symbol names are made into buttons which show
+the symbols' help documentation when typing @key{RET} or clicking
+@kbd{mouse-2} or @kbd{mouse-1} on it.  For example, the quoted name
+@code{info-other-window} is made into a button which shows the
+function's documentation string in another window, in the
+@file{*Help*} buffer.  Such quoted symbols (variables, functions and
+face names) are highlighted by a distinct face and can be reached, as
+the Info manual references, with @key{TAB} and @kbd{S-Tab}.
+
+@vindex info-make-xref-flag
+  If you want to prohibit the button creation for Info buffers, you
+can set @code{info-make-xref-flag} to @code{nil}.
+
 @kindex C-h S
 @findex info-lookup-symbol
   When editing a program, if you have an Info version of the manual
diff --git a/etc/NEWS b/etc/NEWS
index 5b8ab06086c..c55d39baf0c 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -195,6 +195,17 @@ This command adds a docstring comment to the current 
defun.  If a
 comment already exists, point is only moved to the comment.  It is
 bound to 'C-c C-d' in 'go-ts-mode'.
 
+** Info
+
++++
+*** Info-mode provides buttons on symbols showing their documentation string.
+Quoted `symbols', like names of variables, functions or face names,
+are made into buttons which can display the respective documentation
+strings.  These strings are presented in *Help* buffers in another
+window.  Such buttons are working independently of the regular Info
+cross references and can be disabled with setting
+`info-make-xref-flag' to nil.
+
 
 * New Modes and Packages in Emacs 30.1
 
-- 
2.34.1

Attachment: 0001-Info-providing-buttons-on-quoted-symbols-bug-60587.patch
Description: Text Data

-- 
Best wishes
H. Dieter Wilhelm
Zwingenberg, Germany

reply via email to

[Prev in Thread] Current Thread [Next in Thread]