Jack Andrews wrote:
> hi again...
>
> and i have some demands ;)
> how to include c source in reST?
>
> eg:
>
> #include <stdlib.h>
> #include <stdio.h>
> main(int argc,char**argv)
> {int n,period,*list,*result,i,j,sum;
> n=argc-2;period=atoi(argv[1]);
> }
>
> i don't want to indent every line because:
> a) tiresome
> b) can make the source unreadable because there are fewer than 80
> columns for the source
>
> any hints?
>
The way you include literals in reST is : ::
like this
sorry you have to indent - but it can be only one character
in most editors, it's one key press
to indent a paragraph
and the output isn't indented
:-)
Fuzzyman
> kind regards,
>
>
> jack
> ---- _I v o r y__K i t e____
> jack andrews
> vic australia http://www.ivorykite.com/
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by:
> Power Architecture Resource Center: Free content, downloads, discussions,
> and more. http://solutions.newsforge.com/ibmarch.tmpl
> _______________________________________________
> Docutils-users mailing list
> Docutils-users@...
> https://lists.sourceforge.net/lists/listinfo/docutils-users
>
> Please use "Reply All" to reply to the list.
>
>
>
|