mirror of
https://github.com/jgm/pandoc.git
synced 2026-09-21 13:51:29 +08:00
Clean up implicit_figure documentation.
Explain how to specify alt text. See #11082.
This commit is contained in:
+16
-8
@@ -5712,29 +5712,37 @@ The link text will be used as the image's alt text:
|
||||
|
||||
An image with nonempty alt text, occurring by itself in a
|
||||
paragraph, will be rendered as a figure with a caption. The
|
||||
image's alt text will be used as the caption.
|
||||
image's description will be used as the caption.
|
||||
|
||||

|
||||

|
||||
|
||||
How this is rendered depends on the output format. Some output
|
||||
formats (e.g. RTF) do not yet support figures. In those
|
||||
formats, you'll just get an image in a paragraph by itself, with
|
||||
no caption. For LaTeX output, you can specify a [figure's
|
||||
positioning](https://www.overleaf.com/learn/latex/Positioning_images_and_tables#The_figure_environment)
|
||||
by adding the `latex-placement` attribute.
|
||||
|
||||
{latex-placement="ht"}
|
||||
no caption.
|
||||
|
||||
If you just want a regular inline image, just make sure it is not
|
||||
the only thing in the paragraph. One way to do this is to insert a
|
||||
nonbreaking space after the image:
|
||||
|
||||
\
|
||||
\
|
||||
|
||||
Note that in reveal.js slide shows, an image in a paragraph
|
||||
by itself that has the `r-stretch` class will fill the screen,
|
||||
and the caption and figure tags will be omitted.
|
||||
|
||||
To specify an alt text for the image that is different
|
||||
from the caption, you can use an explicit attribute (assuming the
|
||||
`link_attributes` extension is set):
|
||||
|
||||
{alt="description of image"}
|
||||
|
||||
For LaTeX output, you can specify a [figure's
|
||||
positioning](https://www.overleaf.com/learn/latex/Positioning_images_and_tables#The_figure_environment)
|
||||
by adding the `latex-placement` attribute.
|
||||
|
||||
{latex-placement="ht"}
|
||||
|
||||
### Extension: `link_attributes` ###
|
||||
|
||||
Attributes can be set on links and images:
|
||||
|
||||
Reference in New Issue
Block a user