From 0eee4defb09d895b1059eac98f64225f841007ac Mon Sep 17 00:00:00 2001 From: GrĂ©goire DuchĂȘne Date: Sat, 29 Jan 2022 13:16:59 +0000 Subject: emacs: Do a better job at disabling unwanted modes --- emacs/functions.el | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'emacs/functions.el') diff --git a/emacs/functions.el b/emacs/functions.el index b322af6..37686b3 100644 --- a/emacs/functions.el +++ b/emacs/functions.el @@ -62,6 +62,11 @@ returns nil." (interactive) (modify-frame-parameters frame '((left . 0.5) (top . 0.5)))) +(defun my/disable-frame-modes () + "Disable select frame modes where appropriate." + (dolist (mode '(menu-bar-mode scroll-bar-mode tool-bar-mode)) + (when (and (fboundp mode) (symbol-value mode)) (funcall mode -1)))) + (defun my/focus-frame (&optional frame) "Focus FRAME." (interactive) -- cgit v1.2.3-70-g09d2