From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ergus Newsgroups: gmane.emacs.devel Subject: resize_mini_window question Date: Fri, 18 Sep 2020 17:01:13 +0200 Message-ID: <20200918150113.4vz5vq3krfslrwdz@Ergus> References: <20200918150113.4vz5vq3krfslrwdz.ref@Ergus> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19342"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Sep 18 17:03:53 2020 Return-path: Envelope-to: ged-emacs-devel@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 1kJHvV-0004wE-9u for ged-emacs-devel@m.gmane-mx.org; Fri, 18 Sep 2020 17:03:53 +0200 Original-Received: from localhost ([::1]:49154 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJHvU-0002xG-4i for ged-emacs-devel@m.gmane-mx.org; Fri, 18 Sep 2020 11:03:52 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45008) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJHtC-0000wA-Si for emacs-devel@gnu.org; Fri, 18 Sep 2020 11:01:34 -0400 Original-Received: from sonic303-2.consmr.mail.bf2.yahoo.com ([74.6.131.41]:39359) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kJHt7-0007XQ-89 for emacs-devel@gnu.org; Fri, 18 Sep 2020 11:01:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048; t=1600441283; bh=MfeMvmCTjhgWYobjgFZ9Zskar1zRM0ztmL76/Jxrnsg=; h=Date:From:To:Cc:Subject:References:From:Subject; b=DkKSQqDnrpX+ykpjMaw4O6wjO4JTbNzUKuRGaHPtJ/0wQMLZHV8YNUVWzvm+QSJYivaTkZbBxi/VS9hylp90+cUuPUcS+17JpUKQWTOEeSsajlXmkdN5UadpdMcPW54X8aA4bdbZ6aF0/Bixikl/sHSwLq59bQZ7r5RPPf7J8Yey3kKdYbm2lpg8n7GPpIJKu1wCdKrpWfaSvXSnrV2m0cnSzSwQNB6VhxhiW+WPQ2aCipCe7yNbe1T7yxmSBEhbH3S3bdi7Y6F5MP80Er9djNQMxdwhWYWSkejYHnYAB7GvIwzTulj5F5RCriBNqD/7pMcr9DkTGimsomh0bsJTSg== X-YMail-OSG: q9YgBuIVM1kjRtw6nsWz5A8_OMPTv0ily8V5TFaIqaEpg17AXjJD7bQTduv2qTh RPA0JJyoHySxQshkmq1N_eLb7xSUk6okP27NqEAJAn7s4iZBqvFjqQc4HaoGtTyUcq61zeohe.A. J3uphCdGo5X69_x9GGGoCpAHmwPvhP5ios2tMK7TwJmnVux5oaGr__BELiR9ZS9h5fBD8XKClQtU 2Op7uDcyEcfjih9d3OBvhTr1hHznG9.o468nRZ90x3XTzb1GSLz2ISS4JjhiSf1M0yTh5IRC7uf9 niCM.jMeZhWUcaTw13Fc7U0k1XZuE.8Rd.QCLbG2cob3YK3aEMoVkgAu2m0tBURc2J6NtGUpdTLy sVhyjix0prgecxFOq8K1O9Jtmyj2_7pKDpz2NJM4ZQKNXZexo39TeR2d3j4dIPLhHkyhfXBRTyU7 HsLN2ZeGJ8ptXvIGm7X7PnE77BuMEJs5P5lyqWeIsN3gnUWzqbVL9DExsLlAqcyeeeLYhfno3Zb. QnZ_ytCmpwHcEael.WCauapegyTxJqFC5QHzjs6Z1eWAo1rz_wHc8xOnVbp.QhsrcPLFZVQlmg_H _CyT_lJTh5XOZnFJUNAfAn.LCE3ofF7IjGJzxyWZPMlgiQNjVHHr4PIjFS5.jmYdjLT55SLABpsV qS9CbyK2KuWcvYRe7aHTU1g0iChKbSHUiiMXYLqtRov22fBLbXNk6qEPk1t5e6dOXnl9zVTsDKDd TleQtOjjLyfQPJqUl.cz7FJ7heMc3tRbFMvXKfTpvaR3tO9fqLrlOM881WRc8_i7PNhKLAlMjCux NQuel2eGlKPIc9SBVVv_0opPPvZ4rKuFNQLbw5KG.S Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic303.consmr.mail.bf2.yahoo.com with HTTP; Fri, 18 Sep 2020 15:01:23 +0000 Original-Received: by smtp415.mail.ir2.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID d9488a5370402c772edcf6698394d67a; Fri, 18 Sep 2020 15:01:20 +0000 (UTC) Content-Disposition: inline X-Mailer: WebService/1.1.16583 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol Apache-HttpAsyncClient/4.1.4 (Java/11.0.7) Received-SPF: pass client-ip=74.6.131.41; envelope-from=spacibba@aol.com; helo=sonic303-2.consmr.mail.bf2.yahoo.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 11:01:23 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] 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, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:256093 Archived-At: Hi Eli: As you know I have been working in icomplete-vertical and I just received an issue that has to do with resize_mini_window function more than with icomplete. They are related with this bugs: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=24293 https://debbugs.gnu.org/cgi/bugreport.cgi?bug=39379 The problem to me seems that the function xdisp.c:resize_mini_window uses FRAME_LINE_HEIGHT(f); to resize; but in the report the user sets a different font for the minibuffer. So when it sets Vmax_mini_window_height to an int Vmax_mini_window_height * unit is a "wrong" value and the lines will not fit. I see 3 possible clean solutions: 1) Modify resize_mini_window to use the minibuffer's font size to calculate the height when Vmax_mini_window_height is an int. (don't know if it is possible to access the minibuffer font size from there or if this could produce some undesired side effect) 2) Modify the documentation of max-mini-window-height to specify that if an integer, it specifies a number of lines respecting to the frame's default font, not the minibuffer's visible lines. 3) Just force the text to fit ignoring that the number of real visible lines will be different than max-mini-window-height. (This will be seen as ignoring the max-mini-window-height) What do you think is better? Best, Ergus