From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "Basil L. Contovounesios" Newsgroups: gmane.emacs.bugs Subject: bug#48278: [kisara.moe] 28.0.50; Allow eldoc-echo-area-prefer-doc-buffer to work across all-frames Date: Fri, 07 May 2021 17:36:43 +0100 Message-ID: <878s4q1ox0.fsf@tcd.ie> References: <875yzuplai.fsf@kisara.moe> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20922"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 48278@debbugs.gnu.org, =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= To: mohsin kaleem Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri May 07 18:38:55 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lf3V9-0005Ie-8U for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 07 May 2021 18:38:55 +0200 Original-Received: from localhost ([::1]:49972 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lf3V6-0002yX-4Y for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 07 May 2021 12:38:52 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37344) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lf3TO-0002x1-Gx for bug-gnu-emacs@gnu.org; Fri, 07 May 2021 12:37:06 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33278) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lf3TK-0002h6-G9 for bug-gnu-emacs@gnu.org; Fri, 07 May 2021 12:37:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lf3TK-0000HL-D2 for bug-gnu-emacs@gnu.org; Fri, 07 May 2021 12:37:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: "Basil L. Contovounesios" Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 07 May 2021 16:37:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48278 X-GNU-PR-Package: emacs Original-Received: via spool by 48278-submit@debbugs.gnu.org id=B48278.16204054131059 (code B ref 48278); Fri, 07 May 2021 16:37:02 +0000 Original-Received: (at 48278) by debbugs.gnu.org; 7 May 2021 16:36:53 +0000 Original-Received: from localhost ([127.0.0.1]:44824 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lf3TB-0000H1-7B for submit@debbugs.gnu.org; Fri, 07 May 2021 12:36:53 -0400 Original-Received: from mail-wr1-f53.google.com ([209.85.221.53]:39896) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lf3T9-0000Gv-CT for 48278@debbugs.gnu.org; Fri, 07 May 2021 12:36:52 -0400 Original-Received: by mail-wr1-f53.google.com with SMTP id v12so9890766wrq.6 for <48278@debbugs.gnu.org>; Fri, 07 May 2021 09:36:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=6OciP7eY6rEFyQdLN4plTbGxf8Ek9kibCX3UDEPnFuY=; b=GICBp5puFSLKm96ngKWH/VZ9F6hJ+8yRB0e/HKk7ShcbBrYMwOwqAeiO7RdDdE/NCu S4o+zEqqPi2J9D++y3Uia93SUwtgtMDKxcWO6DH0/pjw9EzE8+0ZzWttxKwVQcI5DSwM dFtMmy27n6Gji4lBiwEnjFcGKeFt3M4X/iYcbEwkxZFL9FzQ72B9g8NgNdwvckkj+yYV diwXIeEav8HLtLie/9cAoGFlbn6HQYTVMC0soRO1/nSnbFLLiPH7bnhG+UBPIBgKtcB7 2OSAHgHFTqwoMPCLQ97I1jx/YwuzchGzFaHqjDRN+PnoPRLtepJ7O5llwZzrpSSBe3Om m5mg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=6OciP7eY6rEFyQdLN4plTbGxf8Ek9kibCX3UDEPnFuY=; b=X/Gfo6+lqIMpnX+6BmF5Dbc87QVcfZh8mcfIhxO6bLLn3iBbRD4K/2LuS8H7SoRkvx 0B1/1U0JzOL9inZDYcjMZ8np2ct6wLnOnLx61U16KCse8rh7mRvz3slkqMH+qgYEoIGd HMHl2YdjqLOzy0hoabvxm/d5JSBWbWUf2PEIisKdKJ89nOwiTo3kyarzXYqK89ysqcLS ge84+YR3bLoaW2U9W5OwrsC3IRqwthi5uqi7DCbAewzw3xFzHZpEBFEPVJauToY1n466 m0Xcr/SJ1b2VhFf8fdakr2X4fuJH/7T0QH8F5App5AsZxQQd/V8HHOoGrnrMLdUbKg8I rPzQ== X-Gm-Message-State: AOAM531vi5ptDzwnpswi+Ly8XkOwbHQ4+hDDARqdfZa6LDMr3D3f9XoG uibq42szNThmt/NKwLzZWrrotQ== X-Google-Smtp-Source: ABdhPJw2JRQZHuuWpZCAFkY0IrH5qwjg4r02jjpoIHRh/V8nxjcRiBp11ElpTq6VXClneK47YXpdPg== X-Received: by 2002:a5d:45cb:: with SMTP id b11mr13608269wrs.343.1620405405504; Fri, 07 May 2021 09:36:45 -0700 (PDT) Original-Received: from localhost ([2a02:8084:20e2:c380:d15:339e:aa10:60f1]) by smtp.gmail.com with ESMTPSA id l14sm6887179wmq.4.2021.05.07.09.36.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 07 May 2021 09:36:44 -0700 (PDT) In-Reply-To: <875yzuplai.fsf@kisara.moe> (mohsin kaleem's message of "Fri, 07 May 2021 17:21:09 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:205955 Archived-At: --=-=-= Content-Type: text/plain mohsin kaleem writes: > `eldoc-echo-area-prefer-doc-buffer` is a user option added a short while > back that lets you avoid eldoc showing in the minibuffer when an > equivalent buffer containing the eldoc output is currently visible. > However the current implementation only works for the current frame and > if eldoc-doc-buffer is visible in another emacsclient frame the > echo-area still shows eldoc messages in the current frame. [...] > We oould do this by modifying adding a new user-option or modifying > the existing option and allowing a new `'all-frames` value. > > Thoughts? I'd personally consider this a bug, since the first line of eldoc-echo-area-prefer-doc-buffer's docstring says: Prefer ElDoc's documentation buffer if it is showing in some frame. In which case I'd advocate for this simple fix: --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=eldoc.diff diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el index b4f068cf3a..cec89cf3bc 100644 --- a/lisp/emacs-lisp/eldoc.el +++ b/lisp/emacs-lisp/eldoc.el @@ -538,7 +538,7 @@ eldoc--echo-area-prefer-doc-buffer-p (and truncatedp (eq eldoc-echo-area-prefer-doc-buffer 'maybe))) - (get-buffer-window eldoc--doc-buffer))) + (get-buffer-window eldoc--doc-buffer 'visible))) (defun eldoc-display-in-echo-area (docs _interactive) "Display DOCS in echo area. --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable WDYT? Jo=C3=A3o? Thanks, --=20 Basil --=-=-=--