summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2020-08-18 23:17:47 +0200
committerLars Ingebrigtsen <larsi@gnus.org>2020-08-18 23:19:09 +0200
commit80a42824299e69462448575782a39350805c3d7e (patch)
tree3dafaa2b88a7d34ed54d72bdcd39ed5c522bf4b9
parent1a3105106900157337fda085c5bc534582af454d (diff)
downloademacs-80a42824299e69462448575782a39350805c3d7e.tar.gz
Remove some compat code from forms.el
* lisp/forms.el (forms-mode): make-face always exists.
-rw-r--r--lisp/forms.el25
1 files changed, 10 insertions, 15 deletions
diff --git a/lisp/forms.el b/lisp/forms.el
index fcb6075f94b..83daabdcd6e 100644
--- a/lisp/forms.el
+++ b/lisp/forms.el
@@ -504,12 +504,9 @@ Commands: Equivalent keys in read-only mode:
(setq forms-new-record-filter nil)
(setq forms-modified-record-filter nil)
- ;; If running Emacs 19 under X, setup faces to show read-only and
- ;; read-write fields.
- (if (fboundp 'make-face)
- (progn
- (make-local-variable 'forms-ro-face)
- (make-local-variable 'forms-rw-face)))
+ ;; Setup faces to show read-only and read-write fields.
+ (make-local-variable 'forms-ro-face)
+ (make-local-variable 'forms-rw-face)
;; eval the buffer, should set variables
;;(message "forms: processing control file...")
@@ -609,16 +606,14 @@ Commands: Equivalent keys in read-only mode:
(setq forms--mode-setup t)
;; Copy desired faces to the actual variables used by the forms formatter.
- (if (fboundp 'make-face)
+ (make-local-variable 'forms--ro-face)
+ (make-local-variable 'forms--rw-face)
+ (if forms-read-only
(progn
- (make-local-variable 'forms--ro-face)
- (make-local-variable 'forms--rw-face)
- (if forms-read-only
- (progn
- (setq forms--ro-face forms-ro-face)
- (setq forms--rw-face forms-ro-face))
- (setq forms--ro-face forms-ro-face)
- (setq forms--rw-face forms-rw-face))))
+ (setq forms--ro-face forms-ro-face)
+ (setq forms--rw-face forms-ro-face))
+ (setq forms--ro-face forms-ro-face)
+ (setq forms--rw-face forms-rw-face))
;; Make more local variables.
(make-local-variable 'forms--file-buffer)