emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/font-core.el


From: Stefan Monnier
Subject: [Emacs-diffs] Changes to emacs/lisp/font-core.el
Date: Mon, 09 Sep 2002 19:22:49 -0400

Index: emacs/lisp/font-core.el
diff -c emacs/lisp/font-core.el:1.15 emacs/lisp/font-core.el:1.16
*** emacs/lisp/font-core.el:1.15        Sat Aug 31 13:22:29 2002
--- emacs/lisp/font-core.el     Mon Sep  9 19:22:49 2002
***************
*** 218,243 ****
  ;; Get rid of fontification for the old major mode.
  ;; We do this when changing major modes.
  (defun font-lock-change-mode ()
!   (let ((inhibit-read-only t)
!       (inhibit-point-motion-hooks t)
!       (inhibit-modification-hooks t)
!       (deactivate-mark nil)
!       (buffer-file-name nil)
!       (buffer-file-truename nil)
!       (buffer-undo-list t)
!       (modified (buffer-modified-p)))
!     (save-restriction
!       (widen)
!       (remove-list-of-text-properties
!        (point-min) (point-max) '(font-lock-face)))
!     (unless modified
!       (restore-buffer-modified-p nil)))
!   (when font-lock-defaults
!     (font-lock-unfontify-buffer)))
  
! (defun font-lock-default-function (font-lock-mode)
    ;; Turn on Font Lock mode.
!   (when font-lock-mode
      (font-lock-set-defaults)
      (set (make-local-variable 'char-property-alias-alist)
         (copy-tree char-property-alias-alist))
--- 218,228 ----
  ;; Get rid of fontification for the old major mode.
  ;; We do this when changing major modes.
  (defun font-lock-change-mode ()
!   (font-lock-mode -1))
  
! (defun font-lock-default-function (mode)
    ;; Turn on Font Lock mode.
!   (when mode
      (font-lock-set-defaults)
      (set (make-local-variable 'char-property-alias-alist)
         (copy-tree char-property-alias-alist))
***************
*** 262,268 ****
               (message "Fontifying %s...buffer size greater than 
font-lock-maximum-size"
                        (buffer-name)))))))
    ;; Turn off Font Lock mode.
!   (unless font-lock-mode
      ;; Remove `font-lock-face' as an alias for the `face' property.
      (set (make-local-variable 'char-property-alias-alist)
         (copy-tree char-property-alias-alist))
--- 247,253 ----
               (message "Fontifying %s...buffer size greater than 
font-lock-maximum-size"
                        (buffer-name)))))))
    ;; Turn off Font Lock mode.
!   (unless mode
      ;; Remove `font-lock-face' as an alias for the `face' property.
      (set (make-local-variable 'char-property-alias-alist)
         (copy-tree char-property-alias-alist))




reply via email to

[Prev in Thread] Current Thread [Next in Thread]