summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/general.el6
-rw-r--r--lisp/text.el13
2 files changed, 6 insertions, 13 deletions
diff --git a/lisp/general.el b/lisp/general.el
index 6a7a3a7..d7e74d4 100644
--- a/lisp/general.el
+++ b/lisp/general.el
@@ -82,6 +82,12 @@
;; Line numbers
(global-display-line-numbers-mode 1)
+;; Margin
+(use-package perfect-margin
+ :ensure t
+ :config
+ (perfect-margin-mode t))
+
;; Show number of matches
(setq isearch-lazy-highlight t)
(setq isearch-lazy-count t)
diff --git a/lisp/text.el b/lisp/text.el
index 6a9858c..8a0274c 100644
--- a/lisp/text.el
+++ b/lisp/text.el
@@ -2,22 +2,10 @@
;;; Code:
(defun setup-text-mode ()
"Disable word wrap in text mode."
- ;(perfect-margin-mode 1)
(setq word-wrap t)
(display-line-numbers-mode -1)
)
-(defun my-perfect-margin-mode-hook()
- (when (and (stringp buffer-file-name)
- (string-match "\\.txt\\'" buffer-file-name))
- (perfect-margin-mode 1))
- )
-
-(use-package perfect-margin
- :ensure t
- :config
- (add-hook 'text-mode-hook 'my-perfect-margin-mode-hook))
-
(add-hook 'text-mode-hook 'setup-text-mode)
(use-package ispell
:ensure t
@@ -26,7 +14,6 @@
ispell-dictionary "en_US")
)
-
(use-package flyspell
:ensure t
:hook (text-mode . flyspell-mode)