grim/purple-objects-docbook

Parents cd5a1edb9dd5
Children c87df7294011
added some notes about signals on classes and added an example flags graph to the graphs page
--- a/graphs/example-class.class Sat Jun 01 03:28:10 2013 -0500
+++ b/graphs/example-class.class Sat Jun 01 03:36:19 2013 -0500
@@ -8,6 +8,11 @@
<argument name="object" type="ExampleClass *"/>
</method>
</methods>
+ <signals>
+ <signal name="Foo::bar" type="void" scope="public">
+ <argument name="foo" type="Foo *"/>
+ </signal>
+ </signals>
</class>
<!--
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/graphs/example-flags.enum Sat Jun 01 03:36:19 2013 -0500
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<flags name="ExampleFlags">
+ <item name="FOO" value="1 &lt;&lt; 0"/>
+ <item name="BAR" value="1 &lt;&lt; 1"/>
+ <item name="BAZ" value="1 &lt;&lt; 2"/>
+</flags>
--- a/xml/graphs.xml Sat Jun 01 03:28:10 2013 -0500
+++ b/xml/graphs.xml Sat Jun 01 03:36:19 2013 -0500
@@ -53,7 +53,7 @@
in the top section, and is followed by any modifiers (abstract,
concrete, boxed, etc).
</para>
-
+
<para>
The second section contains the object's member variables. They
are prefixed with a '-' meaning they're private or '+' meaning
@@ -64,7 +64,7 @@
</para>
<para>
- The final section contains all of the methods for the class. The
+ The third section contains all of the methods for the class. The
methods, like the member variables, have the typical scope prefixes.
Following the prefix is the name of the method. Next, is a list of
arguments to the method in the same 'name : type' pair format,
@@ -72,6 +72,11 @@
final ': type', which is the return type of the method.
</para>
+ <para>
+ The last section contains all of the signals for the given class
+ and follows all the same rules as the methods section.
+ </para>
+
<figure id="figure-class">
<title>ExampleClass</title>
@@ -103,5 +108,25 @@
<graphic fileref="graphs/example-enum.png"/>
</figure>
</simplesect>
+
+ <simplesect id="sect-flags">
+ <title>Flags</title>
+
+ <para>
+ Flags are presented exactly like enumerations, but show "flags" in
+ the top section. See <xref linkend="example-flags"/>.
+ </para>
+
+ <para>
+ Flags should show values for all members as a 1 being bit shifted
+ left.
+ </para>
+
+ <figure id="example-flags">
+ <title>ExampleFlags</title>
+
+ <graphic fileref="graphs/example-flags.png"/>
+ </figure>
+ </simplesect>
</chapter>