aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2018-02-06Muse reader: avoid reparsing at the top levelAlexander Krotov1-2/+14
Blocks following paragraphs are parsed only once at the top level. Lists still take exponential time to parse, but this time is not doubled anymore when this list terminates paragraph.
2018-02-06Muse reader: implement paraUntilAlexander Krotov1-8/+36
paraUntil does not discard the result of the following block parsing. This change is a part of Muse reader refactoring to avoid reparsing.
2018-02-05INSTALL.md: mentioning Stack version. (#4343)Adam Brandizzi1-1/+1
2018-02-05Update default.nix to current nixpkgs-unstable for hslua-0.9.5 (#4348)jarlg1-8/+3
2018-02-05Muse reader: avoid parsing newline after paragraph twiceAlexander Krotov1-5/+3
Removed lookAhead from blankline, so it is consumed.
2018-02-05Muse reader: make block parsers responsible for parsing newlineAlexander Krotov1-3/+5
Block parsers must always stop after newline or at the end of file.
2018-02-05Muse reader: test that two blank lines after verse can separate list itemsAlexander Krotov1-0/+21
Unlike paragraph and <quote> tag parsers, verse parser consumes newline. For this reason only three or more blank lines can separate list items.
2018-02-05Muse reader: test that lists can be separated with two blanklines after ↵Alexander Krotov1-0/+27
blockquote Existing tests only checked this for paragraphs.
2018-02-04Muse reader: simplify listItemContents' with sepBy1Alexander Krotov1-4/+2
2018-02-03C -> c.John MacFarlane1-1/+1
2018-02-03Muse writer: write image width specified in percent in Text::Amuse modeAlexander Krotov2-2/+10
2018-02-02Determine image size for PDFs.John MacFarlane1-1/+22
Closes #4322.
2018-02-01Use latest pandoc-citeproc.John MacFarlane2-2/+2
2018-02-01TEI writer: Use height instead of depth for images.John MacFarlane1-1/+1
Closes #4331.
2018-02-01Bump blaze-markup, blaze-html lower bounds to 0.8, 0.9.John MacFarlane1-2/+2
This is needed because the type constructor Empty in MarkupM has changed, and the HTML writer assumes the constructor has an argument. Closes #4334.
2018-01-31Muse reader: replace ParserState with MuseStateAlexander Krotov1-29/+104
2018-01-31Export list marker parsers from Text.Pandoc.ParsingAlexander Krotov1-0/+5
2018-01-30Muse writer: don't wrap displayMath into <verse>Alexander Krotov3-7/+4
<verse> is a block tag and displayMath is an inline element. Writing <verse> around displayMath could result in nested <verse> tags.
2018-01-29Muse writer: escape nonbreaking space ("~~")Alexander Krotov2-1/+3
2018-01-29Muse reader: simplify block tag parsing codeAlexander Krotov1-21/+12
2018-01-29Muse reader: parse inline <literal> without parseFromStringAlexander Krotov1-2/+1
2018-01-29Muse reader: parse <comment> and <verbatim> without parseFromStringAlexander Krotov1-4/+2
2018-01-28MANUAL.txt: self-contained implies standalone (#4304)Daniel Lublin1-7/+7
2018-01-28CONTRIBUTING.md: label was renamed. (#4310)Adam Brandizzi1-2/+2
See https://groups.google.com/forum/#!msg/pandoc-discuss/mrFsj5RzNFA/Pnd3zubWBwAJ;context-place=searchin/pandoc-discuss/%22good$20first$20issue%22%7Csort:date
2018-01-28Muse reader: parse verse tag contents without parseFromStringAlexander Krotov1-4/+3
2018-01-28Muse reader: make verseLine return Inlines, not StringAlexander Krotov1-4/+4
2018-01-28Muse reader: parse directives without parseFromStringAlexander Krotov1-7/+5
2018-01-28Muse reader: fix parsing of trailing whitespaceAlexander Krotov2-8/+7
Newline after whitespace now results in softbreak instead of space.
2018-01-28Muse reader: simplify paragraph parsingAlexander Krotov1-3/+2
Blank lines are already handled by blockElements.
2018-01-27Docx writer tests: correct test name.Jesse Rosenthal1-1/+1
2018-01-27Docx writer tests: Add tests for custom stylesJesse Rosenthal4-0/+10
2018-01-27Add docx golden tests to cabal file.Jesse Rosenthal1-0/+1
2018-01-27Docx writer tests: Use new golden frameworkJesse Rosenthal27-127/+120
These are based off the reader tests, with some removed (where the reader output was identical, based on different docx inputs). There are still more to be added. In particular, tests for custom-styles need to be added. All golden docx files have been checked in MS Word 2013 (windows). There is no corruption. There is questionable output in the `tables` test: the three tables seemed to be joined. This will be addressed in a future commit, and the golden docx file will be changed.
2018-01-27Docx writer: make more deterministic to facilitate testingJesse Rosenthal1-10/+16
This will allow us to compare files directly in a golden test. Times are still based on IO, but we will be able to safely skip those. Changes: - `getUniqueId` now calls to the state to get an incremented digit, instead of calling to P.uniqueHash. - we always start the PRNG in mkNumbering/mkAbstractNum with the same seed (1848), so our randoms should be the same each time.
2018-01-27Docx writer: Fix ids in comment writingJesse Rosenthal1-9/+17
Comments from `--track-changes=all` were producing corrupt docx, because the writer was trying to get id from the `(ID,_,_)` field of the attributes, and ignoring the "id" entry in the key-value pairs. We now check both. There is a larger conversation to be had about the right way to treat "id" and "class" entries in kvs, but this fix will correctly interpret the output of the docx reader work.
2018-01-25Tests: Abstract powerpoint tests out to OOXML tests.Jesse Rosenthal3-176/+191
There is very little pptx-specific in these tests, so we abstract out the basic testing function so it can be used for docx as well. This should allow us to catch some errors in the docx writer that slipped by the roundtrip testing.
2018-01-25ConTeXt writer: new section syntax and --section-divs (#4295)Henri Menke5-56/+103
Fixes #2609. This PR introduces the new-style section headings: `\section[my-header]{My Header}` -> `\section[title={My Header},reference={my-header}]`. On top of this, the ConTeXt writer now supports the `--section-divs` option to write sections in the fenced style, with `\startsection` and `\stopsection`.
2018-01-25Dock writer: Fix deletion track changesJesse Rosenthal1-6/+6
This had been mistakenly written as a second insertion function. Closes: #4303
2018-01-24Muse reader: fix matching of closing inline tagsAlexander Krotov2-2/+6
2018-01-24Muse reader: remove `block` functionAlexander Krotov1-7/+4
2018-01-23Lua filters: store constructors in registryAlbert Krewinkel3-3/+29
Lua functions used to construct AST element values are stored in the Lua registry for quicker access. Getting a value from the registry is much faster than getting a global value (partly to idiosyncrasies of hslua); this change results in a considerable performance boost.
2018-01-23Lua: move getTag from StackInstances to UtilAlbert Krewinkel2-13/+17
Change: minor
2018-01-23Powerpoint writer tests: hlint cleanups.Jesse Rosenthal1-14/+12
2018-01-22Merge pull request #4291 from hmenke/xtablesJohn MacFarlane3-5/+5
ConTeXt writer: xtables: correct wrong usage of caption
2018-01-23ConTeXt writer: xtables: correct wrong usage of captionHenri Menke3-5/+5
2018-01-22Powerpoint writer tests: add tests for two-column layout and imagesJesse Rosenthal5-0/+24
Powerpoint output checked in MS PowerPoint 2013 (Windows)
2018-01-22Powerpoint writer: Add further testsJesse Rosenthal5-0/+17
Tests added for: - table of contents - endnotes - endnotes with table of contents Powerpoint output checked in MS PowerPoint 2013 (Windows)
2018-01-22Powerpoint writer tests: simplify updating functionJesse Rosenthal1-7/+1
We had previously re-read the native file and converted it to Powerpoint. But we have already done that in constructing the test archive. So now we just convert the archive back to a bytestring and write it to disk.
2018-01-22Powerpoint tests: Convert to golden testsJesse Rosenthal1-136/+147
This will allow us to rebuild the pptx files in the test dir more easily if we make a change in the writer.
2018-01-22Muse writer: join code with different attributes during normalizationAlexander Krotov2-2/+3