summaryrefslogtreecommitdiff
path: root/docs/devel_guide_src/comments.tex
diff options
context:
space:
mode:
authorR. Tyler Ballance <tyler@monkeypox.org>2009-11-16 21:09:13 -0800
committerR. Tyler Ballance <tyler@monkeypox.org>2009-11-16 21:09:13 -0800
commitd9ce7916e309e2393d824e249f512d2629e5e181 (patch)
tree6b7ad5cd6292f6e017e048fbeb4551facbabd174 /docs/devel_guide_src/comments.tex
parente43765a679b84c52df875e9629d303e304af50a1 (diff)
downloadpython-cheetah-docs.tar.gz
Revert "Delete the "old" docs directory to make way for fancy smancy sphinx"docs
This reverts commit 5dc95cfcd015628665d3672e56d0551943b5db6b.
Diffstat (limited to 'docs/devel_guide_src/comments.tex')
-rwxr-xr-xdocs/devel_guide_src/comments.tex100
1 files changed, 100 insertions, 0 deletions
diff --git a/docs/devel_guide_src/comments.tex b/docs/devel_guide_src/comments.tex
new file mode 100755
index 0000000..4a7bdbd
--- /dev/null
+++ b/docs/devel_guide_src/comments.tex
@@ -0,0 +1,100 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\section{Directives: Comments}
+\label{comments}
+
+The template:
+
+\begin{verbatim}
+Text before the comment.
+## The comment.
+Text after the comment.
+#* A multi-line comment spanning several lines.
+ It spans several lines, too.
+*#
+Text after the multi-line comment.
+\end{verbatim}
+
+The output:
+
+\begin{verbatim}
+Text before the comment.
+Text after the comment.
+
+Text after the multi-line comment.
+
+\end{verbatim}
+
+The generated code:
+
+\begin{verbatim}
+ write('Text before the comment.\n')
+ # The comment.
+ write('Text after the comment.\n')
+ # A multi-line comment spanning several lines.
+ # It spans several lines, too.
+ write('\nText after the multi-line comment.\n')
+\end{verbatim}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\subsection{Docstring and header comments}
+\label{comments.docstring}
+
+The template:
+\begin{verbatim}
+##doc: .respond() method comment.
+##doc-method: Another .respond() method comment.
+##doc-class: A class comment.
+##doc-module: A module comment.
+##header: A header comment.
+\end{verbatim}
+
+The output:
+\begin{verbatim}
+
+\end{verbatim}
+
+The beginning of the generated \code{.respond} method:
+\begin{verbatim}
+def respond(self,
+ trans=None,
+ dummyTrans=False,
+ VFS=valueFromSearchList,
+ VFN=valueForName,
+ getmtime=getmtime,
+ currentTime=time.time):
+
+ """
+ This is the main method generated by Cheetah
+ .respond() method comment.
+ Another .respond() method comment.
+ """
+\end{verbatim}
+
+The class docstring:
+\begin{verbatim}
+"""
+A class comment.
+
+Autogenerated by CHEETAH: The Python-Powered Template Engine
+"""
+\end{verbatim}
+
+The top of the module:
+\begin{verbatim}
+#!/usr/bin/env python
+# A header comment.
+
+"""A module comment.
+
+Autogenerated by CHEETAH: The Python-Powered Template Engine
+ CHEETAH VERSION: 0.9.13a1
+ Generation time: Fri Apr 26 22:39:23 2002
+ Source file: x.tmpl
+ Source file last modified: Fri Apr 26 22:36:23 2002
+"""
+\end{verbatim}
+
+
+% Local Variables:
+% TeX-master: "devel_guide"
+% End: