#6: Trigger when minibuffer appears.

Looks like recent versions of Emacs don't call the window-configuration-change-hook in that case anymore.
This commit is contained in:
Nikolaj Schumacher 2015-02-28 21:46:53 +01:00
parent ddaaebbea7
commit 0864800d63

View file

@ -37,6 +37,8 @@
;;
;;; Changes Log:
;;
;; Fix numbering of minibuffer for recent Emacs versions.
;;
;; 2013-03-23 (1.1.2)
;; Fix numbering in terminal mode with menu bar visible.
;; Add face for window number. (thanks to Chen Bin)
@ -202,12 +204,14 @@ windows to numbers."
(save-excursion
(setq window-numbering-table (make-hash-table :size 16))
(window-numbering-install-mode-line)
(add-hook 'minibuffer-setup-hook 'window-numbering-update)
(add-hook 'window-configuration-change-hook
'window-numbering-update)
(dolist (frame (frame-list))
(select-frame frame)
(window-numbering-update))))
(window-numbering-clear-mode-line)
(remove-hook 'minibuffer-setup-hook 'window-numbering-update)
(remove-hook 'window-configuration-change-hook
'window-numbering-update)
(setq window-numbering-table nil)))