mirror of
https://github.com/masscollaborationlabs/emacs.git
synced 2025-07-04 11:23:24 +00:00
Delete obsolete variable font-lock-maximum-size
* lisp/font-lock.el (font-lock-maximum-size): Delete variable obsolete since 24.1. (font-lock-initial-fontify): * lisp/mail/rmail.el (rmail-variables): * lisp/mh-e/mh-mime.el (mh-small-show-buffer-p): Don't use above deleted variable. * lisp/font-core.el (font-lock-mode): * lisp/font-lock.el: * lisp/info.el: Don't mention above deleted variable.
This commit is contained in:
parent
5f8922b9e2
commit
76ca5f5ece
6 changed files with 10 additions and 53 deletions
3
etc/NEWS
3
etc/NEWS
|
@ -2276,7 +2276,8 @@ This change is now applied in 'dired-insert-directory'.
|
||||||
'deferred-action-function', 'dired-x-submit-report',
|
'deferred-action-function', 'dired-x-submit-report',
|
||||||
'eieio-defgeneric', 'eieio-defmethod', 'emacs-lock-from-exiting',
|
'eieio-defgeneric', 'eieio-defmethod', 'emacs-lock-from-exiting',
|
||||||
'erc-complete-word', 'eshell-cmpl-suffix-list', 'eshell-for',
|
'erc-complete-word', 'eshell-cmpl-suffix-list', 'eshell-for',
|
||||||
'gnus-carpal', 'gnus-debug-exclude-variables', 'gnus-debug-files',
|
'font-lock-maximum-size', 'gnus-carpal',
|
||||||
|
'gnus-debug-exclude-variables', 'gnus-debug-files',
|
||||||
'gnus-local-domain', 'gnus-outgoing-message-group',
|
'gnus-local-domain', 'gnus-outgoing-message-group',
|
||||||
'gnus-registry-user-format-function-M', 'image-extension-data',
|
'gnus-registry-user-format-function-M', 'image-extension-data',
|
||||||
'image-library-alist', 'inhibit-first-line-modes-regexps',
|
'image-library-alist', 'inhibit-first-line-modes-regexps',
|
||||||
|
|
|
@ -105,8 +105,7 @@ example, put in your ~/.emacs:
|
||||||
Where major modes support different levels of fontification, you
|
Where major modes support different levels of fontification, you
|
||||||
can use the variable `font-lock-maximum-decoration' to specify
|
can use the variable `font-lock-maximum-decoration' to specify
|
||||||
which level you generally prefer. When you turn Font Lock mode
|
which level you generally prefer. When you turn Font Lock mode
|
||||||
on/off the buffer is fontified/defontified, though fontification
|
on/off the buffer is fontified/defontified.
|
||||||
occurs only if the buffer is less than `font-lock-maximum-size'.
|
|
||||||
|
|
||||||
To add your own highlighting for some major mode, and modify the
|
To add your own highlighting for some major mode, and modify the
|
||||||
highlighting selected automatically via the variable
|
highlighting selected automatically via the variable
|
||||||
|
|
|
@ -47,9 +47,9 @@
|
||||||
;;
|
;;
|
||||||
;; Fontification for a particular mode may be available in a number of levels
|
;; Fontification for a particular mode may be available in a number of levels
|
||||||
;; of decoration. The higher the level, the more decoration, but the more time
|
;; of decoration. The higher the level, the more decoration, but the more time
|
||||||
;; it takes to fontify. See the variable `font-lock-maximum-decoration', and
|
;; it takes to fontify. See the variable `font-lock-maximum-decoration'.
|
||||||
;; also the variable `font-lock-maximum-size'. Support modes for Font Lock
|
;; Support modes for Font Lock mode can be used to speed up Font Lock
|
||||||
;; mode can be used to speed up Font Lock mode. See `font-lock-support-mode'.
|
;; mode. See `font-lock-support-mode'.
|
||||||
|
|
||||||
;;;; How Font Lock mode fontifies:
|
;;;; How Font Lock mode fontifies:
|
||||||
|
|
||||||
|
@ -228,32 +228,6 @@
|
||||||
|
|
||||||
;; User variables.
|
;; User variables.
|
||||||
|
|
||||||
(defcustom font-lock-maximum-size 256000
|
|
||||||
"Maximum buffer size for unsupported buffer fontification.
|
|
||||||
When `font-lock-support-mode' is nil, only buffers smaller than
|
|
||||||
this are fontified. This variable has no effect if a Font Lock
|
|
||||||
support mode (usually `jit-lock-mode') is enabled.
|
|
||||||
|
|
||||||
If nil, means size is irrelevant.
|
|
||||||
If a list, each element should be a cons pair of the form (MAJOR-MODE . SIZE),
|
|
||||||
where MAJOR-MODE is a symbol or t (meaning the default). For example:
|
|
||||||
((c-mode . 256000) (c++-mode . 256000) (rmail-mode . 1048576))
|
|
||||||
means that the maximum size is 250K for buffers in C or C++ modes, one megabyte
|
|
||||||
for buffers in Rmail mode, and size is irrelevant otherwise."
|
|
||||||
:type '(choice (const :tag "none" nil)
|
|
||||||
(integer :tag "size")
|
|
||||||
(repeat :menu-tag "mode specific" :tag "mode specific"
|
|
||||||
:value ((t . nil))
|
|
||||||
(cons :tag "Instance"
|
|
||||||
(radio :tag "Mode"
|
|
||||||
(const :tag "all" t)
|
|
||||||
(symbol :tag "name"))
|
|
||||||
(radio :tag "Size"
|
|
||||||
(const :tag "none" nil)
|
|
||||||
(integer :tag "size")))))
|
|
||||||
:group 'font-lock)
|
|
||||||
(make-obsolete-variable 'font-lock-maximum-size nil "24.1")
|
|
||||||
|
|
||||||
(defcustom font-lock-maximum-decoration t
|
(defcustom font-lock-maximum-decoration t
|
||||||
"Maximum decoration level for fontification.
|
"Maximum decoration level for fontification.
|
||||||
If nil, use the default decoration (typically the minimum available).
|
If nil, use the default decoration (typically the minimum available).
|
||||||
|
@ -695,15 +669,9 @@ be enabled."
|
||||||
;; The first fontification after turning the mode on. This must
|
;; The first fontification after turning the mode on. This must
|
||||||
;; only be called after the mode hooks have been run.
|
;; only be called after the mode hooks have been run.
|
||||||
(when (and font-lock-mode
|
(when (and font-lock-mode
|
||||||
(font-lock-specified-p t))
|
(font-lock-specified-p t)
|
||||||
(let ((max-size (font-lock-value-in-major-mode font-lock-maximum-size)))
|
(not font-lock-fontified))
|
||||||
(cond (font-lock-fontified
|
(with-no-warnings (font-lock-fontify-buffer))))
|
||||||
nil)
|
|
||||||
((or (null max-size) (> max-size (buffer-size)))
|
|
||||||
(with-no-warnings (font-lock-fontify-buffer)))
|
|
||||||
(font-lock-verbose
|
|
||||||
(message "Fontifying %s...buffer size greater than font-lock-maximum-size"
|
|
||||||
(buffer-name)))))))
|
|
||||||
|
|
||||||
(defun font-lock-mode-internal (arg)
|
(defun font-lock-mode-internal (arg)
|
||||||
;; Turn on Font Lock mode.
|
;; Turn on Font Lock mode.
|
||||||
|
|
|
@ -133,8 +133,6 @@ orientation. See `Info-nth-menu-item'.")
|
||||||
:version "22.1"
|
:version "22.1"
|
||||||
:type 'boolean)
|
:type 'boolean)
|
||||||
|
|
||||||
;; It's unfortunate that nil means no fontification, as opposed to no limit,
|
|
||||||
;; since that differs from font-lock-maximum-size.
|
|
||||||
(defcustom Info-fontify-maximum-menu-size 400000
|
(defcustom Info-fontify-maximum-menu-size 400000
|
||||||
"Maximum size of menu to fontify if `font-lock-mode' is non-nil.
|
"Maximum size of menu to fontify if `font-lock-mode' is non-nil.
|
||||||
Set to nil to disable node fontification; set to t for no limit."
|
Set to nil to disable node fontification; set to t for no limit."
|
||||||
|
|
|
@ -1451,7 +1451,6 @@ If so restore the actual mbox message collection."
|
||||||
(setq-local font-lock-defaults
|
(setq-local font-lock-defaults
|
||||||
'(rmail-font-lock-keywords
|
'(rmail-font-lock-keywords
|
||||||
t t nil nil
|
t t nil nil
|
||||||
(font-lock-maximum-size . nil)
|
|
||||||
(font-lock-dont-widen . t)
|
(font-lock-dont-widen . t)
|
||||||
(font-lock-inhibit-thing-lock . (lazy-lock-mode fast-lock-mode))))
|
(font-lock-inhibit-thing-lock . (lazy-lock-mode fast-lock-mode))))
|
||||||
(setq-local require-final-newline nil)
|
(setq-local require-final-newline nil)
|
||||||
|
|
|
@ -1141,15 +1141,7 @@ this ;-)"
|
||||||
"Check if show buffer is small.
|
"Check if show buffer is small.
|
||||||
This is used to decide if smileys and graphical emphasis should be
|
This is used to decide if smileys and graphical emphasis should be
|
||||||
displayed."
|
displayed."
|
||||||
(let ((max nil))
|
(>= 32000 (buffer-size)))
|
||||||
;; FIXME: font-lock-maximum-size is obsolete.
|
|
||||||
(when (and (boundp 'font-lock-maximum-size) font-lock-maximum-size)
|
|
||||||
(cond ((numberp font-lock-maximum-size)
|
|
||||||
(setq max font-lock-maximum-size))
|
|
||||||
((listp font-lock-maximum-size)
|
|
||||||
(setq max (cdr (or (assoc 'mh-show-mode font-lock-maximum-size)
|
|
||||||
(assoc t font-lock-maximum-size)))))))
|
|
||||||
(or (not (numberp max)) (>= (/ max 8) (buffer-size)))))
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue