Create Documentation

Build the Documentation

Syntax

General

General documentation syntax:

 1This is a regular text.
 2
 3When writing multiple lines.
 4They will result in a single line.
 5If there is no empty line between them.
 6
 7To add a line break use..
 8
 9..a empty line between them.
10
11Also adding |br| at the end of a line will result in a line break:
12This is the first line. |br|
13This is the second line. |br|
14Note that there is a space before the |br|

Formulas

Formulas can be embedded into the documentation:

1Inline formula :math:`a^2 + b^2 = d^2`

Inline formula a^2 + b^2 = d^2

Centered:

1.. math::
2    a^2 + b^2 = d^2

a^2 + b^2 = d^2

Notes

Note

Notes can be written like this

1.. note::
2    Note text

Warnings

Warning

Warnings can be written like this

1.. warning::
2    Warning text

Code Blocks

This example shows how to embed code snippets.

The following RST code:

1.. code-block:: C++
2    :linenos:
3    :emphasize-lines: 3
4
5    void my_function() {
6        printf("just a test");
7        my_function();
8        int i = 6;
9    }

reults in:

1void my_function() {
2    printf("just a test");
3    my_function();
4    int i = 6;
5}

Images

Images can be added by using:

.. image:: <relative path tho THIS file>

e.g.

.. image:: images/logo.png

Some image parameters:

.. image:: images/logo.png
    :scale: 50%

or

.. image:: images/logo.png
    :width: 400
    :alt: Alternative text

References

Internal

References to other pages, chaper, sections, etc. must be defined explicitly.

.. _name_of_the_reference:

Note that the undescore prefix is mandatory.

These references can then be referenced via:

:ref:`Display text <name_of_the_reference>`

External

External web pages like http://www.google.de will automaticall result in a hyperlink.

To add a text that will result in a hyperlink use:
`Google <http://www.google.de>`_