From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#48669: Inconsistent overlay placement between minibuffer-message and set-minibuffer-message Date: Mon, 31 May 2021 23:24:14 +0300 Organization: LINKOV.NET Message-ID: <877djek6eh.fsf@mail.linkov.net> References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23126"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) Cc: 48669@debbugs.gnu.org To: =?UTF-8?Q?Jo=C3=A3o?= Guerra Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon May 31 22:32:59 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 1lnoap-0005pt-GF for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 31 May 2021 22:32:59 +0200 Original-Received: from localhost ([::1]:39704 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lnoao-0007Eh-JH for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 31 May 2021 16:32:58 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58156) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lnoZv-0005u5-JR for bug-gnu-emacs@gnu.org; Mon, 31 May 2021 16:32:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51668) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lnoZv-0006Xn-AF for bug-gnu-emacs@gnu.org; Mon, 31 May 2021 16:32:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lnoZv-0006yk-7v for bug-gnu-emacs@gnu.org; Mon, 31 May 2021 16:32:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 31 May 2021 20:32:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48669 X-GNU-PR-Package: emacs Original-Received: via spool by 48669-submit@debbugs.gnu.org id=B48669.162249308326757 (code B ref 48669); Mon, 31 May 2021 20:32:03 +0000 Original-Received: (at 48669) by debbugs.gnu.org; 31 May 2021 20:31:23 +0000 Original-Received: from localhost ([127.0.0.1]:34978 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lnoZH-0006xV-JT for submit@debbugs.gnu.org; Mon, 31 May 2021 16:31:23 -0400 Original-Received: from relay2-d.mail.gandi.net ([217.70.183.194]:49081) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lnoZ6-0006wn-R4 for 48669@debbugs.gnu.org; Mon, 31 May 2021 16:31:13 -0400 Original-Received: (Authenticated sender: juri@linkov.net) by relay2-d.mail.gandi.net (Postfix) with ESMTPSA id BECA640006; Mon, 31 May 2021 20:31:05 +0000 (UTC) In-Reply-To: ("=?UTF-8?Q?Jo=C3=A3o?= Guerra"'s message of "Wed, 26 May 2021 14:50:20 +0200") 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:207731 Archived-At: > `minibuffer-message' and `set-minibuffer-message' place the overlay > containing the message slightly differently, resulting in a different > behaviour when there are other overlays present at the end of the > minibuffer. > > The overlay created by `minibuffer-message' always gets added to the > end of the minibuffer. > The overlay created by `set-minibuffer-message' also gets added to the > end of the minibuffer, but its properties make it so that it is shown > before other overlays at the position. > This is particularly important when the user uses packages that add > overlays to the minibuffer, such as vertical completion packages like > selectrum, vertico, and others. > The way `set-minibuffer-message' configures the overlays makes it so > that the overlay is displayed before the other overlays, which I > believe is more compatible with external packages (see attached image > for a visual example). To support completion packages such as icomplete, the overlay in `set-minibuffer-message' was fixed, but not `minibuffer-message'. > Would it make sense to change this behaviour (i.e. overlay > configuration) so that it is consistent in both functions? Right, `minibuffer-message' should be consistent with `set-minibuffer-message' by copying this part: ;; Make sure the overlay with the message is displayed before ;; any other overlays in that position, in case they have ;; resize-mini-windows set to nil and the other overlay strings ;; are too long for the mini-window width. This makes sure the ;; temporary message will always be visible. (overlay-put minibuffer-message-overlay 'priority 1100)