2 Commits
Author SHA1 Message Date
John MacFarlane 29c5afb305 RST writer: fix figure handling.
This fixes a number of regressions from pandoc 2.x.

Properly handle caption, alt attribute in figures.

No longer treat a paragraph with a single image in it as a figure
(we have a dedicated Figure element now).

Closes #8930, closes #8871.
2023-07-12 09:13:32 -07:00
John MacFarlane c43e2dc0f4 RST writer: better image handling.
- An image alone in its paragraph (but not a figure) is now
  rendered as an independent image, with an `alt` attribute
  if a description is supplied.
- An inline image that is not alone in its paragraph will
  be rendered, as before, using a substitution.
  Such an image cannot have a "center", "left", or
  "right" alignment, so the classes `align-center`,
  `align-left`, or `align-right` are ignored.
  However, `align-top`, `align-middle`, `align-bottom`
  will generate a corresponding `align` attribute.

Closes #6948.
2020-12-13 15:25:46 -08:00