]> code.delx.au - gnu-emacs-elpa/blobdiff - packages/markchars/markchars.el
Merge commit '5c540d26479df04e7fc6b99792707457df174528'
[gnu-emacs-elpa] / packages / markchars / markchars.el
index a7b90f228afa2c6ca53d52b83e4465c418e7d5a6..974456a4442e6a9e01013e238575c307e68774c9 100644 (file)
@@ -156,8 +156,8 @@ By default it matches nonascii-chars."
   "Assign markchars confusable properties between BEG and END."
   (let* ((text (buffer-substring-no-properties beg end))
          (scripts (mapcar
-                  '(lambda (c) (aref char-script-table c))
-                  (string-to-list text)))
+                   (lambda (c) (aref char-script-table c))
+                   (string-to-list text)))
          ;; `scripts-extra' is not nil is there was more than one script
          (scripts-extra (delq (car scripts) scripts)))
     (when scripts-extra
@@ -191,12 +191,13 @@ The default is to mark nonascii chars with a magenta underline."
           (add-to-list props 'markchars))
         (font-lock-add-keywords nil markchars-used-keywords))
     (font-lock-remove-keywords nil markchars-used-keywords))
-  (font-lock-fontify-buffer))
+  (if (fboundp 'font-lock-flush)
+      (font-lock-flush) (font-lock-fontify-buffer)))
 
 ;;;###autoload
 (define-globalized-minor-mode markchars-global-mode markchars-mode
   (lambda () (markchars-mode 1))
   :group 'markchars)
 
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+(provide 'markchars)
 ;;; markchars.el ends here