Function: flyspell-check-pre-word-p
flyspell-check-pre-word-p is a byte-compiled function defined in
flyspell.el.gz.
Signature
(flyspell-check-pre-word-p)
Documentation
Return non-nil if we should check the word before point.
More precisely, it applies to the word that was before point before the current command.
Source Code
;; Defined in /usr/src/emacs/lisp/textmodes/flyspell.el.gz
;;*---------------------------------------------------------------------*/
;;* flyspell-check-pre-word-p ... */
;;*---------------------------------------------------------------------*/
(defun flyspell-check-pre-word-p ()
"Return non-nil if we should check the word before point.
More precisely, it applies to the word that was before point
before the current command."
(let ((ispell-otherchars (ispell-get-otherchars)))
(cond
((not (and (numberp flyspell-pre-point)
(eq flyspell-pre-buffer (current-buffer))))
nil)
((and (eq flyspell-pre-pre-point flyspell-pre-point)
(eq flyspell-pre-pre-buffer flyspell-pre-buffer))
nil)
((or (and (= flyspell-pre-point (- (point) 1))
(or (eq (char-syntax (char-after flyspell-pre-point)) ?w)
(and (not (string= "" ispell-otherchars))
(string-match
ispell-otherchars
(buffer-substring-no-properties
flyspell-pre-point (1+ flyspell-pre-point))))))
(= flyspell-pre-point (point))
(= flyspell-pre-point (+ (point) 1)))
nil)
((and (symbolp this-command)
(not executing-kbd-macro)
(or (get this-command 'flyspell-delayed)
(and (get this-command 'flyspell-deplacement)
(eq flyspell-previous-command this-command)))
(or (= (current-column) 0)
(= (current-column) flyspell-pre-column)
;; If other post-command-hooks change the buffer,
;; flyspell-pre-point can lie past eob (bug#468).
(null (char-after flyspell-pre-point))
(or (eq (char-syntax (char-after flyspell-pre-point)) ?w)
(and (not (string= "" ispell-otherchars))
(string-match
ispell-otherchars
(buffer-substring-no-properties
flyspell-pre-point (1+ flyspell-pre-point)))))))
nil)
((not (eq (current-buffer) flyspell-pre-buffer))
t)
((not (and (numberp flyspell-word-cache-start)
(numberp flyspell-word-cache-end)))
t)
(t
(or (< flyspell-pre-point flyspell-word-cache-start)
(> flyspell-pre-point flyspell-word-cache-end))))))