Codeblocks

Basic examples

List files, 'let see':

ls

Show more:

ls -al

Or short:

ls -1

Code-block with line numbers

Note: When you select code, the linenumbers should not be selected, also they are technically WITHIN the html that is selected. See theme#149.

Select some of the following code to test whether the line number get selected as well.

Example of 'contents' directive
 1This is an example block. Next two line have 'emphasis' background color.
 2With another line.
 3And a third one.
 4
 5.. code-block:: rst
 6   :caption: Example of 'contents' directive
 7   :linenos:
 8   :emphasize-lines: 2,3
 9   :force:
10
11   This is an example block.
12   With another line.
13   And a third one.

Image and code-block without caption

../_images/a4.jpg
.
├── composer.json
├── ext_emconf.php
.

Image and code-block with caption

Code blocks with caption show up in html as div.literal-block-wrapper.docutils.container due to docutils. Since DRC v3.0.dev2 html post-processing is changing this to div.literal-block-wrapper.docutils.du-container. This should prevent sphinx_typo3_theme issue #148.

../_images/a4.jpg
Generated extension with boilerplate code
.
├── composer.json
├── ext_emconf.php
.

Figure and code-block without caption

../_images/a4.jpg

Caption of image

.
├── composer.json
├── ext_emconf.php
.

Figure and code-block with caption

../_images/a4.jpg

Caption of image

Generated extension with boilerplate code
.
├── composer.json
├── ext_emconf.php
.

Code-block without caption within figure's caption

../_images/a4.jpg

Caption of image

.
├── composer.json
├── ext_emconf.php
.

Code-block with caption within figure's caption

../_images/a4.jpg

Caption of image

Generated extension with boilerplate code
.
├── composer.json
├── ext_emconf.php
.