Browse Source

first cut at reducing the boilerplate in api doc entries: Prototype, Stack, and Summary are pretty self-evident; Example and See also are still left as headings

pull/20/head
Sami Vaarala 11 years ago
parent
commit
513b204d80
  1. 10
      website/buildsite.py

10
website/buildsite.py

@ -223,7 +223,7 @@ def processApiDoc(parts, funcname, testrefs, used_tags):
if parts.has_key('proto'):
p = parts['proto']
res.append('<h2>Prototype</h2>')
#res.append('<h2>Prototype</h2>')
res.append('<pre class="c-code">')
for i in p:
res.append(htmlEscape(i))
@ -234,20 +234,20 @@ def processApiDoc(parts, funcname, testrefs, used_tags):
if parts.has_key('stack'):
p = parts['stack']
res.append('<h2>Stack</h2>')
#res.append('<h2>Stack</h2>')
for line in p:
res.append('<pre class="stack">' + \
'%s' % htmlEscape(line) + \
'</pre>')
res.append('')
else:
res.append('<h2>Stack</h2>')
res.append('<p>No effect.</p>')
#res.append('<h2>Stack</h2>')
res.append('<p>(No effect on value stack.)</p>')
res.append('')
if parts.has_key('summary'):
p = parts['summary']
res.append('<h2>Summary</h2>')
#res.append('<h2>Summary</h2>')
# If text contains a '<p>', assume it is raw HTML; otherwise
# assume it is a single paragraph (with no markup) and generate

Loading…
Cancel
Save