fix(spell): spell-fu: remove unneeded advice
These issues were addressed upstream. Ref: emacsmirror/spell-fu@50be652a6e Ref: emacsmirror/spell-fu@00af362af3
This commit is contained in:
parent
ee03e83847
commit
7ed7b38999
1 changed files with 0 additions and 22 deletions
|
@ -135,28 +135,6 @@
|
||||||
prog-mode-hook)
|
prog-mode-hook)
|
||||||
#'spell-fu-mode))
|
#'spell-fu-mode))
|
||||||
:config
|
:config
|
||||||
;; TODO PR this fix upstream!
|
|
||||||
(defadvice! +spell--fix-face-detection-a (fn &rest args)
|
|
||||||
"`spell-fu--faces-at-point' uses face detection that won't penetrary
|
|
||||||
overlays (like `hl-line'). This makes `spell-fu-faces-exclude' demonstrably less
|
|
||||||
useful when it'll still spellcheck excluded faces on any line that `hl-line' is
|
|
||||||
displayed on, even momentarily."
|
|
||||||
:around #'spell-fu--faces-at-point
|
|
||||||
(letf! (defun get-char-property (pos prop &optional obj)
|
|
||||||
(or (plist-get (text-properties-at pos) prop)
|
|
||||||
(funcall get-char-property pos prop obj)))
|
|
||||||
(apply fn args)))
|
|
||||||
|
|
||||||
(defadvice! +spell--create-word-dict-a (_word words-file _action)
|
|
||||||
"Prevent `spell-fu--word-add-or-remove' from throwing non-existant
|
|
||||||
directory errors when writing a personal dictionary file (by creating the
|
|
||||||
directory first)."
|
|
||||||
:before #'spell-fu--word-add-or-remove
|
|
||||||
(unless (file-exists-p words-file)
|
|
||||||
(make-directory (file-name-directory words-file) t)
|
|
||||||
(with-temp-file words-file
|
|
||||||
(insert (format "personal_ws-1.1 %s 0\n" ispell-dictionary)))))
|
|
||||||
|
|
||||||
(add-hook! 'spell-fu-mode-hook
|
(add-hook! 'spell-fu-mode-hook
|
||||||
(defun +spell-init-excluded-faces-h ()
|
(defun +spell-init-excluded-faces-h ()
|
||||||
"Set `spell-fu-faces-exclude' according to `+spell-excluded-faces-alist'."
|
"Set `spell-fu-faces-exclude' according to `+spell-excluded-faces-alist'."
|
||||||
|
|
Loading…
Reference in a new issue