From 9b0aaee631936fc13e57a94fddeef2a06ba9fe83 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sun, 24 Sep 2017 15:26:04 +0200 Subject: [PATCH] Fix neotree window shrinking when closing splits Caused when rebalancing windows with sub-character-width fringes. Fixed by forcibly resizing the neotree window to the correct width each time it is restored by doom*popup-save. --- core/core-popups.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/core-popups.el b/core/core-popups.el index 40515b7cc..f8148898d 100644 --- a/core/core-popups.el +++ b/core/core-popups.el @@ -515,7 +515,10 @@ the command buffer." "Repair neotree state whenever its popup state is restored. This ensures that `doom*popup-save' won't break it." (when (equal (buffer-name) neo-buffer-name) - (setq neo-global--window (selected-window)))) + (setq neo-global--window (selected-window)) + ;; Fix neotree shrinking when closing nearby vertical splits + (when neo-window-fixed-size + (doom-resize-window neo-global--window neo-window-width t t)))) (add-hook 'doom-popup-mode-hook #'+evil|neotree-fix-popup))