设置默认关闭auto-fill-mode

设置默认关闭auto-fill-mode

;;disable autofill-mode
(add-hook 'org-mode-hook (lambda () (auto-fill-mode nil)))

不起作用.

关闭 Minor Mode 得用 (foo-mode -1),以下都是开启 Minor Mode

(foo-mode)
(foo-mode nil)
(foo-mode +1)

也就是只和 0 和负整数才能关闭一个 Minor Mode,其它情况一律开启。C-h f auto-fill-mode 提示:

If called from Lisp, toggle the mode if ARG is ‘toggle’, disable the mode if ARG is a non-positive integer, and enable the mode otherwise (including if ARG is omitted or nil or a positive integer).

2 个赞