| 1 |
Embedded images |
| 2 |
=============== |
| 3 |
|
| 4 |
The image_loading_ setting can be used to tell the "html5" writer |
| 5 |
to embed still images in the output document. [#]_ SVG images are |
| 6 |
directly included, other images are base64_ encoded and included |
| 7 |
as a `data URI`_. |
| 8 |
|
| 9 |
.. figure:: ../../../docs/user/rst/images/biohazard.png |
| 10 |
:alt: biohazard |
| 11 |
:align: left |
| 12 |
:width: 2em |
| 13 |
:figwidth: 45% |
| 14 |
:class: align-center |
| 15 |
|
| 16 |
Embedded PNG image in a figure. |
| 17 |
|
| 18 |
.. figure:: ../../../docs/user/rst/images/biohazard-scaling.svg |
| 19 |
:alt: biohazard |
| 20 |
:align: right |
| 21 |
:width: 2em |
| 22 |
:figwidth: 45% |
| 23 |
:class: align-center |
| 24 |
|
| 25 |
Embedded SVG image in a figure. |
| 26 |
|
| 27 |
Embedded inline PNG image |inline-embedded| and SVG image |
| 28 |
|inline-embedded-2| scaled to a height of 0.8 em. |
| 29 |
|
| 30 |
.. |inline-embedded| image:: ../../../docs/user/rst/images/biohazard.png |
| 31 |
:height: 0.8 em |
| 32 |
.. |inline-embedded-2| image:: |
| 33 |
../../../docs/user/rst/images/biohazard-scaling.svg |
| 34 |
:height: 0.8 em |
| 35 |
|
| 36 |
|
| 37 |
.. image:: ../../../docs/user/rst/images/biohazard.svg |
| 38 |
:align: left |
| 39 |
:width: 1.5em |
| 40 |
:height: 1.5em |
| 41 |
:loading: lazy |
| 42 |
|
| 43 |
The ``:loading:`` option of `"image" and "figure" directives`_ overrides the |
| 44 |
image_loading_ setting for the respective image. |
| 45 |
|
| 46 |
.. [#] Videos are only embedded if indicated in the |
| 47 |
`"image" directive`_'s "loading" option. |
| 48 |
|
| 49 |
.. _image_loading: |
| 50 |
https://docutils.sourceforge.io/docs/user/config.html#image-loading |
| 51 |
.. _base64: https://en.wikipedia.org/wiki/Base64 |
| 52 |
.. _data URI: https://en.wikipedia.org/wiki/Data_URI_scheme |
| 53 |
.. _"image" directive: |
| 54 |
.. _"image" and "figure" directives: |
| 55 |
../../../docs/ref/rst/directives.html#images |