StandardBlockDirectives

Defines all supported standard block directives of the reStructuredText reference parser.

The following directives are fully supported:

  • compound
  • container
  • admonition
  • attention
  • caution
  • danger
  • error
  • hint
  • important
  • note
  • tip
  • warning
  • topic
  • sidebar
  • rubric
  • epigraph
  • highlights
  • pull-quote
  • parsed-literal
  • table
  • contents
  • sectnum
  • figure
  • image
  • header
  • footer
  • title
  • meta

The following directives are supported with some limitations:

  • code does currently not support syntax highlighting (it allows to set the language so client-side highlighters can be integrated if required)

  • sectnum does currently not support the prefix, suffix and start options.

  • raw does not support the file or url options.

  • include does not support any of the options apart from the filename. See the API entry for this directive for details.

Finally, for some directives there is currently no support planned:

  • math (would require external tools)
  • csv-table, list-table (would just require some work, contributions are welcome)
  • target-notes, class (these would require processing beyond the directive itself, therefore would require new API)
class Object
trait Matchable
class Any

Value members

Concrete methods

def admonition(style: String, title: String): DirectivePartBuilder[Block]

The attention, caution, danger, error, hint, important, note, tip and warning directives, which are all identical apart from their title which can be specified with the style parameter. See http://docutils.sourceforge.net/docs/ref/rst/directives.html#specific-admonitions for details.

The attention, caution, danger, error, hint, important, note, tip and warning directives, which are all identical apart from their title which can be specified with the style parameter. See http://docutils.sourceforge.net/docs/ref/rst/directives.html#specific-admonitions for details.

The code directive, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#code for details. The current implementation does not support syntax highlighting.

The code directive, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#code for details. The current implementation does not support syntax highlighting.

The image directive for block elements, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#image for details.

The image directive for block elements, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#image for details.

The epitaph, highlights and pull-quote directives, which are all identical apart from the style parameter, see epigraph, highlights and pull-quote for details.

The epitaph, highlights and pull-quote directives, which are all identical apart from the style parameter, see epigraph, highlights and pull-quote for details.

The table directive, adding a title to standard reStructuredText tables, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#table for details.

The table directive, adding a title to standard reStructuredText tables, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#table for details.

Concrete fields

All standard block directives currently supported by Laika, except for the raw directive which needs to be enabled explicitly.

All standard block directives currently supported by Laika, except for the raw directive which needs to be enabled explicitly.

The include directive, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#including-an-external-document-fragment for details.

Note that the only argument supported in Laika is the default argument specifying the path of the file to include. The other options supported by reStructuredText original parser do not make sense in the execution context of Laika. They assume that the file is parsed everytime an include directive is used, whereas in Laika all files of the source tree get parsed in one go and then the include step simply references the previously parsed node tree. This is both simpler and more efficient when the same file gets included in multiple places.

The meta directive, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#meta for details.

In Laika there is no special document tree element for metadata. Therefore the result will be accessible through the generic config property in the Document class.

The raw directive, which is not enabled by default, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#raw-data-pass-through for details. It can be enabled with Transformer.from(ReStructuredText).to(HTML).withRawContent.

The raw directive, which is not enabled by default, see http://docutils.sourceforge.net/docs/ref/rst/directives.html#raw-data-pass-through for details. It can be enabled with Transformer.from(ReStructuredText).to(HTML).withRawContent.