Received: (at 77169-done) by debbugs.gnu.org; 29 Mar 2025 11:28:14 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 29 07:28:14 2025 Received: from localhost ([127.0.0.1]:57270 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tyUMI-0002ab-1V for submit <at> debbugs.gnu.org; Sat, 29 Mar 2025 07:28:14 -0400 Received: from server.qxqx.de ([2a01:4f8:c012:9177::1]:41405 helo=mail.qxqx.de) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <mail@HIDDEN>) id 1tyUMC-0002Zn-U7 for 77169-done <at> debbugs.gnu.org; Sat, 29 Mar 2025 07:28:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=daniel-mendler.de; s=key; h=Content-Type:MIME-Version:Message-ID:Date: References:In-Reply-To:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=+7RsoUkO6PpnR7x6xT+Z9NgT+69w5uhgQ3aMwRa/s6g=; b=ZMqRMcJ9rDOnLrBMtttQmhy41a 2vz3euf/0zX3RlaQNvTYiA8qUFl3qVV2zWq/0GnSgsNrWohT0HZ0vF/WkZW4qAkbM94fztZOEgAzX V4UKa3qRNNn6kXK8ENpxxeYqmzD/AoPUfRTucUEX0lwYH/CcPI9eJuqajrW1mkhhHS8k=; From: Daniel Mendler <mail@HIDDEN> To: Eli Zaretskii <eliz@HIDDEN> Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' In-Reply-To: <86ecyg85vz.fsf@HIDDEN> (Eli Zaretskii's message of "Sat, 29 Mar 2025 13:53:36 +0300") References: <87r02pl7y5.fsf@HIDDEN> <C079BBB8-F545-4251-AD75-7BCFFEAF354E@HIDDEN> <87h63f251y.fsf@HIDDEN> <86ecyg85vz.fsf@HIDDEN> Date: Sat, 29 Mar 2025 12:27:59 +0100 Message-ID: <87r02gnkjk.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 77169-done Cc: 77169-done <at> debbugs.gnu.org, hmelman@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) Eli Zaretskii <eliz@HIDDEN> writes: >> From: Daniel Mendler <mail@HIDDEN> >> Cc: 77169 <at> debbugs.gnu.org, eliz@HIDDEN >> Date: Wed, 26 Mar 2025 16:19:05 +0100 >> >> Howard Melman <hmelman@HIDDEN> writes: >> >> > Daniel Mendler via "Bug reports for GNU Emacs, the Swiss >> > army knife of text editors" <bug-gnu-emacs@HIDDEN> writes: >> > >> >>>> Okay. I have attached an updated version of the patch to this mail. I >> >>>> have added a customization option (off by default) and a NEWS entry. >> > >> >> +(defcustom eldoc-help-at-pt nil >> >> + "If non-nil, sow `help-at-pt-kbd-string' at point via Eldoc. >> > >> > s/sow/show/ >> >> Fixed. Updated patch attached to this mail. > > Thanks, installed on master, and closing the bug. Thanks!
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169-done) by debbugs.gnu.org; 29 Mar 2025 10:53:47 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 29 06:53:47 2025 Received: from localhost ([127.0.0.1]:57128 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tyTox-0000l9-Fn for submit <at> debbugs.gnu.org; Sat, 29 Mar 2025 06:53:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35476) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tyTou-0000kp-Uv for 77169-done <at> debbugs.gnu.org; Sat, 29 Mar 2025 06:53:45 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tyToo-00082u-V4; Sat, 29 Mar 2025 06:53:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=+CFqCWSbrP6KHwbq8sMLKjqfTaicM/pQwfEav70WqT8=; b=ouhNteGjS8v7 L6E3ViTdxxponeQ0riN6FSwkq8AaKS4Im7jNgWraCjqW/sMhZ1tm/LVkIlfpWbzG4tBtUVRuoD4dl I4dy1sK1X47K3sV2LuenPHmHWxv1ZIAJbheM7t7yPvZGs3NkS38g8b3UcRfcpJ0nXKYKdbFSi3eAn TeVEmjVHKmwn9D/woQCDBF/Z6eZ/9Lfj5uOQjTlhl5RcWamcTpKCpCN4vnL6L+U9bik/2EQKce/Hr G2BAeWUFBi1Y14yBUIQMcO6Iaah76anBSZX8VUBSMy7Trhja5pfM4mKxDTxxSdRPYGJVvu3uoUwUm 0vGaWiImbZbLTGSqr1ZPoQ==; Date: Sat, 29 Mar 2025 13:53:36 +0300 Message-Id: <86ecyg85vz.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Daniel Mendler <mail@HIDDEN> In-Reply-To: <87h63f251y.fsf@HIDDEN> (message from Daniel Mendler on Wed, 26 Mar 2025 16:19:05 +0100) Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' References: <87r02pl7y5.fsf@HIDDEN> <C079BBB8-F545-4251-AD75-7BCFFEAF354E@HIDDEN> <87h63f251y.fsf@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 77169-done Cc: 77169-done <at> debbugs.gnu.org, hmelman@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > From: Daniel Mendler <mail@HIDDEN> > Cc: 77169 <at> debbugs.gnu.org, eliz@HIDDEN > Date: Wed, 26 Mar 2025 16:19:05 +0100 > > Howard Melman <hmelman@HIDDEN> writes: > > > Daniel Mendler via "Bug reports for GNU Emacs, the Swiss > > army knife of text editors" <bug-gnu-emacs@HIDDEN> writes: > > > >>>> Okay. I have attached an updated version of the patch to this mail. I > >>>> have added a customization option (off by default) and a NEWS entry. > > > >> +(defcustom eldoc-help-at-pt nil > >> + "If non-nil, sow `help-at-pt-kbd-string' at point via Eldoc. > > > > s/sow/show/ > > Fixed. Updated patch attached to this mail. Thanks, installed on master, and closing the bug.
Daniel Mendler <mail@HIDDEN>
:Eli Zaretskii <eliz@HIDDEN>
:Received: (at 77169) by debbugs.gnu.org; 26 Mar 2025 15:19:18 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Mar 26 11:19:18 2025 Received: from localhost ([127.0.0.1]:43886 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1txSXF-0004RR-GB for submit <at> debbugs.gnu.org; Wed, 26 Mar 2025 11:19:18 -0400 Received: from server.qxqx.de ([2a01:4f8:c012:9177::1]:42305 helo=mail.qxqx.de) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <mail@HIDDEN>) id 1txSXB-0004RC-Pf for 77169 <at> debbugs.gnu.org; Wed, 26 Mar 2025 11:19:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=daniel-mendler.de; s=key; h=Content-Type:MIME-Version:Message-ID:Date: References:In-Reply-To:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=1a1SxzMrPhrcHpX3oqHmRekE3W7ZqR59rmWaqvgSylY=; b=jn7INh161GBMvxwPhI/g375elK M1Hm9eiQyeunAIO+ctxJG+RCA3eW1NKLUobR9RabyHvAlYTZ+EappGU8rLNJoJhE7vliFEn57Fsxx dhjlJLlqc73PqTJ05yizY9eVIw3nKxSFv39HCWXne0YmNJY1F+80PFlBw66gAYXGjCds=; From: Daniel Mendler <mail@HIDDEN> To: Howard Melman <hmelman@HIDDEN> Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' In-Reply-To: <C079BBB8-F545-4251-AD75-7BCFFEAF354E@HIDDEN> (Howard Melman's message of "Sun, 23 Mar 2025 10:29:33 -0400") References: <87r02pl7y5.fsf@HIDDEN> <C079BBB8-F545-4251-AD75-7BCFFEAF354E@HIDDEN> Date: Wed, 26 Mar 2025 16:19:05 +0100 Message-ID: <87h63f251y.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 77169 Cc: eliz@HIDDEN, 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain Howard Melman <hmelman@HIDDEN> writes: > Daniel Mendler via "Bug reports for GNU Emacs, the Swiss > army knife of text editors" <bug-gnu-emacs@HIDDEN> writes: > >>>> Okay. I have attached an updated version of the patch to this mail. I >>>> have added a customization option (off by default) and a NEWS entry. > >> +(defcustom eldoc-help-at-pt nil >> + "If non-nil, sow `help-at-pt-kbd-string' at point via Eldoc. > > s/sow/show/ Fixed. Updated patch attached to this mail. Daniel --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-New-Eldoc-function-eldoc-show-help-at-pt.patch From d675280c2ee379faa33b7c65cbcf04ac5beabc93 Mon Sep 17 00:00:00 2001 From: Daniel Mendler <mail@HIDDEN> Date: Sat, 22 Mar 2025 10:29:45 +0100 Subject: [PATCH] New Eldoc function `eldoc-show-help-at-pt' Show help-at-pt string via Eldoc as an alternative to the `help-at-pt-display-when-idle' timer. The help-at-pt timer competes with Eldoc for the echo area, such that the two mechanisms do not work well together. Therefore when using Eldoc, the setting `eldoc-help-at-pt' may be preferable. * lisp/emacs-lisp/eldoc.el (eldoc-help-at-pt): New customization option. (eldoc-show-help-at-pt): New Eldoc function. (eldoc-documentation-functions): Register the new function. * lisp/help-at-pt.el (help-at-pt-display-when-idle): Mention `eldoc-help-at-pt' in the docstring. * doc/emacs/help.texi: Document `eldoc-help-at-pt'. * etc/NEWS: Announce the change. --- doc/emacs/help.texi | 4 +++- etc/NEWS | 5 +++++ lisp/emacs-lisp/eldoc.el | 15 ++++++++++++++- lisp/help-at-pt.el | 7 ++++++- 4 files changed, 28 insertions(+), 3 deletions(-) diff --git a/doc/emacs/help.texi b/doc/emacs/help.texi index 5c2eabb02d6..6ea7b5783c2 100644 --- a/doc/emacs/help.texi +++ b/doc/emacs/help.texi @@ -857,9 +857,11 @@ Help Echo @kindex C-h . @findex display-local-help @vindex help-at-pt-display-when-idle +@vindex eldoc-help-at-pt On terminals that don't support mouse-tracking, you can display the help text for active buffer text at point by typing @kbd{C-h .} (@code{display-local-help}). This shows the help text in the echo area. To display help text automatically whenever it is available at point, set the variable @code{help-at-pt-display-when-idle} to -@code{t}. +@code{t}. If you use Eldoc, set the variable @code{eldoc-help-at-pt} +to @code{t} instead. diff --git a/etc/NEWS b/etc/NEWS index c8797cf74ec..4d559565011 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -427,6 +427,11 @@ need to set it with 'setopt' for it to take an effect. If the docstring doesn't already mention 'setopt', the 'describe-variable' command will now add a note about this automatically. ++++ +** New user option 'eldoc-help-at-pt' to show help at point via Eldoc. +When enabled, display the 'help-at-pt-kbd-string' via Eldoc. This +setting is an alternative to 'help-at-pt-display-when-idle'. + * Editing Changes in Emacs 31.1 diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el index 85fb6c780e2..2b5d5cc0c8d 100644 --- a/lisp/emacs-lisp/eldoc.el +++ b/lisp/emacs-lisp/eldoc.el @@ -138,6 +138,13 @@ eldoc-echo-area-prefer-doc-buffer (const :tag "Skip echo area if truncating" maybe)) :version "28.1") +(defcustom eldoc-help-at-pt nil + "If non-nil, show `help-at-pt-kbd-string' at point via Eldoc. +This setting is an alternative to `help-at-pt-display-when-idle'. If +the value is non-nil, `eldoc-show-help-at-pt' will show help-at-point +via Eldoc." + :type 'boolean) + (defface eldoc-highlight-function-argument '((t (:inherit bold))) "Face used for the argument at point in a function's argument list. @@ -410,7 +417,7 @@ eldoc-display-message-no-interference-p (overlay-end show-paren--overlay))))))) -(defvar eldoc-documentation-functions nil +(defvar eldoc-documentation-functions (list #'eldoc-show-help-at-pt) "Hook of functions that produce doc strings. A doc string is typically relevant if point is on a function-like @@ -957,6 +964,12 @@ eldoc-print-current-symbol-info (setq eldoc--last-request-state token) (eldoc--invoke-strategy nil)))))) +(defun eldoc-show-help-at-pt (&rest _) + "Show help at point via Eldoc if `eldoc-help-at-pt' is non-nil. +Intended for `eldoc-documentation-functions' (which see)." + (when-let* ((help (and eldoc-help-at-pt (help-at-pt-kbd-string)))) + (format "Help: %s" (substitute-command-keys help)))) + ;; This section only affects ElDoc output to the echo area, as in ;; `eldoc-display-in-echo-area'. diff --git a/lisp/help-at-pt.el b/lisp/help-at-pt.el index 68054016dc5..094f2b788fe 100644 --- a/lisp/help-at-pt.el +++ b/lisp/help-at-pt.el @@ -191,7 +191,12 @@ help-at-pt-display-when-idle enabling buffer local values. It sets the actual value to nil. Thus, Custom distinguishes between a nil value and other values that disable the feature, which Custom identifies with `never'. -The default is `never'." +The default is `never'. + +Eldoc uses the echo area to display documentation. As such it +conflicts with `help-at-pt-display-when-idle' due to the use of +the echo area. If you use Eldoc, consider setting +`eldoc-help-at-pt' instead." :group 'help-at-pt :type '(choice (const :tag "Always" :format "%t\n%h" -- 2.47.2 --=-=-=--
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 23 Mar 2025 14:30:05 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Mar 23 10:30:05 2025 Received: from localhost ([127.0.0.1]:51943 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1twMKx-00069O-PU for submit <at> debbugs.gnu.org; Sun, 23 Mar 2025 10:30:04 -0400 Received: from lists.gnu.org ([2001:470:142::17]:36852) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <hmelman@HIDDEN>) id 1twMKr-00067G-7P for submit <at> debbugs.gnu.org; Sun, 23 Mar 2025 10:29:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <hmelman@HIDDEN>) id 1twMKk-0004Qu-GU for bug-gnu-emacs@HIDDEN; Sun, 23 Mar 2025 10:29:50 -0400 Received: from mail-qv1-xf30.google.com ([2607:f8b0:4864:20::f30]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <hmelman@HIDDEN>) id 1twMKi-0005ua-FX; Sun, 23 Mar 2025 10:29:50 -0400 Received: by mail-qv1-xf30.google.com with SMTP id 6a1803df08f44-6ecf99dd567so2073436d6.0; Sun, 23 Mar 2025 07:29:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1742740186; x=1743344986; darn=gnu.org; h=to:cc:date:message-id:subject:mime-version :content-transfer-encoding:from:from:to:cc:subject:date:message-id :reply-to; bh=xBYvXucdvBKLa0T6XZ4vveclwikZ1sCY9hbsFtFwxKw=; b=l5VT/CQ/DPaFP9uZVe2b5JDfY2VjvbMlYBU0LSy6OAr8+CsxBVnlf2L5PHziWvhhFi s6NA8nNwG2YJ4L4WOlgiEms4wpNX/ZqjN12O6ftH7sWXOhq9nZo3zEBHUh+AIX/Kijgy LdlpreMdYkpl5hZzT26uEPHpcYZc05lQm9Ia9ru/adrKIE78UPIoUMSdMbeYmjJGpUW8 LYXRzoyNvI/bENJ8t1km5di4HEtHtSPQE2bMkUZG5FsjrM58zV2KaXsmg/Z5T7WbrqSx 2AeWO2WKBMcXqjndRZQf9tc9IEGNxv/O/Duom0qFcVayQjWRmQQSTNrLwHsczhoO9j0C 0R3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1742740186; x=1743344986; h=to:cc:date:message-id:subject:mime-version :content-transfer-encoding:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xBYvXucdvBKLa0T6XZ4vveclwikZ1sCY9hbsFtFwxKw=; b=Xf7PSnY/X+G/W25v7XPWLlWvWPFxABQfPC1FT7nkENRRYjMcxz8gXC93rDfWjQ4E/8 Xr95c4ck4FNXPw7JXKKkygrJ5CcUqcZOCQyT1yYiWnCvV73b4G6t6cgZTnA+RnYqz/Pf ylwNPXT8oxiczlR7NfzEZnKg0qymaxnEpNpammuUvzzkIsL/Du0tzJdA35QPwFCLZTud 2Jd703OTWdUJOSQtU0AmsGYyxbbTJHHwCSQ5G40JCgm8P1/Dou5kWhymQTYULYUHngg7 X5ykVJr5ZDaiq73qMDIsc6p+UokRsgj5A5UIeLmM4GeRwIkypDsEU9wJPruHoBxWUxfE 8kSw== X-Gm-Message-State: AOJu0Yz7nd5ENMaSS3gdYFd+pUkhk7numiTbOqUeYuriXJiWUskJYOwH CSSfMp65kCdRcjlmPmSyNrABNlB6DlGNd+MAjkLymYIeQt5ElQMdUjt+YlC4 X-Gm-Gg: ASbGnctXLINuvj9oJM+Kxwg1r7yR69Zd6BXQBJUvY/aFvZ3FXY8bjLx61ZK/ZfC5Dwf Xn2vVJfJkhMt7VRdGBXoSukfVlcrfgTSoSddqyv6N/7Orl4uROoUnRvjMieyAkqshjiUrEtg8OI +WbCejQWIwua3ZzDsJ3MLJC17RINcq4lItA0TmK8AE6cuLA3eEsgyRVXDbvWuvNGJtQ+1olfLch Vm9l/soVg0aNDGlfdc911Fcgse3GvBq7+CC7EYgTpMkz4Lo8Qez33oHbNkaxt6lrXxhL4fl88l5 C65HMmaNiAxPFCVQWlj+3PsT8hZjOffos9onFV/pLobuDpyS9UE38Mpx X-Google-Smtp-Source: AGHT+IHB5UJpJdL7VqCALoxmp5prJkIMAape6Wg9AOa9h9kzJ1VanHtx9PyoNCoQ2jbA7qEIF2h6IQ== X-Received: by 2002:a05:6214:cc8:b0:6ea:d39e:9aa4 with SMTP id 6a1803df08f44-6eb3f285898mr144587956d6.5.1742740185587; Sun, 23 Mar 2025 07:29:45 -0700 (PDT) Received: from smtpclient.apple ([72.85.185.24]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6eb3efc5bdfsm32065346d6.76.2025.03.23.07.29.43 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 23 Mar 2025 07:29:44 -0700 (PDT) From: Howard Melman <hmelman@HIDDEN> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.400.131.1.6\)) Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' Message-Id: <C079BBB8-F545-4251-AD75-7BCFFEAF354E@HIDDEN> Date: Sun, 23 Mar 2025 10:29:33 -0400 To: GNU Emacs <bug-gnu-emacs@HIDDEN> X-Mailer: Apple Mail (2.3826.400.131.1.6) Received-SPF: pass client-ip=2607:f8b0:4864:20::f30; envelope-from=hmelman@HIDDEN; helo=mail-qv1-xf30.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit Cc: mail@HIDDEN, eliz@HIDDEN, 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.0 (/) Daniel Mendler via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN> writes: >>> Okay. I have attached an updated version of the patch to this mail. I >>> have added a customization option (off by default) and a NEWS entry. > +(defcustom eldoc-help-at-pt nil > + "If non-nil, sow `help-at-pt-kbd-string' at point via Eldoc. s/sow/show/ -- Howard
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 23 Mar 2025 14:29:53 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Mar 23 10:29:53 2025 Received: from localhost ([127.0.0.1]:51935 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1twMKn-00067Z-B1 for submit <at> debbugs.gnu.org; Sun, 23 Mar 2025 10:29:53 -0400 Received: from mail-qv1-xf31.google.com ([2607:f8b0:4864:20::f31]:60744) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from <hmelman@HIDDEN>) id 1twMKl-00066W-Fc for 77169 <at> debbugs.gnu.org; Sun, 23 Mar 2025 10:29:51 -0400 Received: by mail-qv1-xf31.google.com with SMTP id 6a1803df08f44-6e89a2501a0so34375176d6.1 for <77169 <at> debbugs.gnu.org>; Sun, 23 Mar 2025 07:29:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1742740186; x=1743344986; darn=debbugs.gnu.org; h=to:cc:date:message-id:subject:mime-version :content-transfer-encoding:from:from:to:cc:subject:date:message-id :reply-to; bh=xBYvXucdvBKLa0T6XZ4vveclwikZ1sCY9hbsFtFwxKw=; b=dENOHM9/u+FkuYMcyo0S4NtYt+sbHiDji5+F0xQWopbdmKiSHkOZvWndr/DfczHNe3 EtJGgBgawi5KmkrZJvzQMBUw852RUqgRnViQxVjWX/SHXniErZPj4ozFEDdQ3pugm49E 8nhrhWcxx+JeEpkJ5zOY3ZElUscktHV4TSQDCzcpXs1w0/XvgaJ5PxWhfRH8cy9Sh4kO zwQq+XHJcpHGQ5K34tVtybBOvbgzYjpm/Q+vu0p/u2lCoSL6RhvXxn1uH2zx281dzT2W R7EnEfHPs5rq2qnLu4PuHUSreJ5znfks1E3UJYnn1bSc7mtWn1NavTiya+/PXUfWwWjB dnxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1742740186; x=1743344986; h=to:cc:date:message-id:subject:mime-version :content-transfer-encoding:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xBYvXucdvBKLa0T6XZ4vveclwikZ1sCY9hbsFtFwxKw=; b=Jo+/eAvLNl3C8qggowGewFynMb+KxAyfB3GyPLAvAkZ2O9AXW6TEjQ5C3jqdyXJc/K PNsajpq0gtkyCUR1F4EOelf14jdeIWiBK+QU9pL25bzhtFfDlII97wX2ju7A6h3unl5R MJH4t+4DhgHa1b2KQYEOgywkqYwWxiafCpheZGu8gUh2FWQSSlyPnk0mKKwUXFZABTO/ Naj9Do8/yE4TKhCdAr9Onkria3cPeaIjUGoW8X+JvYS9lFnfzbqBIZUMkQ20GD814zO9 v5JxeTmSwgctXw/mij1cA8ST3HrzyA/9mMBoUjdivdX7vdH/3j9cq9cHsz5wW3IYO+8B 4ILg== X-Forwarded-Encrypted: i=1; AJvYcCXL/wvgKPA6DadD3Qnbs7DoVTWnohTcW3maSyoLbUTKfnXUAUuojbFePLDfdGWHj97LNkWb1g==@debbugs.gnu.org X-Gm-Message-State: AOJu0Yw64laiRxbOGziVCdOV26oDMqBo+tlIQb0aM2KmeTtnfPDFr8pl ZP6B792DbSUezrV5dnCB6OAjrv1OhwC4CS2/hJwH2c8w7796b32UAFLn17ay X-Gm-Gg: ASbGncuRDfwX0PgA4QnlHEHUQO9vNU54QSG5zdg+vHv6C8AQ/cxd2sfSF/ugqEmuP+S yPgqA38o9xWvU5GtDL3s1LaaGmDBWoRiuLS3S7gGqJfMsXJXMI+NnyiyOTQjRy5aK8UFWIDiTuu ACYMKHLONFrkD/WSC9kwrDFyDGehI85/GROXu3oY3GdEGA1ka3N7BFPJpCVz3jQqtWi//5pbrG9 xu1K8kNHc5XCZRX0tBPVjOlUC8Of224pcoUcUne/Rd+YIVkKfaQOGX8FizvJ924XmOT8xpJf8dC FEACWGyU0K5z10mWjjDeK0muFgOBX2/d6f7s0KEaBrXAOKxvtgA11vA1 X-Google-Smtp-Source: AGHT+IHB5UJpJdL7VqCALoxmp5prJkIMAape6Wg9AOa9h9kzJ1VanHtx9PyoNCoQ2jbA7qEIF2h6IQ== X-Received: by 2002:a05:6214:cc8:b0:6ea:d39e:9aa4 with SMTP id 6a1803df08f44-6eb3f285898mr144587956d6.5.1742740185587; Sun, 23 Mar 2025 07:29:45 -0700 (PDT) Received: from smtpclient.apple ([72.85.185.24]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6eb3efc5bdfsm32065346d6.76.2025.03.23.07.29.43 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 23 Mar 2025 07:29:44 -0700 (PDT) From: Howard Melman <hmelman@HIDDEN> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.400.131.1.6\)) Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' Message-Id: <C079BBB8-F545-4251-AD75-7BCFFEAF354E@HIDDEN> Date: Sun, 23 Mar 2025 10:29:33 -0400 To: GNU Emacs <bug-gnu-emacs@HIDDEN> X-Mailer: Apple Mail (2.3826.400.131.1.6) X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 77169 Cc: mail@HIDDEN, eliz@HIDDEN, 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Daniel Mendler via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN> writes: >>> Okay. I have attached an updated version of the patch to this mail. I >>> have added a customization option (off by default) and a NEWS entry. > +(defcustom eldoc-help-at-pt nil > + "If non-nil, sow `help-at-pt-kbd-string' at point via Eldoc. s/sow/show/ -- Howard
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 23 Mar 2025 07:22:59 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Mar 23 03:22:59 2025 Received: from localhost ([127.0.0.1]:47243 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1twFfe-000378-JB for submit <at> debbugs.gnu.org; Sun, 23 Mar 2025 03:22:59 -0400 Received: from server.qxqx.de ([2a01:4f8:c012:9177::1]:43997 helo=mail.qxqx.de) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <mail@HIDDEN>) id 1twFfb-00035V-1U for 77169 <at> debbugs.gnu.org; Sun, 23 Mar 2025 03:22:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=daniel-mendler.de; s=key; h=Content-Type:MIME-Version:Message-ID:Date: References:In-Reply-To:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=b0cfLn01aq2xaluhtv4Sdm1xxtPVRtDjSlmC7oZLIEc=; b=KmnHc9/IA429Ph5rX+jO0W2qRD N5lmIqJV63OihucVMSi0K68VQ4QNrsjRb14OAXUpBzTFYftC1NpLGu75PNjM2iqNXiSCvf24GU9dz T3REFWrYwnNjCtf2QLd3sSc7jECjysLMe7OJOXxWuKR9vyIAy18WuoWhfPMhfGPnpSRs=; From: Daniel Mendler <mail@HIDDEN> To: Eli Zaretskii <eliz@HIDDEN> Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' In-Reply-To: <86r02ogtzx.fsf@HIDDEN> (Eli Zaretskii's message of "Sun, 23 Mar 2025 08:07:30 +0200") References: <87r02pl7y5.fsf@HIDDEN> <86iko1jp1d.fsf@HIDDEN> <87sen5b8xi.fsf@HIDDEN> <86sen5i671.fsf@HIDDEN> <87jz8gbx8k.fsf@HIDDEN> <86r02ogtzx.fsf@HIDDEN> Date: Sun, 23 Mar 2025 08:22:46 +0100 Message-ID: <87iko02ou1.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 77169 Cc: 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain Eli Zaretskii <eliz@HIDDEN> writes: >> From: Daniel Mendler <mail@HIDDEN> >> Cc: 77169 <at> debbugs.gnu.org >> Date: Sat, 22 Mar 2025 21:56:27 +0100 >> >> >> > Also, shouldn't we have a user option to turn this on in ElDoc? >> >> >> >> Not sure if we need an option given that it is easy to add the function >> >> to the list, or remove it, if the function is enabled by default. >> > >> > It might be easy fore you and me, but not for users who are not Lisp >> > programmers. >> >> Okay. I have attached an updated version of the patch to this mail. I >> have added a customization option (off by default) and a NEWS entry. > > Thanks. > >> --- a/etc/NEWS >> +++ b/etc/NEWS >> @@ -415,6 +415,11 @@ need to set it with 'setopt' for it to take an effect. If the docstring >> doesn't already mention 'setopt', the 'describe-variable' command will >> now add a note about this automatically. >> >> +--- > > This should be "+++", since you've updated the manuals. > >> +(defcustom eldoc-help-at-pt nil >> + "Show `help-at-pt-kbd-string' at point via Eldoc. > > "If non-nil, show `help-at-pt-kbd-string' at point via Eldoc." > >> +This setting is an alternative to `help-at-pt-display-when-idle'. If >> +the variable is t, enable the `eldoc-help-at-pt-function'." > > "Enable" is inaccurate, since it's enabled by default, it just doesn't > do anything when the variable is nil. So something like > > If the value is non-nil, `eldoc-help-at-pt-function' will show > help-at-point via Eldoc. > >> -(defvar eldoc-documentation-functions nil >> +(defvar eldoc-documentation-functions (list #'eldoc-help-at-pt-function) >> "Hook of functions that produce doc strings. >> >> A doc string is typically relevant if point is on a function-like >> @@ -957,6 +963,12 @@ eldoc-print-current-symbol-info >> (setq eldoc--last-request-state token) >> (eldoc--invoke-strategy nil)))))) >> >> +(defun eldoc-help-at-pt-function (&rest _) > > I thought symbols that end in "-function" are usually variables whose > value is the function, is that not so? So maybe call this > eldoc-show-help-at-pt instead? > >> --- a/lisp/help-at-pt.el >> +++ b/lisp/help-at-pt.el >> @@ -191,7 +191,11 @@ help-at-pt-display-when-idle >> enabling buffer local values. It sets the actual value to nil. >> Thus, Custom distinguishes between a nil value and other values >> that disable the feature, which Custom identifies with `never'. >> -The default is `never'." >> +The default is `never'. >> + >> +Eldoc uses the echo area to display help at point. > > I'd say "Eldoc uses the echo area to display documentation" instead, > since the conflict between help-at-pt-display-when-idle and Eldoc is > due to the use of echo-area, not because they both show help-at-pt. Thanks. I have updated the patch accordingly. The updated patch is attached to this mail. Daniel --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-New-Eldoc-function-eldoc-show-help-at-pt.patch From 2211dcaa7dc0e38ac8e0ee56302a58a2b5e7f2b0 Mon Sep 17 00:00:00 2001 From: Daniel Mendler <mail@HIDDEN> Date: Sat, 22 Mar 2025 10:29:45 +0100 Subject: [PATCH] New Eldoc function `eldoc-show-help-at-pt' Show help-at-pt string via Eldoc as an alternative to the `help-at-pt-display-when-idle' timer. The help-at-pt timer competes with Eldoc for the echo area, such that the two mechanisms do not work well together. Therefore when using Eldoc, the setting `eldoc-help-at-pt' may be preferable. * lisp/emacs-lisp/eldoc.el (eldoc-help-at-pt): New customization option. (eldoc-show-help-at-pt): New Eldoc function. (eldoc-documentation-functions): Register the new function. * lisp/help-at-pt.el (help-at-pt-display-when-idle): Mention `eldoc-help-at-pt' in the docstring. * doc/emacs/help.texi: Document `eldoc-help-at-pt'. * etc/NEWS: Announce the change. --- doc/emacs/help.texi | 4 +++- etc/NEWS | 5 +++++ lisp/emacs-lisp/eldoc.el | 15 ++++++++++++++- lisp/help-at-pt.el | 7 ++++++- 4 files changed, 28 insertions(+), 3 deletions(-) diff --git a/doc/emacs/help.texi b/doc/emacs/help.texi index 5c2eabb02d6..6ea7b5783c2 100644 --- a/doc/emacs/help.texi +++ b/doc/emacs/help.texi @@ -857,9 +857,11 @@ Help Echo @kindex C-h . @findex display-local-help @vindex help-at-pt-display-when-idle +@vindex eldoc-help-at-pt On terminals that don't support mouse-tracking, you can display the help text for active buffer text at point by typing @kbd{C-h .} (@code{display-local-help}). This shows the help text in the echo area. To display help text automatically whenever it is available at point, set the variable @code{help-at-pt-display-when-idle} to -@code{t}. +@code{t}. If you use Eldoc, set the variable @code{eldoc-help-at-pt} +to @code{t} instead. diff --git a/etc/NEWS b/etc/NEWS index c8797cf74ec..4d559565011 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -427,6 +427,11 @@ need to set it with 'setopt' for it to take an effect. If the docstring doesn't already mention 'setopt', the 'describe-variable' command will now add a note about this automatically. ++++ +** New user option 'eldoc-help-at-pt' to show help at point via Eldoc. +When enabled, display the 'help-at-pt-kbd-string' via Eldoc. This +setting is an alternative to 'help-at-pt-display-when-idle'. + * Editing Changes in Emacs 31.1 diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el index 85fb6c780e2..451ed059fb4 100644 --- a/lisp/emacs-lisp/eldoc.el +++ b/lisp/emacs-lisp/eldoc.el @@ -138,6 +138,13 @@ eldoc-echo-area-prefer-doc-buffer (const :tag "Skip echo area if truncating" maybe)) :version "28.1") +(defcustom eldoc-help-at-pt nil + "If non-nil, sow `help-at-pt-kbd-string' at point via Eldoc. +This setting is an alternative to `help-at-pt-display-when-idle'. If +the value is non-nil, `eldoc-show-help-at-pt' will show help-at-point +via Eldoc." + :type 'boolean) + (defface eldoc-highlight-function-argument '((t (:inherit bold))) "Face used for the argument at point in a function's argument list. @@ -410,7 +417,7 @@ eldoc-display-message-no-interference-p (overlay-end show-paren--overlay))))))) -(defvar eldoc-documentation-functions nil +(defvar eldoc-documentation-functions (list #'eldoc-show-help-at-pt) "Hook of functions that produce doc strings. A doc string is typically relevant if point is on a function-like @@ -957,6 +964,12 @@ eldoc-print-current-symbol-info (setq eldoc--last-request-state token) (eldoc--invoke-strategy nil)))))) +(defun eldoc-show-help-at-pt (&rest _) + "Show help at point via Eldoc if `eldoc-help-at-pt' is non-nil. +Intended for `eldoc-documentation-functions' (which see)." + (when-let* ((help (and eldoc-help-at-pt (help-at-pt-kbd-string)))) + (format "Help: %s" (substitute-command-keys help)))) + ;; This section only affects ElDoc output to the echo area, as in ;; `eldoc-display-in-echo-area'. diff --git a/lisp/help-at-pt.el b/lisp/help-at-pt.el index 68054016dc5..094f2b788fe 100644 --- a/lisp/help-at-pt.el +++ b/lisp/help-at-pt.el @@ -191,7 +191,12 @@ help-at-pt-display-when-idle enabling buffer local values. It sets the actual value to nil. Thus, Custom distinguishes between a nil value and other values that disable the feature, which Custom identifies with `never'. -The default is `never'." +The default is `never'. + +Eldoc uses the echo area to display documentation. As such it +conflicts with `help-at-pt-display-when-idle' due to the use of +the echo area. If you use Eldoc, consider setting +`eldoc-help-at-pt' instead." :group 'help-at-pt :type '(choice (const :tag "Always" :format "%t\n%h" -- 2.47.2 --=-=-=--
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 23 Mar 2025 06:07:44 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Mar 23 02:07:44 2025 Received: from localhost ([127.0.0.1]:47043 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1twEUo-0007uU-By for submit <at> debbugs.gnu.org; Sun, 23 Mar 2025 02:07:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33612) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1twEUk-0007t8-Vb for 77169 <at> debbugs.gnu.org; Sun, 23 Mar 2025 02:07:40 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1twEUe-0005KJ-Hm; Sun, 23 Mar 2025 02:07:32 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=gT8g+HH93wZYXFV3wWSnfa9sPJtNJ/L/RmuZKHR5k/A=; b=EYxLC7U9TJUh 5qpceTIM4s1hBdOYVLTMWybNPZknX24eWs68XQtd0tJc7tN+UQdDLOZn/rCqZoT5X9Nh7l3MqOCyU +GsOyHP2BV2sZocOoqI9pfrmKMVfKIVrbOr6m02zPuL6LQswyOHYbdQQmqFfoPxga3mg8lCPgkkxT QACLupBUpZ0J8DkW2rISbXA8S5d26BSyb5Mqafne2kiMryeVS41YwXzUS/Rd+Ihr9WIem6iJEjPGH DWgBh52eaxxU0Rz3sTd+8mE3MneMFvAYEJub4W5uT+q2LuOBS+uOlkfC5rvgsf9x+YIAQuODjMss8 12W3KEJ8zfRKA/AEjjOt3w==; Date: Sun, 23 Mar 2025 08:07:30 +0200 Message-Id: <86r02ogtzx.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Daniel Mendler <mail@HIDDEN> In-Reply-To: <87jz8gbx8k.fsf@HIDDEN> (message from Daniel Mendler on Sat, 22 Mar 2025 21:56:27 +0100) Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' References: <87r02pl7y5.fsf@HIDDEN> <86iko1jp1d.fsf@HIDDEN> <87sen5b8xi.fsf@HIDDEN> <86sen5i671.fsf@HIDDEN> <87jz8gbx8k.fsf@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 77169 Cc: 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > From: Daniel Mendler <mail@HIDDEN> > Cc: 77169 <at> debbugs.gnu.org > Date: Sat, 22 Mar 2025 21:56:27 +0100 > > >> > Also, shouldn't we have a user option to turn this on in ElDoc? > >> > >> Not sure if we need an option given that it is easy to add the function > >> to the list, or remove it, if the function is enabled by default. > > > > It might be easy fore you and me, but not for users who are not Lisp > > programmers. > > Okay. I have attached an updated version of the patch to this mail. I > have added a customization option (off by default) and a NEWS entry. Thanks. > --- a/etc/NEWS > +++ b/etc/NEWS > @@ -415,6 +415,11 @@ need to set it with 'setopt' for it to take an effect. If the docstring > doesn't already mention 'setopt', the 'describe-variable' command will > now add a note about this automatically. > > +--- This should be "+++", since you've updated the manuals. > +(defcustom eldoc-help-at-pt nil > + "Show `help-at-pt-kbd-string' at point via Eldoc. "If non-nil, show `help-at-pt-kbd-string' at point via Eldoc." > +This setting is an alternative to `help-at-pt-display-when-idle'. If > +the variable is t, enable the `eldoc-help-at-pt-function'." "Enable" is inaccurate, since it's enabled by default, it just doesn't do anything when the variable is nil. So something like If the value is non-nil, `eldoc-help-at-pt-function' will show help-at-point via Eldoc. > -(defvar eldoc-documentation-functions nil > +(defvar eldoc-documentation-functions (list #'eldoc-help-at-pt-function) > "Hook of functions that produce doc strings. > > A doc string is typically relevant if point is on a function-like > @@ -957,6 +963,12 @@ eldoc-print-current-symbol-info > (setq eldoc--last-request-state token) > (eldoc--invoke-strategy nil)))))) > > +(defun eldoc-help-at-pt-function (&rest _) I thought symbols that end in "-function" are usually variables whose value is the function, is that not so? So maybe call this eldoc-show-help-at-pt instead? > --- a/lisp/help-at-pt.el > +++ b/lisp/help-at-pt.el > @@ -191,7 +191,11 @@ help-at-pt-display-when-idle > enabling buffer local values. It sets the actual value to nil. > Thus, Custom distinguishes between a nil value and other values > that disable the feature, which Custom identifies with `never'. > -The default is `never'." > +The default is `never'. > + > +Eldoc uses the echo area to display help at point. I'd say "Eldoc uses the echo area to display documentation" instead, since the conflict between help-at-pt-display-when-idle and Eldoc is due to the use of echo-area, not because they both show help-at-pt.
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 22 Mar 2025 20:56:39 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 22 16:56:39 2025 Received: from localhost ([127.0.0.1]:45923 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tw5tW-0002mb-H5 for submit <at> debbugs.gnu.org; Sat, 22 Mar 2025 16:56:39 -0400 Received: from server.qxqx.de ([2a01:4f8:c012:9177::1]:46895 helo=mail.qxqx.de) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <mail@HIDDEN>) id 1tw5tT-0002lu-3T for 77169 <at> debbugs.gnu.org; Sat, 22 Mar 2025 16:56:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=daniel-mendler.de; s=key; h=Content-Type:MIME-Version:Message-ID:Date: References:In-Reply-To:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=8Ne4FpaFKqXhPITE0vKGCm0AiJWf9ykkTVwKvqNmvhY=; b=Es1GcGD3Ej4RTcBefC8l6GGN+C CWbXhHi3PRPiSejqGzVLdlZRdEZtvT6BselEOum7PlYWf3aieHEkwCKspQ17ZBXfkFRi162nXmxbT MCUBIY2soU7iojFzqqgr1UFmQpp+Ei3ONXdH5Yw6/MYBQmFKLrktnpb4wFQAK7nk0Tu0=; From: Daniel Mendler <mail@HIDDEN> To: Eli Zaretskii <eliz@HIDDEN> Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' In-Reply-To: <86sen5i671.fsf@HIDDEN> (Eli Zaretskii's message of "Sat, 22 Mar 2025 14:46:26 +0200") References: <87r02pl7y5.fsf@HIDDEN> <86iko1jp1d.fsf@HIDDEN> <87sen5b8xi.fsf@HIDDEN> <86sen5i671.fsf@HIDDEN> Date: Sat, 22 Mar 2025 21:56:27 +0100 Message-ID: <87jz8gbx8k.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 77169 Cc: 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain Eli Zaretskii <eliz@HIDDEN> writes: >> From: Daniel Mendler <mail@HIDDEN> >> Cc: 77169 <at> debbugs.gnu.org >> Date: Sat, 22 Mar 2025 12:29:13 +0100 >> >> > Thanks, but please also reflect this feature in the doc string of >> > help-at-pt-display-when-idle and in the Emacs user manual (where that >> > option is described). >> >> The question is if `help-at-pt-display-when-idle' should be marked >> obsolete in favor of the Eldoc mechanism to avoid conflicts. Eldoc is >> even preloaded these days, so the de-facto standard for documentation at >> point. > > Users can still disable ElDoc, and if they do, perhaps they would like > to have help-at-pt-display-when-idle. > > We could start the process of obsoleting help-at-pt-display-when-idle, > if we think it should be superseded by ElDoc, but that process takes > time, and in the meantime we should assume people are still using > help-at-pt-display-when-idle and need to be aware of the replacement, > and vice versa. Agree. >> > Also, shouldn't we have a user option to turn this on in ElDoc? >> >> Not sure if we need an option given that it is easy to add the function >> to the list, or remove it, if the function is enabled by default. > > It might be easy fore you and me, but not for users who are not Lisp > programmers. Okay. I have attached an updated version of the patch to this mail. I have added a customization option (off by default) and a NEWS entry. Daniel --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-New-Eldoc-function-eldoc-help-at-pt-function.patch From 8a70fb1df597257ff552a171e5da53c7bde8a057 Mon Sep 17 00:00:00 2001 From: Daniel Mendler <mail@HIDDEN> Date: Sat, 22 Mar 2025 10:29:45 +0100 Subject: [PATCH] New Eldoc function `eldoc-help-at-pt-function' Show help-at-pt string via Eldoc as an alternative to the `help-at-pt-display-when-idle' timer. The help-at-pt timer competes with Eldoc for the echo area, such that the two mechanisms do not work well together. Therefore when using Eldoc, the setting `eldoc-help-at-pt' may be preferable. * lisp/emacs-lisp/eldoc.el (eldoc-help-at-pt): New customization option. (eldoc-help-at-pt-function): New Eldoc function. (eldoc-documentation-functions): Register the new function. * lisp/help-at-pt.el (help-at-pt-display-when-idle): Mention `eldoc-help-at-pt' in the docstring. * doc/emacs/help.texi: Document `eldoc-help-at-pt'. * etc/NEWS: Announce the change. --- doc/emacs/help.texi | 4 +++- etc/NEWS | 5 +++++ lisp/emacs-lisp/eldoc.el | 14 +++++++++++++- lisp/help-at-pt.el | 6 +++++- 4 files changed, 26 insertions(+), 3 deletions(-) diff --git a/doc/emacs/help.texi b/doc/emacs/help.texi index 5c2eabb02d6..6ea7b5783c2 100644 --- a/doc/emacs/help.texi +++ b/doc/emacs/help.texi @@ -857,9 +857,11 @@ Help Echo @kindex C-h . @findex display-local-help @vindex help-at-pt-display-when-idle +@vindex eldoc-help-at-pt On terminals that don't support mouse-tracking, you can display the help text for active buffer text at point by typing @kbd{C-h .} (@code{display-local-help}). This shows the help text in the echo area. To display help text automatically whenever it is available at point, set the variable @code{help-at-pt-display-when-idle} to -@code{t}. +@code{t}. If you use Eldoc, set the variable @code{eldoc-help-at-pt} +to @code{t} instead. diff --git a/etc/NEWS b/etc/NEWS index 3b14a87dd42..8b81a130c4d 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -415,6 +415,11 @@ need to set it with 'setopt' for it to take an effect. If the docstring doesn't already mention 'setopt', the 'describe-variable' command will now add a note about this automatically. +--- +** New user option 'eldoc-help-at-pt' to show help at point via Eldoc. +When enabled, display the 'help-at-pt-kbd-string' via Eldoc. This +setting is an alternative to 'help-at-pt-display-when-idle'. + * Editing Changes in Emacs 31.1 diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el index 966158024dd..d510877d0b2 100644 --- a/lisp/emacs-lisp/eldoc.el +++ b/lisp/emacs-lisp/eldoc.el @@ -138,6 +138,12 @@ eldoc-echo-area-prefer-doc-buffer (const :tag "Skip echo area if truncating" maybe)) :version "28.1") +(defcustom eldoc-help-at-pt nil + "Show `help-at-pt-kbd-string' at point via Eldoc. +This setting is an alternative to `help-at-pt-display-when-idle'. If +the variable is t, enable the `eldoc-help-at-pt-function'." + :type 'boolean) + (defface eldoc-highlight-function-argument '((t (:inherit bold))) "Face used for the argument at point in a function's argument list. @@ -410,7 +416,7 @@ eldoc-display-message-no-interference-p (overlay-end show-paren--overlay))))))) -(defvar eldoc-documentation-functions nil +(defvar eldoc-documentation-functions (list #'eldoc-help-at-pt-function) "Hook of functions that produce doc strings. A doc string is typically relevant if point is on a function-like @@ -957,6 +963,12 @@ eldoc-print-current-symbol-info (setq eldoc--last-request-state token) (eldoc--invoke-strategy nil)))))) +(defun eldoc-help-at-pt-function (&rest _) + "Show help at point via Eldoc if `eldoc-help-at-pt' is non-nil. +Intended for `eldoc-documentation-functions' (which see)." + (when-let* ((help (and eldoc-help-at-pt (help-at-pt-kbd-string)))) + (format "Help: %s" (substitute-command-keys help)))) + ;; This section only affects ElDoc output to the echo area, as in ;; `eldoc-display-in-echo-area'. diff --git a/lisp/help-at-pt.el b/lisp/help-at-pt.el index 68054016dc5..548aa864a03 100644 --- a/lisp/help-at-pt.el +++ b/lisp/help-at-pt.el @@ -191,7 +191,11 @@ help-at-pt-display-when-idle enabling buffer local values. It sets the actual value to nil. Thus, Custom distinguishes between a nil value and other values that disable the feature, which Custom identifies with `never'. -The default is `never'." +The default is `never'. + +Eldoc uses the echo area to display help at point. As such it +competes with `help-at-pt-display-when-idle' for the echo area. +If you use Eldoc, consider setting `eldoc-help-at-pt' instead." :group 'help-at-pt :type '(choice (const :tag "Always" :format "%t\n%h" -- 2.47.2 --=-=-=--
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 22 Mar 2025 12:46:40 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 22 08:46:40 2025 Received: from localhost ([127.0.0.1]:41453 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tvyFM-0003Qk-0k for submit <at> debbugs.gnu.org; Sat, 22 Mar 2025 08:46:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48810) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tvyFI-0003QT-6k for 77169 <at> debbugs.gnu.org; Sat, 22 Mar 2025 08:46:36 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tvyFC-0003GM-4w; Sat, 22 Mar 2025 08:46:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=k7W4b6bLhe6ZjurA092T4hfP2Km1E2OMQMmncAPZrUg=; b=qv2hh+Rze2Bp DZxywYn5FIgBHvJE4Jtt2K19dpes4Cg6bYgbAHEj5bkQsZtajIA/56yKb8ekujuHUtKc9Bb6xC+Lb Qm432Fyjw4AuJaRUPRB2af2V+bTk655VbUIHBMelDeMYTejXB0n80RrqvklLi2uev5Z+T1LII8S8N ZHVie0rg24Qke9hKYYLqN9nyRwO8Ix4jRx6tTSsHYlzoXzx18FcAF91dP3CM6MpHp2XwX4PusNInR QYetoy1ThOYDh4MpvaGybgC7pda1GXv67IpuFszRK3qxf5QflDJ6bFt49TZecCSQGlGX2KYH7t2ua ebCXpEnfloDtbAIlmW+Bhg==; Date: Sat, 22 Mar 2025 14:46:26 +0200 Message-Id: <86sen5i671.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Daniel Mendler <mail@HIDDEN> In-Reply-To: <87sen5b8xi.fsf@HIDDEN> (message from Daniel Mendler on Sat, 22 Mar 2025 12:29:13 +0100) Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' References: <87r02pl7y5.fsf@HIDDEN> <86iko1jp1d.fsf@HIDDEN> <87sen5b8xi.fsf@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 77169 Cc: 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > From: Daniel Mendler <mail@HIDDEN> > Cc: 77169 <at> debbugs.gnu.org > Date: Sat, 22 Mar 2025 12:29:13 +0100 > > > Thanks, but please also reflect this feature in the doc string of > > help-at-pt-display-when-idle and in the Emacs user manual (where that > > option is described). > > The question is if `help-at-pt-display-when-idle' should be marked > obsolete in favor of the Eldoc mechanism to avoid conflicts. Eldoc is > even preloaded these days, so the de-facto standard for documentation at > point. Users can still disable ElDoc, and if they do, perhaps they would like to have help-at-pt-display-when-idle. We could start the process of obsoleting help-at-pt-display-when-idle, if we think it should be superseded by ElDoc, but that process takes time, and in the meantime we should assume people are still using help-at-pt-display-when-idle and need to be aware of the replacement, and vice versa. > > Also, shouldn't we have a user option to turn this on in ElDoc? > > Not sure if we need an option given that it is easy to add the function > to the list, or remove it, if the function is enabled by default. It might be easy fore you and me, but not for users who are not Lisp programmers. Thanks.
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 22 Mar 2025 11:29:24 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 22 07:29:23 2025 Received: from localhost ([127.0.0.1]:41122 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tvx2Z-0007Sx-GY for submit <at> debbugs.gnu.org; Sat, 22 Mar 2025 07:29:23 -0400 Received: from server.qxqx.de ([2a01:4f8:c012:9177::1]:53457 helo=mail.qxqx.de) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <mail@HIDDEN>) id 1tvx2W-0007Si-LE for 77169 <at> debbugs.gnu.org; Sat, 22 Mar 2025 07:29:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=daniel-mendler.de; s=key; h=Content-Type:MIME-Version:Message-ID:Date: References:In-Reply-To:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=wuXwSSsaG4SjqFUOGXaTx/KcA06Zqi4ZStZO76opK1M=; b=Ad+V+IrbolhifuynvWt9tRHngx C3URSoMYQWmoZYxR4fgxoPNaDTj1I3rt8u3lpysQY0Pyc0z5sNcOmsu+15/790yq98c4xjuaQpUgw fGqc+/JpG7DTZxWMWpvrwI4x3QSluDxzJSqG7MXvmhDmsLY/l/akISbuxABU0Bwh5QPQ=; From: Daniel Mendler <mail@HIDDEN> To: Eli Zaretskii <eliz@HIDDEN> Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' In-Reply-To: <86iko1jp1d.fsf@HIDDEN> (Eli Zaretskii's message of "Sat, 22 Mar 2025 13:14:06 +0200") References: <87r02pl7y5.fsf@HIDDEN> <86iko1jp1d.fsf@HIDDEN> Date: Sat, 22 Mar 2025 12:29:13 +0100 Message-ID: <87sen5b8xi.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 77169 Cc: 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) Eli Zaretskii <eliz@HIDDEN> writes: >> Date: Sat, 22 Mar 2025 10:40:18 +0100 >> From: Daniel Mendler via "Bug reports for GNU Emacs, >> the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN> >> >> This patch proposes the addition of a new Eldoc function >> `help-at-pt-eldoc-function'. >> >> Show help-at-pt string via Eldoc as an alternative to the >> `help-at-pt-display-when-idle' timer. The help-at-pt timer competes >> with Eldoc for the echo area, such that using both does not work well. >> The new `help-at-pt-eldoc-function' is meant to be added to >> `eldoc-documentation-functions'. Eli, thank you for looking at the patch so quickly. > Thanks, but please also reflect this feature in the doc string of > help-at-pt-display-when-idle and in the Emacs user manual (where that > option is described). The question is if `help-at-pt-display-when-idle' should be marked obsolete in favor of the Eldoc mechanism to avoid conflicts. Eldoc is even preloaded these days, so the de-facto standard for documentation at point. > Also, shouldn't we have a user option to turn this on in ElDoc? Not sure if we need an option given that it is easy to add the function to the list, or remove it, if the function is enabled by default. (add-hook 'eldoc-documentation-functions #'help-at-pt-eldoc-function) (remove-hook 'eldoc-documentation-functions #'help-at-pt-eldoc-function) > And what about a NEWS entry? I will add one. Daniel
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at 77169) by debbugs.gnu.org; 22 Mar 2025 11:14:25 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 22 07:14:25 2025 Received: from localhost ([127.0.0.1]:41081 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tvwo5-0003jq-9X for submit <at> debbugs.gnu.org; Sat, 22 Mar 2025 07:14:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45058) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tvwo3-0003jd-1k for 77169 <at> debbugs.gnu.org; Sat, 22 Mar 2025 07:14:23 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tvwnw-000282-7d; Sat, 22 Mar 2025 07:14:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=UTLai2+Di3dEgAN+89l+Pwt03CdBl5x1q5YElHsagu4=; b=o/9SbxRPHjhF j8dWPveCIj2J6ViYAogxMl+DdkY915k7gSyqvVulhJFnRjvuoxK7PYKgHHXXFLdlQQC1BHou/pKrM xhXkZAkjjpjSxgoa1DAEHNzvZuohsIROvglF3/Xe4BIfpTydhbDN8UlCmIU0DtxkMzMFP1CZ3fUTZ NVRaoWK6ZGvzp3PYpPP5vPkkMdqH0lfPGQVCRNbXZWYfW2jOUV0CIyxDI4+hF8SkbfDZsYgSxXg0z w2+8VR8r1kVAEbFlans7r1ryZiMvtz96rmaMRyXVT1ZFOlIeFvAdR1HWynFnYXV0wKcJ+rV4i8MCG ej2ZRDoo9oSstNLwGWSBAA==; Date: Sat, 22 Mar 2025 13:14:06 +0200 Message-Id: <86iko1jp1d.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Daniel Mendler <mail@HIDDEN> In-Reply-To: <87r02pl7y5.fsf@HIDDEN> (bug-gnu-emacs@HIDDEN) Subject: Re: bug#77169: [PATCH] New Eldoc function `help-at-pt-eldoc-function' References: <87r02pl7y5.fsf@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 77169 Cc: 77169 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Date: Sat, 22 Mar 2025 10:40:18 +0100 > From: Daniel Mendler via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN> > > This patch proposes the addition of a new Eldoc function > `help-at-pt-eldoc-function'. > > Show help-at-pt string via Eldoc as an alternative to the > `help-at-pt-display-when-idle' timer. The help-at-pt timer competes > with Eldoc for the echo area, such that using both does not work well. > The new `help-at-pt-eldoc-function' is meant to be added to > `eldoc-documentation-functions'. Thanks, but please also reflect this feature in the doc string of help-at-pt-display-when-idle and in the Emacs user manual (where that option is described). Also, shouldn't we have a user option to turn this on in ElDoc? And what about a NEWS entry?
bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 22 Mar 2025 09:40:49 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 22 05:40:49 2025 Received: from localhost ([127.0.0.1]:40871 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tvvLV-0007xO-DS for submit <at> debbugs.gnu.org; Sat, 22 Mar 2025 05:40:49 -0400 Received: from lists.gnu.org ([2001:470:142::17]:47718) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <mail@HIDDEN>) id 1tvvLT-0007xA-8e for submit <at> debbugs.gnu.org; Sat, 22 Mar 2025 05:40:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <mail@HIDDEN>) id 1tvvLN-0006oh-8u for bug-gnu-emacs@HIDDEN; Sat, 22 Mar 2025 05:40:41 -0400 Received: from server.qxqx.de ([2a01:4f8:c012:9177::1] helo=mail.qxqx.de) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <mail@HIDDEN>) id 1tvvLL-0007vY-89 for bug-gnu-emacs@HIDDEN; Sat, 22 Mar 2025 05:40:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=daniel-mendler.de; s=key; h=Content-Type:MIME-Version:Message-ID:Date: Subject:To:From:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=X/WLjeWkqswpdUO/54Ru/+lKPWKfqbJmLvAtn7xy1ws=; b=sN1pHDpEKphGiR98xOiAx0obzF bQloEq5dC+/EnWu5FArFMplc7yO6Ow0OkEkg8yuW5mT0VpEDUWaRbEtGkmZ7rUAlRUeMf2yD2jVoH YiLkVH9MeZsA9G3VmEwmcVrQHbz8m2kjY0pOIs6mWJoFrwH/TRc0NJSPdQ7c5a5G9oOA=; From: Daniel Mendler <mail@HIDDEN> To: bug-gnu-emacs@HIDDEN Subject: [PATCH] New Eldoc function `help-at-pt-eldoc-function' Date: Sat, 22 Mar 2025 10:40:18 +0100 Message-ID: <87r02pl7y5.fsf@HIDDEN> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2a01:4f8:c012:9177::1; envelope-from=mail@HIDDEN; helo=mail.qxqx.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.1 (/) --=-=-= Content-Type: text/plain Tags: patch This patch proposes the addition of a new Eldoc function `help-at-pt-eldoc-function'. Show help-at-pt string via Eldoc as an alternative to the `help-at-pt-display-when-idle' timer. The help-at-pt timer competes with Eldoc for the echo area, such that using both does not work well. The new `help-at-pt-eldoc-function' is meant to be added to `eldoc-documentation-functions'. --=-=-= Content-Type: text/patch Content-Disposition: attachment; filename=0001-New-Eldoc-function-help-at-pt-eldoc-function.patch From d3d2717d98e82ec2ac80054a08d8e7b5d215f0e4 Mon Sep 17 00:00:00 2001 From: Daniel Mendler <mail@HIDDEN> Date: Sat, 22 Mar 2025 10:29:45 +0100 Subject: [PATCH] New Eldoc function `help-at-pt-eldoc-function' Show help-at-pt string via Eldoc as an alternative to the `help-at-pt-display-when-idle' timer. The help-at-pt timer competes with Eldoc for the echo area, such that using both does not work well. The new `help-at-pt-eldoc-function' is meant to be added to `eldoc-documentation-functions': (add-to-list 'eldoc-documentation-functions 'help-at-pt-eldoc-function) * lisp/help-at-pt.el (help-at-pt-eldoc-function): New Eldoc function. * TODO: Should the new function be added to `eldoc-documentation-functions' by default, such that tooltip messages are automatically shown in the echo area when moving point over text with the `help-echo' property or overlay? * TODO: Should the `help-at-pt-timer' mechanism be deprecated in favor of Eldoc? --- lisp/help-at-pt.el | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lisp/help-at-pt.el b/lisp/help-at-pt.el index 68054016dc5..6a266114610 100644 --- a/lisp/help-at-pt.el +++ b/lisp/help-at-pt.el @@ -81,6 +81,13 @@ help-at-pt-kbd-string (echo (help-at-pt-string))) (if (and kbd (not (eq kbd t))) kbd echo))) +;;;###autoload +(defun help-at-pt-eldoc-function (&rest _) + "Show help at point via Eldoc. +Intended for `eldoc-documentation-functions' (which see)." + (when-let* ((help (help-at-pt-kbd-string))) + (format "Help: %s" (substitute-command-keys help)))) + (declare-function widget-describe "wid-edit" (&optional widget-or-pos)) (declare-function widget-at "wid-edit" (&optional pos)) -- 2.47.2 --=-=-=--
Daniel Mendler <mail@HIDDEN>
:bug-gnu-emacs@HIDDEN
.
Full text available.bug-gnu-emacs@HIDDEN
:bug#77169
; Package emacs
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.