diff options
author | Georg Brandl <georg@python.org> | 2014-09-19 13:18:29 +0200 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2014-09-19 13:18:29 +0200 |
commit | 109cb873de79504d9c9d6034a82a8bc47de5e08b (patch) | |
tree | 4116dc9b0da3711a98f7b7d118ecd2d488c3ba7b /doc/markup/code.rst | |
parent | c3eb669f8aa67afff8aaf6f069b186869bd31158 (diff) | |
download | sphinx-git-109cb873de79504d9c9d6034a82a8bc47de5e08b.tar.gz |
Use "any" role in changelog.
Diffstat (limited to 'doc/markup/code.rst')
-rw-r--r-- | doc/markup/code.rst | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/doc/markup/code.rst b/doc/markup/code.rst index f69bb161b..b948dc386 100644 --- a/doc/markup/code.rst +++ b/doc/markup/code.rst @@ -36,21 +36,29 @@ installed) and handled in a smart way: highlighted as Python). * The highlighting language can be changed using the ``highlight`` directive, - used as follows:: + used as follows: - .. highlight:: c + .. rst:directive:: .. highlight:: language - This language is used until the next ``highlight`` directive is encountered. + Example:: + + .. highlight:: c + + This language is used until the next ``highlight`` directive is encountered. * For documents that have to show snippets in different languages, there's also a :rst:dir:`code-block` directive that is given the highlighting language - directly:: + directly: + + .. rst:directive:: .. code-block:: language + + Use it like this:: - .. code-block:: ruby + .. code-block:: ruby - Some Ruby code. + Some Ruby code. - The directive's alias name :rst:dir:`sourcecode` works as well. + The directive's alias name :rst:dir:`sourcecode` works as well. * The valid values for the highlighting language are: |