diff options
author | Richard M. Stallman <rms@gnu.org> | 1997-04-13 06:11:35 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1997-04-13 06:11:35 +0000 |
commit | 6811a757a57f886bc9d172164da79903ec901227 (patch) | |
tree | d777e2bc08cd50b87bb7cd6626250090496d5bb1 /lisp/textmodes | |
parent | 64ae0c233e62851efe9bd63ba834baeb98e22715 (diff) | |
download | emacs-6811a757a57f886bc9d172164da79903ec901227.tar.gz |
(sgml-mode-facemenu-add-face-function): New function.
(sgml-mode-common): Use that function for the hook value.
Diffstat (limited to 'lisp/textmodes')
-rw-r--r-- | lisp/textmodes/sgml-mode.el | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index a05d079ed57..6d52f835ca5 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. |