aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorRichard M. Stallman <[email protected]>1997-04-13 06:11:35 +0000
committerRichard M. Stallman <[email protected]>1997-04-13 06:11:35 +0000
commit6811a757a57f886bc9d172164da79903ec901227 (patch)
treed777e2bc08cd50b87bb7cd6626250090496d5bb1 /lisp
parent64ae0c233e62851efe9bd63ba834baeb98e22715 (diff)
(sgml-mode-facemenu-add-face-function): New function.
(sgml-mode-common): Use that function for the hook value.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/textmodes/sgml-mode.el17
1 files changed, 10 insertions, 7 deletions
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el
index a05d079ed5..6d52f835ca 100644
--- a/lisp/textmodes/sgml-mode.el
+++ b/lisp/textmodes/sgml-mode.el
@@ -333,13 +333,7 @@ varables of same name)."
sgml-font-lock-keywords-1)
nil
t)
- facemenu-add-face-function
- (lambda (face end)
- (if (setq face (cdr (assq face sgml-face-tag-alist)))
- (progn
- (setq facemenu-end-add-face (concat "</" face ">"))
- (concat "<" face ">"))
- (error "Face not configured for %s mode." mode-name))))
+ facemenu-add-face-function 'sgml-mode-facemenu-add-face-function)
(while sgml-display-text
(put (car (car sgml-display-text)) 'before-string
(cdr (car sgml-display-text)))
@@ -347,6 +341,15 @@ varables of same name)."
(run-hooks 'text-mode-hook 'sgml-mode-hook))
+(defun sgml-mode-facemenu-add-face-function (face end)
+ (if (setq face (cdr (assq face sgml-face-tag-alist)))
+ (progn
+ (setq face (funcall skeleton-transformation face))
+ (setq facemenu-end-add-face (concat "</" face ">"))
+ (concat "<" face ">"))
+ (error "Face not configured for %s mode." mode-name)))
+
+
;;;###autoload
(defun sgml-mode (&optional function)
"Major mode for editing SGML documents.