unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#28978: 26.0; Regression: separate, dedicated `*Completions*' frame no longer has parameter `minibuffer'
@ 2017-10-24 20:20 Drew Adams
  2017-10-25  7:45 ` martin rudalics
  0 siblings, 1 reply; 17+ messages in thread
From: Drew Adams @ 2017-10-24 20:20 UTC (permalink / raw)
  To: 28978

In my code I check (essentially) this:

(let ((swin  (selected-window)))
  (when (window-minibuffer-p swin) (setq swin  (minibuffer-selected-window)))
  (and (get-buffer-window "*Completions*")
       (window-live-p swin)
       (not (eq (window-buffer swin) (get-buffer "*Completions*")))
       (interactive-p)))

It does what I expect in all Emacs releases, but not in this
prerelease.  My `*Completions*' window is in its own one-window frame,
with the window dedicated.  Input for that frame is redirected to my
standalone minibuffer frame.

It should be the case in my context that this returns the minibuffer
window:

(cdr (assoc 'minibuffer (frame-parameters
                          (#<frame *Completions* 000000000cacf6c8>))))

Instead, it now returns nil.  Parameter `minibuffer' for the
`*Completions*' frame is no longer the minibuffer window; it is nil.

This is the code that redirects the frame focus, which I guess is
relevant:

(let ((redirect  (if (active-minibuffer-window)
                     1on1-minibuffer-frame
                   (and completion-reference-buffer
                        (get-buffer-window completion-reference-buffer 'visible)
                        (not (eq (get-buffer "*Completions*") completion-reference-buffer))
                        (window-frame (get-buffer-window completion-reference-buffer t))))))
  (when redirect (redirect-frame-focus (selected-frame) redirect)))

That code is in a function, `1on1-display-*Completions*-frame',
that I use with `special-display-buffer-names':

(add-to-list 'special-display-buffer-names
             `("*Completions*" 1on1-display-*Completions*-frame
               ((background-color ,@1on1-completions-frame-background)
                (mouse-color      ,@1on1-completions-frame-mouse+cursor-color)
                (cursor-color     ,@1on1-completions-frame-mouse+cursor-color)
                (menu-bar-lines . 0) (tool-bar-lines . 0) ; No menu bar or tool bar.
                ,@(and 1on1-completions-frame-width
                       `((width   ,@1on1-completions-frame-width))))))

In GNU Emacs 26.0.90 (build 3, x86_64-w64-mingw32)
 of 2017-10-13
Repository revision: 906224eba147bdfc0514090064e8e8f53160f1d4
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --without-dbus --host=x86_64-w64-mingw32
 --without-compress-install 'CFLAGS=-O2 -static -g3''





^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2017-10-30 19:16 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-24 20:20 bug#28978: 26.0; Regression: separate, dedicated `*Completions*' frame no longer has parameter `minibuffer' Drew Adams
2017-10-25  7:45 ` martin rudalics
2017-10-25 14:47   ` Drew Adams
2017-10-26  7:57     ` martin rudalics
2017-10-26 14:01       ` Drew Adams
2017-10-27  8:25         ` martin rudalics
2017-10-27 14:19           ` Drew Adams
2017-10-28  8:45             ` martin rudalics
2017-10-28 19:15               ` Drew Adams
2017-10-29 11:18                 ` martin rudalics
2017-10-29 15:59                   ` Drew Adams
2017-10-29 18:13                     ` martin rudalics
2017-10-29 23:56                       ` Drew Adams
2017-10-30  8:24                         ` martin rudalics
2017-10-30 14:32                           ` Drew Adams
2017-10-30 19:00                             ` martin rudalics
2017-10-30 19:16                               ` Drew Adams

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).