summaryrefslogtreecommitdiff
path: root/src/elisp/urweb-mode.el
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adamc@hcoop.net>2008-10-12 12:53:45 -0400
committerGravatar Adam Chlipala <adamc@hcoop.net>2008-10-12 12:53:45 -0400
commit807bea9c53e5af96f93dc8dacc572052226e7d30 (patch)
treeeb8cb2136f97801698ae84a6e9e68d80d318927a /src/elisp/urweb-mode.el
parent19b9eee2a968e9fe577792a48d0b4cf931165874 (diff)
Highlighting HTML tags
Diffstat (limited to 'src/elisp/urweb-mode.el')
-rw-r--r--src/elisp/urweb-mode.el23
1 files changed, 14 insertions, 9 deletions
diff --git a/src/elisp/urweb-mode.el b/src/elisp/urweb-mode.el
index d32b2a55..a4691811 100644
--- a/src/elisp/urweb-mode.el
+++ b/src/elisp/urweb-mode.el
@@ -162,10 +162,10 @@ See doc for the variable `urweb-mode-info'."
(defconst urweb-font-lock-keywords
`(;;(urweb-font-comments-and-strings)
- (,(concat "\\<\\(fun\\|and\\)\\s-+\\(\\sw+\\)\\s-+[^ \t\n=]")
+ ("\\<\\(fun\\|and\\)\\s-+\\(\\sw+\\)\\s-+[^ \t\n=]"
(1 font-lock-keyword-face)
(2 font-lock-function-name-face))
- (,(concat "\\<\\(\\(data\\)?type\\|con\\|class\\)\\s-+\\(\\sw+\\)")
+ ("\\<\\(\\(data\\)?type\\|con\\|class\\)\\s-+\\(\\sw+\\)"
(1 font-lock-keyword-face)
(3 font-lock-type-def-face))
("\\<\\(val\\|table\\|sequence\\)\\s-+\\(\\sw+\\>\\s-*\\)?\\(\\sw+\\)\\s-*[=:]"
@@ -177,6 +177,11 @@ See doc for the variable `urweb-mode-info'."
("\\<\\(signature\\)\\s-+\\(\\sw+\\)"
(1 font-lock-keyword-face)
(2 font-lock-interface-def-face))
+
+ ("<\\(\\sw+\\)[^>]*>"
+ (1 font-lock-tag-face))
+ ("</\\(\\sw+\\)[^>]*>"
+ (1 font-lock-tag-face))
(,urweb-keywords-regexp . font-lock-keyword-face)
(,urweb-sql-keywords-regexp . font-lock-sql-face)
@@ -212,13 +217,6 @@ See doc for the variable `urweb-mode-info'."
(defvar font-lock-sql-face 'font-lock-sql-face
"Face name to use for SQL keywords.")
-;(defface font-lock-variable-face
-; '((t (:foreground "green")))
-; "Font Lock mode face used to highlight lowercase identifiers."
-; :group 'font-lock-highlighting-faces)
-;(defvar font-lock-variable-face 'font-lock-variable-face
-; "Face name to use for lowercase identifiers.")
-
(defface font-lock-cvariable-face
'((t (:foreground "dark blue")))
"Font Lock mode face used to highlight capitalized identifiers."
@@ -226,6 +224,13 @@ See doc for the variable `urweb-mode-info'."
(defvar font-lock-cvariable-face 'font-lock-cvariable-face
"Face name to use for capitalized identifiers.")
+(defface font-lock-tag-face
+ '((t (:bold t)))
+ "Font Lock mode face used to highlight XML tags."
+ :group 'font-lock-highlighting-faces)
+(defvar font-lock-tag-face 'font-lock-tag-face
+ "Face name to use for XML tags.")
+
;;
;; Code to handle nested comments and unusual string escape sequences
;;