From: Kefu Chai Date: Sun, 14 Mar 2021 12:12:37 +0000 (+0800) Subject: doc/dev: specify lexer of pygment X-Git-Tag: v17.1.0~2536^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=cf816cfdbebe8f3664ec89db38a095e1313443b4;p=ceph.git doc/dev: specify lexer of pygment for better rendering result Signed-off-by: Kefu Chai --- diff --git a/doc/dev/documenting.rst b/doc/dev/documenting.rst index 1e10776ce03..3e4c942faed 100644 --- a/doc/dev/documenting.rst +++ b/doc/dev/documenting.rst @@ -33,7 +33,9 @@ markup supported by Breathe_. .. _Doxygen: http://www.doxygen.nl/ .. _Breathe: https://github.com/michaeljones/breathe -The general format for function documentation is:: +The general format for function documentation is + +.. code-block:: c /** * Short description diff --git a/doc/dev/encoding.rst b/doc/dev/encoding.rst index 398c85d95f9..81b52500e63 100644 --- a/doc/dev/encoding.rst +++ b/doc/dev/encoding.rst @@ -13,7 +13,7 @@ Adding a field to a structure You can see examples of this all over the Ceph code, but here's an example: -:: +.. code-block:: cpp class AcmeClass { @@ -55,7 +55,7 @@ at the end of the ``encode`` and ``decode`` functions, and incrementing the versions in ``ENCODE_START`` and ``DECODE_START``. For example, here's how to add a third field to ``AcmeClass``: -:: +.. code-block:: cpp class AcmeClass {