]> code.delx.au - gnu-emacs/blobdiff - lisp/obsolete/lazy-lock.el
Merge from emacs--rel--22
[gnu-emacs] / lisp / obsolete / lazy-lock.el
index 2daf779bc73bc57e9254a14035fc286e5cdfdf28..e048b4e82ca2aeb994947da8371922f65fe7438e 100644 (file)
@@ -1,7 +1,7 @@
 ;;; lazy-lock.el --- lazy demand-driven fontification for fast Font Lock mode
 
 ;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 2001, 2002, 2003, 2004,
-;;   2005 Free Software Foundation, Inc.
+;;   2005, 2006, 2007 Free Software Foundation, Inc.
 
 ;; Author: Simon Marshall <simon@gnu.org>
 ;; Maintainer: FSF
@@ -12,7 +12,7 @@
 
 ;; GNU Emacs is free software; you can redistribute it and/or modify
 ;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
+;; the Free Software Foundation; either version 3, or (at your option)
 ;; any later version.
 
 ;; GNU Emacs is distributed in the hope that it will be useful,
@@ -299,6 +299,10 @@ until TEST returns nil."
    `(while (progn ,@body ,test)))
  (put 'do-while 'lisp-indent-function (get 'while 'lisp-indent-function)))
 
+(defgroup lazy-lock nil
+  "Font Lock support mode to fontify lazily."
+  :group 'font-lock)
+
 (defvar lazy-lock-mode nil)                    ; Whether we are turned on.
 (defvar lazy-lock-buffers nil)                 ; For deferral.
 (defvar lazy-lock-timers (cons nil nil))       ; For deferral and stealth.
@@ -522,8 +526,8 @@ verbosity is controlled via the variable `lazy-lock-stealth-verbose'."
                   (if arg (> (prefix-numeric-value arg) 0) (not was-on)))))
     (cond ((and now-on (not font-lock-mode))
           ;; Turned on `lazy-lock-mode' rather than `font-lock-mode'.
-          (let ((font-lock-support-mode 'lazy-lock-mode))
-            (font-lock-mode t)))
+           (message "Use font-lock-support-mode rather than calling lazy-lock-mode")
+           (sit-for 2))
          (now-on
           ;; Turn ourselves on.
           (set (make-local-variable 'lazy-lock-mode) t)
@@ -1050,5 +1054,5 @@ verbosity is controlled via the variable `lazy-lock-stealth-verbose'."
 
 (provide 'lazy-lock)
 
-;;; arch-tag: c1776846-f046-4a45-9684-54b951b12fc9
+;; arch-tag: c1776846-f046-4a45-9684-54b951b12fc9
 ;;; lazy-lock.el ends here