aboutsummaryrefslogtreecommitdiff
path: root/test/tables.fb2
AgeCommit message (Collapse)AuthorFilesLines
2020-04-15Use the new builders, modify readers to preserve empty headersdespresc1-1/+1
The Builder.simpleTable now only adds a row to the TableHead when the given header row is not null. This uncovered an inconsistency in the readers: some would unconditionally emit a header filled with empty cells, even if the header was not present. Now every reader has the conditional behaviour. Only the XWiki writer depended on the header row being always present; it now pads its head as necessary.
2019-08-25Use new doctemplates, doclayout.John MacFarlane1-1/+0
+ Remove Text.Pandoc.Pretty; use doclayout instead. [API change] + Text.Pandoc.Writers.Shared: remove metaToJSON, metaToJSON' [API change]. + Text.Pandoc.Writers.Shared: modify `addVariablesToContext`, `defField`, `setField`, `getField`, `resetField` to work with Context rather than JSON values. [API change] + Text.Pandoc.Writers.Shared: export new function `endsWithPlain` [API change]. + Use new templates and doclayout in writers. + Use Doc-based templates in all writers. + Adjust three tests for minor template rendering differences. + Added indentation to body in docbook4, docbook5 templates. The main impact of this change is better reflowing of content interpolated into templates. Previously, interpolated variables were rendered independently and intepolated as strings, which could lead to overly long lines. Now the templates interpolated as Doc values which may include breaking spaces, and reflowing occurs after template interpolation rather than before.
2018-04-05FB2 writer: represent HorizontalRule as empty lineAlexander Krotov1-1/+14
HorizontalRule corresponds to <hr> element in the default output format, HTML. Current HTML standard defines <hr> element as "paragraph-level thematic break". In typography it is often represented by extra space or centered asterism ("⁂"), but since FB2 does not support text centering, empty line (similar to extra space) is the only solution. Line breaks, on the other hand, don't generate <empty-line /> anymore. Previously line breaks generated <empty-line /> element inside paragraph, which is not allowed. So, this commit addresses issue #2424 ("FB2 produced by pandoc doesn't validate"). FB2 does not have a way to represent line breaks inside paragraphs. They are replaced with LF character, which is not rendered by FB2 readers, but at least preserves some information.
2017-11-01FB2 writer: Add "unrecognised" genre to <title-info>Alexander Krotov1-1/+1
XML schema requires at least one genre.
2017-11-01FB2 writer: remove <annotation> from <body>Alexander Krotov1-1/+1
<annotation> is not allowed inside <body> according to FictionBook2 XML schema. Besides that, the same information is already placed inside <description>. Related bug: #2424
2017-02-04Moved tests/ -> test/.John MacFarlane1-0/+3