Permalink
Browse files

g-ir-doc-tool: Add some more stuff to Enum pages

  • Loading branch information...
1 parent 5cb2864 commit 67d354dc97c107c490a555a5e9ff245dc0cae2cc @tomeuv tomeuv committed Feb 20, 2012
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<page id="${node.namespace.name}.${node.name}"
+ type="guide"
+ style="enum"
+ xmlns="http://projectmallard.org/1.0/"
+ xmlns:ui="http://projectmallard.org/experimental/ui/">
+ <info>
+ <link type="guide" xref="index"/>
+ </info>
+ <title>${node.namespace.name}.${node.name}</title>
+ ${formatter.format(node.doc)}
+% if node.members:
+<table>
+% for member, ix in zip(node.members, range(len(node.members))):
+<tr>
+<td><p>${node.name}.${member.name.upper()} :</p></td>
+<td>${formatter.format(member.doc)}</td>
+</tr>
+% endfor
+</table>
+% endif
+
+</page>
@@ -210,6 +210,9 @@ def _render_node(self, node, output):
page_id = '%s.%s.%s' % (namespace.name, node.parent.name, node.name)
else:
page_id = '%s.%s' % (namespace.name, node.name)
+ elif isinstance(node, ast.Enum):
+ template_name = 'mallard-%s-enum.tmpl' % self._language
+ page_id = '%s.%s' % (namespace.name, node.name)
elif isinstance(node, ast.Property) and node.parent is not None:
template_name = 'mallard-%s-property.tmpl' % self._language
page_id = '%s.%s-%s' % (namespace.name, node.parent.name, node.name)
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.ArrayType"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.ArrayType</title>
<p>The type of array in a <link xref="GIRepository.TypeInfo">GIRepository.TypeInfo</link>.</p>
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.Direction"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.Direction</title>
<p>The direction of a <link xref="GIRepository.ArgInfo">GIRepository.ArgInfo</link>.</p>
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.InfoType"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.InfoType</title>
<p>The type of a GIBaseInfo struct.</p>
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.RepositoryError"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.RepositoryError</title>
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.ScopeType"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.ScopeType</title>
<p>Scope type of a <link xref="GIRepository.ArgInfo">GIRepository.ArgInfo</link> representing callback, determines how the
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.Transfer"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.Transfer</title>
<p>The transfer is the exchange of data between two parts, from the callee to
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.TypeTag"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.TypeTag</title>
<p>The type tag of a <link xref="GIRepository.TypeInfo">GIRepository.TypeInfo</link>.</p>
@@ -1,10 +1,11 @@
<?xml version="1.0"?>
<page id="GIRepository.nvokeError"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.nvokeError</title>
<p>An error occuring while invoking a function via
@@ -1,11 +1,32 @@
<?xml version="1.0"?>
<page id="GIRepository.ArrayType"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.ArrayType</title>
-<p>The type of array in a <link xref="GIRepository.TypeInfo">GIRepository.TypeInfo</link>.</p>
+ <p>The type of array in a <link xref="GIRepository.TypeInfo">GIRepository.TypeInfo</link>.</p>
+
+<table>
+<tr>
+<td><p>ArrayType.C :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>ArrayType.ARRAY :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>ArrayType.PTR_ARRAY :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>ArrayType.BYTE_ARRAY :</p></td>
+<td></td>
+</tr>
+</table>
+
</page>
@@ -1,11 +1,28 @@
<?xml version="1.0"?>
<page id="GIRepository.Direction"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.Direction</title>
-<p>The direction of a <link xref="GIRepository.ArgInfo">GIRepository.ArgInfo</link>.</p>
+ <p>The direction of a <link xref="GIRepository.ArgInfo">GIRepository.ArgInfo</link>.</p>
+
+<table>
+<tr>
+<td><p>Direction.IN :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>Direction.OUT :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>Direction.INOUT :</p></td>
+<td></td>
+</tr>
+</table>
+
</page>
@@ -1,11 +1,96 @@
<?xml version="1.0"?>
<page id="GIRepository.InfoType"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.InfoType</title>
-<p>The type of a GIBaseInfo struct.</p>
+ <p>The type of a GIBaseInfo struct.</p>
+
+<table>
+<tr>
+<td><p>InfoType.INVALID :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.FUNCTION :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.CALLBACK :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.STRUCT :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.BOXED :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.ENUM :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.FLAGS :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.OBJECT :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.INTERFACE :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.CONSTANT :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.INVALID_0 :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.UNION :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.VALUE :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.SIGNAL :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.VFUNC :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.PROPERTY :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.FIELD :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.ARG :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.TYPE :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>InfoType.UNRESOLVED :</p></td>
+<td></td>
+</tr>
+</table>
+
</page>
@@ -1,11 +1,32 @@
<?xml version="1.0"?>
<page id="GIRepository.RepositoryError"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.RepositoryError</title>
+
+
+<table>
+<tr>
+<td><p>RepositoryError.TYPELIB_NOT_FOUND :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>RepositoryError.NAMESPACE_MISMATCH :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>RepositoryError.NAMESPACE_VERSION_CONFLICT :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>RepositoryError.LIBRARY_NOT_FOUND :</p></td>
+<td></td>
+</tr>
+</table>
</page>
@@ -1,13 +1,34 @@
<?xml version="1.0"?>
<page id="GIRepository.ScopeType"
- type="topic"
- style=""
+ type="guide"
+ style="enum"
xmlns="http://projectmallard.org/1.0/"
xmlns:ui="http://projectmallard.org/experimental/ui/">
<info>
+ <link type="guide" xref="index"/>
</info>
<title>GIRepository.ScopeType</title>
-<p>Scope type of a <link xref="GIRepository.ArgInfo">GIRepository.ArgInfo</link> representing callback, determines how the
+ <p>Scope type of a <link xref="GIRepository.ArgInfo">GIRepository.ArgInfo</link> representing callback, determines how the
callback is invoked and is used to decided when the invoke structs
can be freed.</p>
+
+<table>
+<tr>
+<td><p>ScopeType.INVALID :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>ScopeType.CALL :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>ScopeType.ASYNC :</p></td>
+<td></td>
+</tr>
+<tr>
+<td><p>ScopeType.NOTIFIED :</p></td>
+<td></td>
+</tr>
+</table>
+
</page>
Oops, something went wrong.

0 comments on commit 67d354d

Please sign in to comment.