Prev | Next | srccode |
$srccode%file_ext%source%$$
source
code
with highlighting and for the language
corresponding to the specified file extension.
file_ext
does not include the dot .
file_ext
.
For example, the R programming language would correspond to
file_ext
equal to R
or r
.
%file_ext%source%
is a delimiter sequence
where %
can be any character that is not a letter.
srccode
command are ignored.
(There must be at least two newlines in text.)
This enables the inclusion of source code that is actually compiled.
For example, the input
$tabsize 4$$
$subhead Factorial Program$$ */
$srccode%py%
def factorial(n) :
if n == 1 :
return 1
return n * factorial(n-1)
end
/* %$$
would create the following output
def factorial(n) : if n == 1 : return 1 return n * factorial(n-1) end