aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-11-21 08:25:14 +0000
committerDavid Robillard <d@drobilla.net>2011-11-21 08:25:14 +0000
commit8c9a0cbaf858f31b8e4fb8e37f89541dfb038a78 (patch)
tree7a640e576672405f3f9478b7acad72f3b0ca531a
parent6efb807a885369b9240c7fe0bc0abeb81b5deb05 (diff)
downloadlv2-8c9a0cbaf858f31b8e4fb8e37f89541dfb038a78.tar.xz
Highlight qnames as Name.Tag.
-rw-r--r--doc/style.css2
-rwxr-xr-xlv2specgen/lv2specgen.py8
2 files changed, 5 insertions, 5 deletions
diff --git a/doc/style.css b/doc/style.css
index 120dc24..d91a72c 100644
--- a/doc/style.css
+++ b/doc/style.css
@@ -546,7 +546,7 @@ h1, h2, h3, h4, h5, h6, th {
.nf { color: #222222; font-weight: bold } /* Name.Function */
.nl { color: #A0A000 } /* Name.Label */
.nn { color: #000000 } /* Name.Namespace */
-.nt { color: #008000; font-weight: bold } /* Name.Tag */
+.nt { color: #334433; } /* Name.Tag */
.nv { color: #19177C } /* Name.Variable */
.ow { color: #AA22FF; font-weight: bold } /* Operator.Word */
.w { color: #bbbbbb } /* Text.Whitespace */
diff --git a/lv2specgen/lv2specgen.py b/lv2specgen/lv2specgen.py
index b8494a1..1349f5c 100755
--- a/lv2specgen/lv2specgen.py
+++ b/lv2specgen/lv2specgen.py
@@ -196,8 +196,8 @@ if have_pygments:
],
'predObj': [
include('comments'),
- (r'(\s*[a-zA-Z_:][a-zA-Z0-9\-_:]*\b\s*)', Operator, 'object'),
- (r'\s*(<[^>]*\>)', Operator, 'object'),
+ (r'\s*[a-zA-Z_:][a-zA-Z0-9\-_:]*\b\s*', Name.Tag, 'object'),
+ (r'\s*(<[^>]*\>)', Name.Tag, 'object'),
(r'\s*\]\s*', Text, '#pop'),
(r'(?=\s*\.\s*)', Keyword, '#pop'),
],
@@ -209,12 +209,12 @@ if have_pygments:
'object': [
include('comments'),
(r'\s*\[', Text, 'predObj'),
- (r'\s*<[^> ]*>', Name.Attribute),
+ (r'\s*<[^> ]*>', Name.Tag),
(r'\s*("""(?:.|\n)*?""")(\@[a-z]{2-4}|\^\^<?[a-zA-Z0-9\-\:_#/\.]*>?)?\s*', bygroups(Literal.String,Text)),
(r'\s*".*?[^\\]"(?:\@[a-z]{2-4}|\^\^<?[a-zA-Z0-9\-\:_#/\.]*>?)?\s*', Literal.String),
(r'\s*[0-9]+\.[0-9]*\s*\n?', Literal.Number),
(r'\s*[0-9]+\s*\n?', Literal.Number),
- (r'\s*[a-zA-Z0-9\-_\:]\s*', Name.Attribute),
+ (r'\s*[a-zA-Z0-9\-_\:]\s*', Name.Tag),
(r'\s*\(', Text, 'objList'),
(r'\s*;\s*\n?', Punctuation, '#pop'),
(r'\s*,\s*\n?', Punctuation), # Added by drobilla so "," is not an error