[interchange-docs] xmldocs - docelic modified refs/subtotal.tag

docs at icdevgroup.org docs at icdevgroup.org
Mon Aug 11 12:36:58 UTC 2008


User:      docelic
Date:      2008-08-11 12:36:58 GMT
Modified:  refs     subtotal.tag
Log:
Oi,

Let's generally avoid perl code blocks in examples (like I've been
doing all this time), unless the point of the example is to show
something you can't do in ITL.

The "conversion" from ITL to Perl is straightforward (at least when
you know some basic rules -- which I'm gonna document in the future
perl programming guide), and using only ITL will unify the look and feel
of the docs.

I've commented the example for now, but I have a few notes for cases where
you will really really want a perl example:

- Enclose it in [perl] or [calc] so that the block is runnable in ITL context
  like everything else

- Use <programlisting><![CDATA[ .... ]]></programlisting> instead of
  just <programlisting> so that you can use chars like > and < without
  needing to write &lt; &gt;

- Say "using Perl" in title instead of "programmatically"

- Don't insert side-features in the example that are not "announced"
  in the title (like the ({noformat=>1}) thing). The proper example
  for that example of yours would be:
  "Displaying unformatted subtotal using Perl"

Cya,
-doc

Revision  Changes    Path
1.5                  xmldocs/refs/subtotal.tag


rev 1.5, prev_rev 1.4
Index: subtotal.tag
===================================================================
RCS file: /var/cvs/xmldocs/refs/subtotal.tag,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- subtotal.tag	11 Aug 2008 08:57:55 -0000	1.4
+++ subtotal.tag	11 Aug 2008 12:36:58 -0000	1.5
@@ -5,7 +5,7 @@
 __NAME__ synopsis
 <row>
 	<entry>
-	<group choice='optional'>
+	<group>
 	<arg choice='plain'>name</arg>
 	<arg choice='plain'>cart</arg>
 	</group>
@@ -31,11 +31,12 @@
 </programlisting>
 __END__
 
-__NAME__ example: Using [subtotal] programatically
-<programlisting>
+<!--
+example: Using [subtotal] programatically
+<programlisting><![CDATA[
 $subtotal = $Tag->subtotal({noformat => 1});
-</programlisting>
-__END__
+]]></programlisting>
+-->
 
 __NAME__ see also
 currency, total-cost







More information about the docs mailing list