From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#43572: Feature request: make it possible to choose whether the first lines of the minibuffer should be displayed instead of the last ones Date: Wed, 23 Sep 2020 16:00:55 -0400 Message-ID: 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="27729"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 43572@debbugs.gnu.org To: Gregory Heytings Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Sep 23 22:02:23 2020 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 1kLAy7-00078A-CE for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Sep 2020 22:02:23 +0200 Original-Received: from localhost ([::1]:36496 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kLAy4-0004fp-Kb for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Sep 2020 16:02:20 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45264) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kLAxn-0004eU-5O for bug-gnu-emacs@gnu.org; Wed, 23 Sep 2020 16:02:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:54653) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kLAxm-0003Vf-9H for bug-gnu-emacs@gnu.org; Wed, 23 Sep 2020 16:02:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kLAxm-0000gO-5j for bug-gnu-emacs@gnu.org; Wed, 23 Sep 2020 16:02:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Sep 2020 20:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43572 X-GNU-PR-Package: emacs Original-Received: via spool by 43572-submit@debbugs.gnu.org id=B43572.16008912722527 (code B ref 43572); Wed, 23 Sep 2020 20:02:02 +0000 Original-Received: (at 43572) by debbugs.gnu.org; 23 Sep 2020 20:01:12 +0000 Original-Received: from localhost ([127.0.0.1]:37966 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kLAwv-0000eb-Cw for submit@debbugs.gnu.org; Wed, 23 Sep 2020 16:01:12 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:64825) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kLAwq-0000dq-Ds for 43572@debbugs.gnu.org; Wed, 23 Sep 2020 16:01:08 -0400 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 825EB440708; Wed, 23 Sep 2020 16:00:58 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id D0186440587; Wed, 23 Sep 2020 16:00:56 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1600891256; bh=2Hl3Px60TBw7dA3Di7aZNJ5YzZN8Y7dNO9IqKOSEbRQ=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=UZJqd9R1q1QNmfWFPxlfHd0keqeqM5kYPNZV8C0xonzGfGoZYZ5Wz+ZPLuSN1v7rC L34Y638gbB0lQrs7XSDzKua211QyuBTFfzQH59zbfK51vfBionQxdOfZqv9Ze7MkEt 8vA58envzOqFHuuHiEutKSuX1AF23326nemplHQCJQRlWQ7b+/6A5ClorDyyhwZW6M q7PDAwIc+wieez3LQEzS0s/PcF0ginM/3dJ3FlIeoKgyCDxVflwd0DPjYzsDat2W0u usE7uPGm6Q4RFHhQqi3ADYeqJ4IYNAybwLXjK4ZD7onk5TRTd1X2wJQ3/nM6+j3YYA u33T0F+d6ifFQ== Original-Received: from alfajor (unknown [45.72.232.131]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 55A03120298; Wed, 23 Sep 2020 16:00:56 -0400 (EDT) In-Reply-To: (Gregory Heytings's message of "Wed, 23 Sep 2020 19:46:18 +0000") 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:188827 Archived-At: >> src/emacs -Q --eval '(setq max-mini-window-height 2)' -f icomplete-mode >> C-x C-f >> lisp/progmodes/../progmodes/../progmodes/../progmodes/../progmodes/../progmodes/../progmodes/../progmodes/../progmodes/../ >> >> where we see the whole of icomplete's overlay rather than seeing the whole >> of the minibuffer's actual content. >> > > The problem is that such a recipe would only work with a not-too-wide Emacs > frame and a not-too-small default font. For example, on my computer, it > does not demonstrate the problem. Really? Despite the `-Q`? Is it using a proportional font? How many columns wide is the frame? Oh, wait, is it because you're running that Emacs session in a tty rather than in a GUI? >>> The attached patch does not change the behavior of Emacs in any way, >>> unless the feature it introduces is used. >> I see the following potential problem with it: icomplete will likely want >> to set it globally, but that means it will also affect uses of the mini >> window where icomplete is not used. Also, potential other users may >> encounter similar difficulties. > No, if you look at the patch its value is reset to nil whenever the > minibuffer is entered. That still leaves the non-minibuffer uses of the mini window (i.e. the echo area). And of course, that will also result in the use of an incorrect value when you exit a *nested* minibuffer (unless both minibuffers were using the same value). >> I don't have a patch to suggest, but I think ideally, I'd want clients >> like icomplete to tell the redisplay either something like "please display >> as much as possible of *this* chunk of text" or maybe "feel free not to >> display all of this overlay, it's not super important". > > Yes, that's the point. The patch I proposed tells redisplay "please display > as much as possible of the text between BOB and point", when the current > behavior tells redisplay "please display as much as possible of the text > between point and EOB". Something more fine-grained would of course be > possible, but I don't think it is a good idea to implement a feature when > there is no clear need for it. I think what I was getting at is that this "request" should come from the minibuffer's text rather than from a variable. Stefan