Questions tagged [docutils]

a general purpose document processing system written in Python.

Docutils is an open-source text processing system for processing plain text documentation into useful formats such as HTML, LaTeX, man-pages, open-document or XML. It includes the markup language.

The Docutils homepage may be found here.

180 questions
1
vote
0 answers

Sphinx with rst2odt.py

I really like a lot of the features of Sphinx, but I also require the final output to be docx. I've had great luck with .rst -> .odt -> .docx using rst2odt.py (docutils) and LibreOffice. I noticed that Sphinx can generate "Docutils XML". In my mind,…
Jacob Schaer
  • 727
  • 1
  • 9
  • 14
1
vote
1 answer

How to create referenceable label node above section in sphinx

I am creating a custom directive in sphinx. This directive lists all possible objects (each one in separate section). Now I would like those objects to be referenceable from other parts (files) of documentation. I was trying to do something very…
1
vote
2 answers

Unable to run RstPreview parser in sublime text

For sublime text, I installed RstPreview, downloaded docutils-0.11, and installed it by running C:\Anaconda\python setup.py install in Command Prompt (I am using windows 7 64 bits). When I press Ctrl+Shift+R to parse a .rst file I get the…
IssamLaradji
  • 6,637
  • 8
  • 43
  • 68
1
vote
1 answer

How to print a reStructuredText node tree?

Section Parsing the Document of The Docutils Hacker's Guide mentions the quicktest.py utility that can be used to print a node tree representation of a parsed reStructuredText document. However I can't find quicktest.py anywhere in my docutils…
vitaut
  • 49,672
  • 25
  • 199
  • 336
1
vote
1 answer

Sectioning / grouping attributes inside a class

I have a class with a large number of attributes; I would like to present them grouped (rather than in a flat list), with a section-like appearance inside the class documentation. Is this possible with docutils/sphinx? Any suggestion to achieve…
eudoxos
  • 18,545
  • 10
  • 61
  • 110
1
vote
1 answer

Create table of content inside table

I want to be able to generate table of content inside a table. E.g. it should have borders and look like this: .. tabularcolumns::…
1
vote
2 answers

Global include in restructured text

I'm using reStructuredText for my blog/website and I want to add a global include file. I have access to and am happy to change the settings file I'm using to generate the html output, I just can't figure out the syntax for either: adding a default…
Jeff Tratner
  • 16,270
  • 4
  • 47
  • 67
0
votes
2 answers

docutils/reStructuredText template features

How could I customize placeholders in my .rst file with actual values? For example, I have example.rst file with following content: Header ------------------------------------ ${custom_text} I want to replace ${custom_text} property with the value…
altern
  • 5,829
  • 5
  • 44
  • 72
0
votes
1 answer

Create a latex pdf table from Python without pdflatex

i want to generate a pdf output created from latex inside a python script. Since I'ma working under windows with python xy and that i cannot install latex, i would like to know if there is a way to produce a latex output using a package from…
Mermoz
  • 14,898
  • 17
  • 60
  • 85
0
votes
0 answers

Sphinx adds span with class colon to the header

We have a project which produces html from rst files, using Sphinx. Earlier we used Sphinx version 2.1 and after upgrade to version 6.1.3 a sideeffect occurs where our headers defined like this: :header: are rendered in our html structure as small…
0
votes
0 answers

How can I implement automatic multilevel list numbering in sphinx restructedtext?

How can I implement automatic multilevel list numbering in sphinx reStructuredText? Let's say there is a to-do list somewhere in the document: (here the numbering is manual) 1. Do something #1 1.1 Do something #2 1.1.1 Do something…
0
votes
0 answers

How to make reStructuredText ASCII art that includes backslash (`\)`?

I would like to include some ASCII art in a doc-string. However, even inside literal blocks, Sphinx seems to interpret \ as the escape sequence. Is there a reStructuredText environment in which the backslash character \ is evaluated literally? I…
Paul Brodersen
  • 11,221
  • 21
  • 38
0
votes
2 answers

How to programmatically create doctrees in Sphinx?

I'm creating a Sphinx extension that generates a pretty huge number of RST files. Since I formally know the content of them, I'd like to gain time and space by directly writing the docutils, skipping the RST generation and parsing of them. Is there…
Oragon Efreet
  • 1,114
  • 1
  • 8
  • 25
0
votes
0 answers

Create directive which wraps other directives inside

We are trying to create a directive which wraps other directives inside. The following example will show an example: Directives ========== .. service_card_wrapper:: .. service_card:: .. service_card:: We did not find a proper way to…
allegoric
  • 15
  • 4
0
votes
1 answer

Pages not showing on side menu

I am using Sphinx and ReStructuredText to create documentation, but even though all pages were created the same way, only 4 out of 8 are showing on the side menu. This is my table of contents: .. toctree:: :glob: :titlesonly: * I've…