muffinmad / emacs-mini-frame

Show minibuffer in child frame on read-from-minibuffer
GNU General Public License v3.0
314 stars 20 forks source link

Conflict with consult-imenu #69

Closed yusi1 closed 1 year ago

yusi1 commented 1 year ago

When I have mini-frame-mode enabled and call consult-imenu, this error occurs: redisplay--pre-redisplay-functions: (error "Cannot resize the root window of a frame")

Also, one thing to mention is that consult-imenu also creates it's own buffer, but the menu is available in both the mini-frame and the buffer that consult-imenu creates.

Would there be any way to disable mini-frame-mode before consult-imenu creates its own buffer?

This issue is not reproducible with standard imenu.

yusi1 commented 1 year ago

Issue occurs with consult-imenu.

https://user-images.githubusercontent.com/82241382/190871750-0d2d5183-bb73-4aba-89ce-72f318899c2a.mp4

yusi1 commented 1 year ago

Issue doesn't occur with normal imenu.

https://user-images.githubusercontent.com/82241382/190871788-c0e8c1af-531b-4ecd-bbf2-9664a4f0139e.mp4

muffinmad commented 1 year ago

I'm not familiar with consult, would be greate if you can provide some steps for reproduce this issue starting from emacs -Q.

Also you can turn off mini-frame for consult-imenu by adding consult-imenu to mini-frame-ignore-commands.

yusi1 commented 1 year ago

I'm not familiar with consult, would be greate if you can provide some steps for reproduce this issue starting from emacs -Q.

Here's a minimal config, but it seems the error didn't occur when I tried emacs -Q with this minimal config.

(require 'package)
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/"))
(package-initialize)

(package-install 'mini-frame)
(package-install 'consult)

(require 'mini-frame)
(mini-frame-mode)

(require 'consult)
(consult-imenu) ; goto a file like init.el before doing this

Also you can turn off mini-frame for consult-imenu by adding consult-imenu to mini-frame-ignore-commands.

Thank you, this is all I needed, AFAIK I don't think the issue is with either consult or mini-frame, because when I tried emacs -Q with the minimal config, the error didn't occur.

yusi1 commented 1 year ago

I think the issue is maybe with my configuration.

yusi1 commented 1 year ago

Also you can turn off mini-frame for consult-imenu by adding consult-imenu to mini-frame-ignore-commands.

This fix is fine for me and has solved the issue.