GNU bug report logs - #44080
27.1; Display behavior of overlays `after-string` in resizable minibuffer frames

Previous Next

Package: emacs;

Reported by: Clemens <clemens.radermacher <at> posteo.de>

Date: Mon, 19 Oct 2020 18:40:02 UTC

Severity: normal

Found in version 27.1

Done: Clemens <clemens.radermacher <at> posteo.de>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 44080 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Clemens <clemens.radermacher <at> posteo.de>, martin rudalics <rudalics <at> gmx.at>
Cc: 44080 <at> debbugs.gnu.org
Subject: Re: bug#44080: 27.1;
 Display behavior of overlays `after-string` in resizable minibuffer
 frames
Date: Mon, 19 Oct 2020 22:43:41 +0300
> From: Clemens <clemens.radermacher <at> posteo.de>
> Date: Mon, 19 Oct 2020 20:39:15 +0200
> 
> 1. `emacs -Q --eval "(setq default-frame-alist '((minibuffer . nil)))"`
> 2. `eval-buffer` with following code:
> 
> ```elisp
> (setq resize-mini-frames t)
> 
> (defvar ov (make-overlay (point-min) (point-min) nil t t))
> 
> (minibuffer-with-setup-hook
>      (lambda ()
>        (move-overlay ov
> 		    (point-max)
> 		    (point-max)
> 		    (current-buffer))
>         ;; Note the initial newline...
>        (overlay-put ov 'after-string "\nHey there, I'm hidden initially 
> and will hide again after any space in the input"))
>    (read-string "Hi? "))
> ```
> 
> 3. Start typing
> 
> As stated in the after-string text, it is initially hidden, shows when 
> you input some text and gets hidden again every time you type a space.

It looks like the problem is in fit-frame-to-buffer: it is not
prepared to handle after-string at the end of the prompt.
Specifically, the fact that the 2nd and the 3rd args of the call to
window-text-pixel-size are both t causes the function to return the
value which doesn't account for the after-string.




This bug report was last modified 4 years and 266 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.