Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ivy is broken with a minibuffer-only frame. #380

Closed
zhenya1007 opened this issue Feb 5, 2016 · 7 comments
Closed

Ivy is broken with a minibuffer-only frame. #380

zhenya1007 opened this issue Feb 5, 2016 · 7 comments

Comments

@zhenya1007
Copy link

I have my Emacs set up with a minibuffer-only-frame. I have just installed swiper following the recommendations from the wiki, and, when I try to get any of the swiper commands, I get the error which reads "Cannot resize the root window of a frame." The net effect is that the package is completely unusable with a minibuffer-only-frame. I am happy to experiment a bit more, and help you debug this, if you are not able to reproduce it with your set-up.

@abo-abo
Copy link
Owner

abo-abo commented Feb 5, 2016

minibuffer-only-frame

How do you set it up?

@zhenya1007
Copy link
Author

Thank you for a quick response, and apologies for not providing sufficient detail upfront!

I am able to repro using the following steps ($ is the prototypical shell prompt)

$ emacs -Q -l ivy-separate-minibuffer.el # ivy-separate-minibuffer.el.zip is attached
  • Emacs will start, and display two frames: a small frame with the minibuffer in it, and a larger frame with the scratch buffer.
  • Make sure that the scratch buffer has focus, and type "C-x C-f"

You will see that the error message "Cannot resize the root window of a frame." is displayed in the echo area (which is in the same -- smaller -- frame as the minibuffer).

For comparison, you can evaluate

(define-key ctl-x-map [(control ?f)] 'find-file)

in the scratch buffer, and type C-x C-f again.

For reference, my emacs-version is 25.1.50.1

ivy-separate-minibuffer.el.zip

@abo-abo abo-abo closed this as completed in e1c156b Feb 5, 2016
@abo-abo
Copy link
Owner

abo-abo commented Feb 5, 2016

Thanks for the details to reproduce.

Your setup feels very strange. The error is gone, but you'll have to resize the minibuffer frame manually.

@zhenya1007
Copy link
Author

Thank you for a lightning-fast turn-around on the fix! I am very impressed with your responsiveness and follow-through. I can handle resizing the minibuffer frame (the definition of window--resize-mini-window looks promising as an inspiration).

I agree that my set-up is not for everyone. It was inspired by OneOnOneEmacs, except that my actual set-up uses display-buffer-base-action and friends. I just found that I really buy into the basic premise of OneOnOneEmacs that, "windows are a work-around for not having better support for frames in terminals."

@pjones
Copy link

pjones commented Oct 11, 2018

@zhenya1007 How did you end up resolving this? I'm working through the same issue with a minibuffer frame via EXWM ch11ng/exwm#489. Thanks.

@zhenya1007
Copy link
Author

@pjones I ended up going with the competition, namely Helm; it does not (as far as I can tell) expect to be able to resize the minibuffer, so I never explored the window--resize-mini-window and friends. I realize this probably isn't the answer you were looking for, however.

@pjones
Copy link

pjones commented Oct 22, 2018

@zhenya1007, @abo-abo:

I got Ivy working with a dedicated minibuffer:

(custom-set-variables
 '(ivy-fixed-height-minibuffer nil)
 '(ivy-add-newline-after-prompt nil))

If either of these two variables are set Ivy will try to set the window height which throws an error. It would be nice if Ivy was a bit smarter about calling set-window-text-height since Emacs fully supports and even documents how to have a dedicated minibuffer.

See also ch11ng/exwm#489

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants