Commit 72562057 authored by Colin Walters's avatar Colin Walters
Browse files

(global-font-lock-mode, font-lock-auto-fontify): Delete defvars.

(cvs-highlight): Delete.
(cvs-add-face): Use `font-lock-face'.  Always add properties.
parent 2a4a8cd5
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
;; Author: Stefan Monnier <monnier@cs.yale.edu> ;; Author: Stefan Monnier <monnier@cs.yale.edu>
;; Keywords: pcl-cvs ;; Keywords: pcl-cvs
;; Revision: $Id: pcvs-info.el,v 1.8 2001/12/31 20:28:40 rms Exp $ ;; Revision: $Id: pcvs-info.el,v 1.9 2002/04/03 16:56:36 kai Exp $
;; This file is part of GNU Emacs. ;; This file is part of GNU Emacs.
...@@ -47,15 +47,6 @@ If t, their full path name will be displayed, else only the filename." ...@@ -47,15 +47,6 @@ If t, their full path name will be displayed, else only the filename."
:group 'pcl-cvs :group 'pcl-cvs
:type '(boolean)) :type '(boolean))
(defvar global-font-lock-mode)
(defvar font-lock-auto-fontify)
(defcustom cvs-highlight
(or (and (boundp 'font-lock-auto-fontify) font-lock-auto-fontify)
(and (boundp 'global-font-lock-mode) global-font-lock-mode))
"*Whether to use text highlighting ( la font-lock) or not."
:group 'pcl-cvs
:type '(boolean))
(defcustom cvs-allow-dir-commit nil (defcustom cvs-allow-dir-commit nil
"*Allow `cvs-mode-commit' on directories. "*Allow `cvs-mode-commit' on directories.
If you commit without any marked file and with the cursor positioned If you commit without any marked file and with the cursor positioned
...@@ -319,17 +310,15 @@ FI-OR-TYPE can either be a symbol (a fileinfo-type) or a fileinfo." ...@@ -319,17 +310,15 @@ FI-OR-TYPE can either be a symbol (a fileinfo-type) or a fileinfo."
(eq (car (memq func (cdr (assq type cvs-states)))) func)))) (eq (car (memq func (cdr (assq type cvs-states)))) func))))
(defun cvs-add-face (str face &optional keymap &rest properties) (defun cvs-add-face (str face &optional keymap &rest properties)
(when (or cvs-highlight properties) (add-text-properties 0 (length str)
(add-text-properties 0 (length str) (append
(append (list* 'font-lock-face face
(when cvs-highlight (when keymap
(list* 'face face (list* 'mouse-face 'highlight
(when keymap (when (keymapp keymap)
(list* 'mouse-face 'highlight (list 'keymap keymap)))))
(when (keymapp keymap) properties)
(list 'keymap keymap)))))) str)
properties)
str))
str) str)
(defun cvs-fileinfo-pp (fileinfo) (defun cvs-fileinfo-pp (fileinfo)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment