Index: openacs-4/packages/acs-templating/www/doc/gen/proc-doc.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-templating/www/doc/gen/proc-doc.adp,v diff -u -r1.2 -r1.3 --- openacs-4/packages/acs-templating/www/doc/gen/proc-doc.adp 27 Oct 2014 16:40:22 -0000 1.2 +++ openacs-4/packages/acs-templating/www/doc/gen/proc-doc.adp 7 Aug 2017 23:48:03 -0000 1.3 @@ -1,72 +1,76 @@ -{/doc/acs-templating {Templating}} {Commenting Tcl procedures for parsing} +{/doc/acs-templating {ACS Templating}} {Commenting Tcl procedures for parsing} Commenting Tcl procedures for parsing - - -

Using comments to document Tcl procedures

Templating System

Text divisions, grouping

< blah blah > The Tcl proc parser relies on three main -text markers to divvy the Tcl library file into neat compartments: -namespace, procedure and directive. Each of these divisions has its -own text marker(s). In the end, your Tcl file should look somthing -like this: -

+

Using comments to document Tcl procedures

+Templating System +

Text divisions, grouping

+< blah blah > + The Tcl proc parser relies on three +main text markers to divvy the Tcl library file into neat +compartments: namespace, procedure and directive. Each of these +divisions has its own text marker(s). In the end, your Tcl file +should look somthing like this: +

 [------------------------------------------------------]
-[------  ignored text at beginning of file  -----------]
+[------  ignored text at beginning of file  -----------]
 [------------------------------------------------------]
 
-# \@namespace<name><description of namespace>
-        # <continued description>
+# \@namespace<name><description of namespace>
+        # <continued description>
 
-        # \@author<name of the primary author for this namespace>
+        # \@author<name of the primary author for this namespace>
 
-        # \@see<type of reference, like proc, namespace, url, or other><full name of reference><url of reference>
-        # \@see ... <more references>
+        # \@see<type of reference, like proc, namespace, url, or other><full name of reference><url of reference>
+        # \@see ... <more references>
 
 
-   # (\@public|\@private) <name><description of procedure>
-     # <continued description>
+   # (\@public|\@private) <name><description of procedure>
+     # <continued description>
 
-     # \@param<name><default value><description>
-     # <continued description>
+     # \@param<name><default value><description>
+     # <continued description>
 
-     # \@param ... <info for other paramaters>
+     # \@param ... <info for other paramaters>
 
-     # \@option<name><default value><description>
-     # <continued description>
+     # \@option<name><default value><description>
+     # <continued description>
 
-     # \@option ... <info for other options>
+     # \@option ... <info for other options>
  
-     # \@author<name of author>
+     # \@author<name of author>
 
-     # \@return<description of return variable>
+     # \@return<description of return variable>
 
-     # \@see<just like the namespace \@see directive>
+     # \@see<just like the namespace \@see directive>
 
      [------------------------------------------------------]
-     [----------  source text for procedure  ---------------] 
+     [----------  source text for procedure  ---------------] 
      [------------------------------------------------------]
 
 
-   # \@public or \@private ... < more procedures within the same namespace >
+   # \@public or \@private ... < more procedures within the same namespace >
 
 
-# \@namespace ... <other namespaces>
-
+# \@namespace ... <other namespaces> +
+ Note that comment lines are indented to indicate the manner in which they should be grouped only, and that there is no required spacing scheme for comments.

Use of these directive markers is largely straightforward, but a more in depth guideline of how the markers guide parsing may help -those documenting their own work:

-the \@namespace markerthe directive markers
The commentary text that precedes a Tcl proc command should contain a list of directives identified by these markers: