Tag datastructure definitions in docs/spec/* for highlighting

Currently the language used for highlighting is auto-detected and not ideal.
A datastructure-definition lexer should be created to optimize highlighting.

Some specifications have links to other parts of the documentation; currently
these would get escaped and highlighted (and so these specifications have not
been tagged). The HighlightExtension needs extending so that sections of text
to not highlight (or escape) can be marked. Alternatively, the HTML formatter
supports adding links using a ctags file, but this would require formalizing
the datastructure-definition format enough to be able to identify names
properly.
This commit is contained in:
str4d
2013-06-10 07:23:39 +00:00
parent aaa5d03bd1
commit 6a1d9daa57
9 changed files with 157 additions and 253 deletions

View File

@@ -12,7 +12,7 @@ See the Streaming page for an overview of the Streaming Library.
<p>{% trans -%}
The format of a single packet in the streaming protocol is:
{%- endtrans %}</p>
<pre>
{% highlight %}
+----+----+----+----+----+----+----+----+
| send Stream ID | rcv Stream ID |
@@ -29,7 +29,7 @@ The format of a single packet in the streaming protocol is:
+----+----+----+----//
</pre>
{% endhighlight %}
<table>
<tr><th>{{ _('Field') }}<th>{{ _('Length') }}<th>{{ _('Contents') }}