Comments (10)
@lroolle After some investigation, turns out this wasn't actually a bug, it's just necessary to use zoom-mode
instead of calling zoom
directly. zoom-mode
advises pre-redisplay-function
, where it calls zoom--update
from a stable "current window".
Without this, it can lose track of the current window where complex display-buffer-alist
rules are involved. e.g. with Doom's popup manager, where display-buffer-in-side-window
is used, which will delete existing windows to redisplay them on the side of the frame, causing zoom--update
to operate out of a deleted window then throw the error.
TL;DR, this should fix it:
(use-package zoom
:hook (doom-first-input . zoom-mode)
:config
(setq zoom-size '(0.7 . 0.7)
zoom-ignored-major-modes '(dired-mode vterm-mode help-mode helpful-mode rxt-help-mode help-mode-menu org-mode)
zoom-ignored-buffer-names '("*doom:scratch*" "*info*" "*helpful variable: argv*")
zoom-ignored-buffer-name-regexps '("^\\*calc" "\\*helpful variable: .*\\*")
zoom-ignore-predicates (list (lambda () (> (count-lines (point-min) (point-max)) 20)))))
There's also no need to tamper with window-configuration-change-hook
because, unlike golden-ratio-mode, zoom doesn't add anything to it.
from zoom.
Hmm I don't see anything zoom-related in the backtrace, are you sure it is the culprit?
from zoom.
:config (remove-hook 'window-configuration-change-hook #'zoom) (add-hook 'doom-switch-window-hook #'zoom)
Moreover what's the point of this?
from zoom.
:config (remove-hook 'window-configuration-change-hook #'zoom) (add-hook 'doom-switch-window-hook #'zoom)Moreover what's the point of this?
It's doom's hooks according to this issue: @hlissner
-> doomemacs/doomemacs#2225 (comment)
Well actually after I remove these two hooks the Errors never occur. But zoom won't' work automatically any more.
Thanks for replies and due to this is doom's Issue, I'll close this issue.
from zoom.
But zoom won't' work automatically any more.
Try with:
(custom-set-variables
'(zoom-mode t))
from zoom.
But zoom won't' work automatically any more.
Try with:
(custom-set-variables '(zoom-mode t))
While seems like doom does not respect zoom-mode
on...this doesnt work automatically
from zoom.
Hmm, I'm not familiar with Doom but that's enough to make it work automatically with regular Emacs, being zoom-mode
a global minor mode.
from zoom.
@lroolle This works for me:
(use-package zoom
:hook doom-switch-window
:config
(setq zoom-size '(0.7 . 0.7)
zoom-ignored-major-modes '(dired-mode vterm-mode help-mode helpful-mode rxt-help-mode help-mode-menu org-mode)
zoom-ignored-buffer-names '("*doom:scratch*" "*info*" "*helpful variable: argv*")
zoom-ignored-buffer-name-regexps '("^\\*calc" "\\*helpful variable: .*\\*")
zoom-ignore-predicates (list (lambda () (> (count-lines (point-min) (point-max)) 20)))))
Although, that ignore predicate is pretty aggressive. I'll assume that was intended.
EDIT: Ah, I think I've found the issue; a fix'll be up shortly.
from zoom.
@hlissner Awesome!
Thanks for the following.
from zoom.
Thank you @hlissner for taking the time to dig into this.
from zoom.
Related Issues (20)
- Creating windows with C-x 3 causes Emacs to freeze and hang HOT 1
- Calling `avy-goto-char` with several windows open triggers the following error HOT 1
- Mouse click resize the windows. HOT 9
- Odd behavior of zoom HOT 1
- With zoom mode on entire buffer contents deleted HOT 4
- Zoom font-size together with windows? HOT 3
- Dired-sidebar unusable with zoom enabled HOT 16
- Org Capture Frame is showing only half HOT 5
- How to ignore ediff control panel buffer? HOT 10
- Zoom does not work with LSP buffers (dap-mode) HOT 17
- zoom-mode caused weird behavior in image-mode HOT 2
- Excluded buffer weirdness HOT 1
- Let zoom support ignore company-box HOT 3
- How do I zoom to resize when frame is less than a particular width and/or height? HOT 4
- flickering on ess-display-help-on-object HOT 3
- Not work well with minimap. (because it always balance-window whatever if ignore it) HOT 12
- i have serious issue with vterm HOT 1
- `balance-windows` calls changes layout of ignored windows (Treemacs) in an undesirable way HOT 1
- woes with helm and which-key HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zoom.