docs/source/.
Setting up the documentation build
Install dependencies
Open a terminal in the
docs/ directory and install the required Python packages:Build the docs
From the This generates the documentation in
docs/ directory, run:docs/build/html/. Open index.html in your browser to preview it.Submitting changes
Edit the.rst files in docs/source/, then submit a pull request with your changes. If you are not comfortable with Git, open an issue with your proposed changes or contact us and we will handle it.
Style guide
Heading levels
ReStructuredText does not assign fixed decoration characters to heading levels — the hierarchy is determined by the order in which decorations first appear. OpenRocket docs use the following convention:| Level | Decoration | Usage |
|---|---|---|
| H1 | * with overline | Chapter (page title) |
| H2 | = | Section |
| H3 | - | Subsection |
| H4 | ^ | Subsubsection |
| H5 | " | Paragraph |
Horizontal rules
Insert a horizontal rule before starting each new H2 section using four or more hyphens:Adding images
Images go indocs/source/img/, following the same directory structure as the source file. Use percentage widths and always include alt text:
Hyperlinks
Admonitions
Use admonitions to call out important information:- Tip
- Note
- Warning
- Attention
danger, error, hint, important, caution.
Semantic markup roles
Sphinx roles apply semantic meaning to inline text:| Role | Example | Use for |
|---|---|---|
:menuselection: | :menuselection:File —> Open“ | Menu navigation paths |
:command: | :command:ls“ | CLI commands |
:file: | :file:conf.py“ | File names and paths |
:kbd: | :kbd:Ctrl + :kbd:C“ | Keyboard keys |
:guilabel: | :guilabel:Submit“ | UI labels and buttons |
:abbr: | :abbr:OR (OpenRocket)“ | Abbreviations with tooltips |
Substitutions
Custom substitutions are defined indocs/source/conf.py under rst_prolog. Use them to avoid repeating version numbers or other frequently updated values:
Line wrapping
Keep lines in.rst files under approximately 120 characters. Normal prose can be broken across lines freely — Sphinx treats adjacent lines as a single paragraph as long as there is no blank line between them.
For list items that span multiple lines, indent continuation lines to align with the start of the list item text.
Todo notes
Mark incomplete sections with atodo directive:
todo_include_todos = True in conf.py to render all pending todos in the output.