From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.bugs Subject: bug#50178: 28.0.50; Size of echo area does not account for line-spacing Date: Wed, 25 Aug 2021 09:01:20 +0000 Message-ID: References: <87eeajfvbq.fsf@telefonica.net> <83a6l7vyu2.fsf@gnu.org> <87a6l7ezks.fsf@telefonica.net> <837dgax1a0.fsf@gnu.org> <875yvug2ka.fsf@telefonica.net> <83y28qvhhn.fsf@gnu.org> <871r6ig01r.fsf@telefonica.net> <83wnoavftn.fsf@gnu.org> <87wnoaeisl.fsf@telefonica.net> <83sfyyuupx.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33686"; mail-complaints-to="usenet@ciao.gmane.io" Cc: =?UTF-8?Q?=C3=93scar?= Fuentes , 50178@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Aug 25 11:02:21 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 1mIonc-0008XV-97 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 25 Aug 2021 11:02:20 +0200 Original-Received: from localhost ([::1]:49370 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mIonb-0000O4-0g for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 25 Aug 2021 05:02:19 -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 1mIonK-0000Ew-Jr for bug-gnu-emacs@gnu.org; Wed, 25 Aug 2021 05:02:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34153) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mIonK-0008Vn-Ao for bug-gnu-emacs@gnu.org; Wed, 25 Aug 2021 05:02:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mIonK-0005cU-8u for bug-gnu-emacs@gnu.org; Wed, 25 Aug 2021 05:02:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gregory Heytings Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 25 Aug 2021 09:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50178 X-GNU-PR-Package: emacs Original-Received: via spool by 50178-submit@debbugs.gnu.org id=B50178.162988208421554 (code B ref 50178); Wed, 25 Aug 2021 09:02:02 +0000 Original-Received: (at 50178) by debbugs.gnu.org; 25 Aug 2021 09:01:24 +0000 Original-Received: from localhost ([127.0.0.1]:45699 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIomi-0005ba-1x for submit@debbugs.gnu.org; Wed, 25 Aug 2021 05:01:24 -0400 Original-Received: from heytings.org ([95.142.160.155]:32786) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIomf-0005bS-Sa for 50178@debbugs.gnu.org; Wed, 25 Aug 2021 05:01:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20210101; t=1629882081; bh=H5Av06yBOPzjO+XoEGHMqhBjD1j/k+7fSkv0Qml3MWI=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=xU4ZL71yJUQi6qTrFHPsqMtCWCUsL4SRyKTFR1aOAgKeAmzbVL88cPFZcoaR6Yn9C ATHvxRzHrfemOLpgqKEoP+zsMvDFknd0dpXI5oRfjR1tPX/KLX5ZOC8vO1mRrDrp7x nS90K4dBtczJji6ATJpqRu3o4ssy+bcIawWTcN+X8ihetYQ3TeMwgD+F2uCAZsT0Xn hb4NDyooMyK3YxUVtp3PGq+lojmzg+Pz97eRLLja5gyUC+Kh4SbCl9XGoAVaELKtq8 q5yulPkF2u+2X5XN4eToWet2LRbup2i6iUqHFa8Y6BbNRX8db4nuVMPt4jmgf6JVWa DX8KPlGSGkdvg== In-Reply-To: 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:212590 Archived-At: > > To elaborate: > > (1) You first have to calculate the maximum permissible pixel height of > the echo area window from the character height of the frame where you > intend to display the completions and the value of > `max-mini-window-height' height as specified for that frame. Note that > for a minibuffer-less frame the echo area window may appear on another > frame whose character height you have to use here. > > (2) You then have to calculate the pixel height of each completion line > as if it were shown in the echo area window mentioned in (1) using > `window-text-pixel-size' and add it to some cumulative height until you > have exhausted the maximum permissible height calculated in (1). > If you can live with the fact that the last visible completion candidate is not fully displayed (which is, as Eli said, consistent with what happens in other Emacs windows), this complex procedure is not necessary anymore. You can simply set redisplay-adhoc-scroll-in-resize-mini-windows to nil and insert "enough" completion candidates. Emacs will resize the window appropriately, and the last completion candidates will not be visible.