[emacs] Fix whitespace mode configuration.
This commit is contained in:
parent
9e44f18d11
commit
0877fd7ce4
@ -217,22 +217,23 @@
|
||||
;; White space mode & Fill mode column
|
||||
|
||||
(defun my-visual-hook ()
|
||||
(setq-default fill-column 95)
|
||||
(setq-local whitespace-line-column 95)
|
||||
(visual-line-mode t)
|
||||
;; (visual-fill-column-mode t)
|
||||
;; (visual-fill-column-mode t)
|
||||
(define-key visual-line-mode-map [remap kill-line] nil)
|
||||
(whitespace-mode t))
|
||||
|
||||
(add-hook 'before-save-hook 'whitespace-cleanup)
|
||||
|
||||
(setq-default fill-column 95)
|
||||
(setq-default whitespace-line-column 95)
|
||||
(add-hook 'python-mode-hook (lambda () (setq-local whitespace-line-column 100)))
|
||||
(add-hook 'LaTeX-mode-hook (lambda () (setq-local whitespace-line-column -1)))
|
||||
(add-hook 'markdown-mode-hook (lambda () (setq-local whitespace-line-column -1)))
|
||||
(add-hook 'web-mode-hook (lambda () (setq-local whitespace-line-column -1)))
|
||||
|
||||
(add-hook 'text-mode-hook 'my-visual-hook)
|
||||
(add-hook 'prog-mode-hook 'my-visual-hook)
|
||||
|
||||
(add-hook 'before-save-hook 'whitespace-cleanup)
|
||||
|
||||
;; Electric pair mode
|
||||
(electric-pair-mode 1)
|
||||
(show-paren-mode 1)
|
||||
|
Loading…
Reference in New Issue
Block a user