diff --git a/evil-escape.el b/evil-escape.el index 7e3bb79..d4023cc 100644 --- a/evil-escape.el +++ b/evil-escape.el @@ -180,13 +180,15 @@ with a key sequence." "evil-escape pre-command hook." (with-demoted-errors "evil-escape: Error %S" (when (evil-escape-p) - (let* ((modified (buffer-modified-p)) + (let* ((inhibit-redisplay t) + (fontification-functions nil) + (modified (buffer-modified-p)) (inserted (evil-escape--insert)) (fkey (elt evil-escape-key-sequence 0)) (skey (elt evil-escape-key-sequence 1)) (evt (read-event nil nil evil-escape-delay))) (when inserted (evil-escape--delete)) - (set-buffer-modified-p modified) + (restore-buffer-modified-p modified) (cond ((and (characterp evt) (or (and (equal (this-command-keys) (evil-escape--first-key))