The fixtures in test/odt/fodt are LibreOffice's own conversions of the
zipped fixtures in test/odt/odt, and they are compared against the very
same expectations, so that flat and zipped input are asserted to
converge on identical documents.
There are only four of them, because a flat file shares nearly all of
the reader with a zipped one: once readFODT has handed the root element
over, the converter is the very same code. Two of the four are there
for the two paths that a flat file alone reaches: image, whose data has
to be decoded from office:binary-data and typed from draw:mime-type
rather than found in the archive, and formula, whose MathML is read
from the draw:object itself rather than from a sub-document. The other
two guard against whitespace, which is peculiar to the format without
being a separate branch of the reader, since LibreOffice pretty-prints
a flat file and that indentation is in the XML the reader sees:
preformattedText is a CodeBlock, whose whitespace is significant and so
is compared exactly, and textMixedStyles is a run of nested emphasis,
where stray indentation would show up between the inlines.
`test/command/fodt-roundtrip.md` round-trips markdown through the flat
format, which also covers the writer, whose output has a timestamp in
it and so cannot be compared byte for byte.
Together with previous commits, closes#4010.
Previously it was not looking in the right directory
and not recursing.
The function now alphabetizes its results so that test output
is the same with or without `embed_data_files`.
This replaces (now deprecated but still functional) options
`--mathml`, `--mathjax`, `--gladtex`, `--katex`, `--webtex`.
The `plain` style can now be specified explicitly.
In defaults files, `html-math-method` is now
`math-method` (though `html-math-method` will still work).
Text.Pandoc.App.Opt:
- In unexported type CompletionKind, add MathMethods.
- In Opt, change `optHTMLMathMethod` to `optMathMethod`. [API change]
Text.Pandoc.Options:
- Rename HTMLMathMethod type to MathMethod. [API change]
- Rename `writerHTMLMathMethod` field of WriterOptions to
`writerMathMethod`. [API change]
Text.Pandoc.App.Completion:
- Clean up code.
- Add support for `--math-method`.
Make `--bash-completion` an alias of `--completion=bash`.
Reorganize option parsing code using a new data structure OptionSpec,
which can encode the type of completion needed by each option.
Add new unexported module Text.Pandoc.Completion.
Unexported module Text.Pandoc.CommandLineOptions: export OptionSpec.
Closes#8542.