(make-face 'tei-head-1-face) (set-face-foreground 'tei-head-1-face "dark green") (set-face-font 'tei-head-1-face "-*-courier-bold-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-head-2-face) (set-face-foreground 'tei-head-2-face "dark blue") (set-face-font 'tei-head-2-face "-*-courier-bold-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-head-3-face) (set-face-foreground 'tei-head-3-face "dark green") (set-face-font 'tei-head-3-face "-*-courier-normal-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-head-4-face) (set-face-foreground 'tei-head-4-face "dark blue") (set-face-font 'tei-head-4-face "-*-courier-normal-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-head-5-face) (set-face-foreground 'tei-head-5-face "brown") (set-face-font 'tei-head-5-face "-*-courier-bold-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-emph-face) (set-face-font 'tei-emph-face "-adobe-helvetica-medium-o-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-title-face) (set-face-font 'tei-title-face "-adobe-helvetica-bold-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-eg-face) (set-face-font 'tei-eg-face "-adobe-helvetica-medium-r-*-*-*-180-*-*-*-*-koi8-*") (set-face-foreground 'tei-eg-face "dark blue") (make-face 'tei-label-face) (set-face-foreground 'tei-label-face "dark cyan") (set-face-font 'tei-label-face "-adobe-courier-medium-o-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-item-face) (set-face-foreground 'tei-item-face "dark cyan") (set-face-font 'tei-item-face "-adobe-courier-bold-r-*-*-*-180-*-*-*-*-koi8-*") (make-face 'tei-note-face) (set-face-font 'tei-note-face "-adobe-courier-medium-r-*-*-*-140-*-*-*-*-koi8-*") (make-face 'tei-quote-face) (set-face-font 'tei-quote-face "-adobe-courier-medium-o-*-*-*-180-*-*-*-*-koi8-*") (add-hook 'tei-mode-hook 'TEI-fontify) (defun TEI-fontify () (setq font-lock-keywords '( ("<div1[^>]*><head/[^/]*/" . tei-head-1-face) ("<div1[^>]*><head[^>]*>[^<]*</>" . tei-head-1-face) ("<div1[^>]*><head[^>]*>[^<]*</head>" . tei-head-1-face) ("<div2[^>]*><head/[^/]*/" . tei-head-2-face) ("<div2[^>]*><head[^>]*>[^<]*</>" . tei-head-2-face) ("<div2[^>]*><head[^>]*>[^<]*</head>" . tei-head-2-face) ("<div3[^>]*><head/[^/]*/" . tei-head-3-face) ("<div3[^>]*><head[^>]*>[^<]*</>" . tei-head-3-face) ("<div3[^>]*><head[^>]*>[^<]*</head>" . tei-head-3-face) ("<div4[^>]*><head/[^/]*/" . tei-head-4-face) ("<div4[^>]*><head[^>]*>[^<]*</>" . tei-head-4-face) ("<div4[^>]*><head[^>]*>[^<]*</head>" . tei-head-4-face) ("<div5[^>]*><head/[^/]*/" . tei-head-5-face) ("<div5[^>]*><head[^>]*>[^<]*</>" . tei-head-5-face) ("<div5[^>]*><head[^>]*>[^<]*</head>" . tei-head-5-face) ("<emph/[^/]*/" . tei-emph-face) ("<emph[^>]*>[^<]*</emph>" . tei-emph-face) ("<emph[^>]*>[^<]*</>" . tei-emph-face) ("<hi/[^/]*/" . tei-emph-face) ("<hi[^>]*>[^<]*</title>" . tei-emph-face) ("<hi[^>]*>[^<]*</>" . tei-emph-face) ("<title/[^/]*/" . tei-title-face) ("<title[^>]*>[^<]*</title>" . tei-title-face) ("<title[^>]*>[^<]*</>" . tei-title-face) ("<eg/[^/]*/" . tei-eg-face) ("<eg[^>]*>.*</>" . tei-eg-face) ("<eg[^>]*>.*</eg>" . tei-eg-face) ("<code/[^/]*/" . tei-eg-face) ("<code[^>]*>[^<]*</>" . tei-eg-face) ("<code[^>]*>[^<]*</code>" . tei-eg-face) ("<kw/[^/]*/" . tei-eg-face) ("<kw[^>]*>[^<]*</>" . tei-eg-face) ("<kw[^>]*>[^<]*</kw>" . tei-eg-face) ("<label/[^/]*/" . tei-label-face) ("<label[^>]*>[^<]*</>" . tei-label-face) ("<label[^>]*>[^<]*</label>" . tei-label-face) ("<note/[^/]*/" . tei-note-face) ("<note[^>]*>[^<]*</>" . tei-note-face) ("<note[^>]*>[^<]*</note>" . tei-note-face) ("<item/" . tei-item-face) ("<item[^>]*>" . tei-item-face) ("<q/[^/]*/" . tei-quote-face) ("<q>[^<]*</>" . tei-quote-face) ("<q>[^<]*</q>" . tei-quote-face) ("<socalled/[^/]*/" . tei-quote-face) ("<socalled>[^<]*</>" . tei-quote-face) ("<socalled[^>]*>[^<]*</socalled>" . tei-quote-face) ("<term/[^/]*/" . tei-eg-face) ("<term[^>]*>[^<]*</>" . tei-eg-face) ("<term[^>]*>[^<]*</term>" . tei-eg-face) ) ) ) (defun tei-mode () (interactive) (sgml-mode) (run-hooks 'tei-mode-hook) (font-lock-mode 1)) (defun docbook-mode () (sgml-mode) ) (provide 'tei-colors)