aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Readers/Odt
AgeCommit message (Collapse)AuthorFilesLines
2017-11-06Spellcheck commentsAlexander Krotov2-6/+6
2017-11-02hlintAlexander Krotov2-5/+5
2017-10-29Source code reformatting.John MacFarlane1-1/+0
2017-10-29More hlint fixes.John MacFarlane1-1/+1
2017-10-27hlint suggestions.John MacFarlane4-9/+8
2017-10-27Automatic reformating by stylish-haskell.John MacFarlane8-76/+75
2017-06-20Odt reader: replaced collectRights with rights from Data.Either.John MacFarlane2-6/+2
2017-05-31Odt reader: remove dead codeAlbert Krewinkel7-902/+4
The ODT reader contained a lot of general code useful for working with arrows. However, many of these utils weren't used and are hence removed.
2017-01-27Shared: rename compactify', compactify'DL -> compactify, compactifyDL.John MacFarlane1-2/+2
2017-01-25Revert "Added page breaks into Pandoc."John MacFarlane2-36/+10
This reverts commit f02a12aff638fa2339192231b8f601bffdfe3e14.
2017-01-25Added page breaks into Pandoc.Hubert Plociniczak2-10/+36
This requires an updated version of pandoc-types that introduces PageBreak definition. Not that this initial commit only introduces ODT pagebreaks and distinguishes for it page breaks before, after, or both, the paragraph, as read from the style definition.
2016-11-26[odt] Infer table's caption from the paragraph (#3224)hubertp-lshift1-6/+21
ODT's reader always put empty captions for the parsed tables. This commit 1) checks paragraphs that follow the table definition 2) treats specially a paragraph with a style named 'Table' 3) does some postprocessing of the paragraphs that combines tables followed immediately by captions The ODT writer used 'TableCaption' style name for the caption paragraph. This commit follows the open office approach which allows for appending captions to table but uses a built-in style named 'Table' instead of 'TableCaption'. Any users of odt format (both writer and reader) are therefore required to change the style's name to 'Table', if necessary.
2016-11-08Inline code when text has a special styleHubert Plociniczak1-6/+20
When a piece of text has a text 'Source_Text' then we assume that this is a piece of the document that represents a code that needs to be inlined. Addapted an odt writer to also reflect that change; previously it was just writing a 'preformatted' text using a non-distinguishable font style. Code blocks are still not recognized by the ODT reader. That's a separate issue.
2016-11-01[odt] Infer tables' header props from rows (#3199)hubertp-lshift1-2/+9
ODT reader simply provided an empty header list which meant that the contents of the whole table, even if not empty, was simply ignored. While we still do not infer headers we at least have to provide default properties of columns.
2016-10-19Image with a caption needs special formattingHubert Plociniczak1-2/+6
Latex Writer only handles captions if the image's title is prefixed with 'fig:'.
2016-10-18Merge pull request #3166 from hubertp-lshift/bug/3134John MacFarlane1-3/+2
Issue 3143: Don't duplicate text for anchors
2016-10-18Merge pull request #3165 from hubertp-lshift/feature/odt-imageJohn MacFarlane1-6/+106
[odt] images parser
2016-10-18Issue 3143: Don't duplicate text for anchorsHubert Plociniczak1-3/+2
When creating an anchor element we were adding its representation as well as the original content, leading to text duplication.
2016-10-17Minor refactoringHubert Plociniczak1-10/+6
2016-10-17Infer caption from the text following the imgHubert Plociniczak1-20/+47
Frame can contain other frames with the text boxes. This is something that has not been considered before and meant that the whole construction of images was broken in those cases. Also the captions were fixed/ignored.
2016-10-14Added tests and a corner case for starting numberHubert Plociniczak1-0/+1
Review revealed that we didn't handle the case when the starting point is an empty string. While this is not a valid .odt file, we simply added a special case to deal with it. Also added tests for the new feature.
2016-10-12[ODT Parser] Include list's starting valueHubert Plociniczak2-13/+20
Previously the starting value of the lists' items has been hardcoded to 1. In reality ODT's list style definition can provide a new starting value in one of its attributes. Writers already handle the modified start value so no need to change anything in that area.
2016-10-12Basic support for images in ODT documentsHubert Plociniczak1-6/+83
Highly influenced by the docx support, refactored some code to avoid DRY.
2016-09-02Fix grouping of imports.Jesse Rosenthal3-3/+4
Some source files keep imports in tidy groups. Changing `Text.Pandoc.Compat.Monoid` to `Data.Monoid` could upset that. This restores tidiness.
2016-09-02Remove Compat.MonoidJesse Rosenthal3-3/+3
This was only necessary for GHC versions with base below 4.5 (i.e., ghc < 7.4).
2016-07-14Removed some redundant class constraints.John MacFarlane1-3/+3
2016-07-03Odt reader: Removed redundant Monoid constraints.John MacFarlane1-7/+7
2016-01-22Changed type of Shared.uniqueIdent argument from [String] to Set String.John MacFarlane1-1/+2
This avoids performance problems in documents with many identically named headers. Closes #2671.
2015-11-09Restored Text.Pandoc.Compat.Monoid.John MacFarlane3-2/+3
Don't use custom prelude for latest ghc. This is a better approach to making 'stack ghci' and 'cabal repl' work. Instead of using NoImplicitPrelude, we only use the custom prelude for older ghc versions. The custom prelude presents a uniform API that matches the current base version's prelude. So, when developing (presumably with latest ghc), we don't use a custom prelude at all and hence have no trouble with ghci. The custom prelude no longer exports (<>): we now want to match the base 4.8 prelude behavior.
2015-11-09Revert "Use -XNoImplicitPrelude and 'import Prelude' explicitly."John MacFarlane9-9/+0
This reverts commit c423dbb5a34c2d1195020e0f0ca3aae883d0749b.
2015-11-08Use -XNoImplicitPrelude and 'import Prelude' explicitly.John MacFarlane9-0/+9
This is needed for ghci to work with pandoc, given that we now use a custom prelude. Closes #2503.
2015-10-22Changed § to % in operators from Odt.Arrows.Utils.John MacFarlane5-43/+42
This prevents problems building haddocks with "C" locale. Closes #2457.
2015-10-14Use custom Prelude to avoid compiler warnings.John MacFarlane6-6/+0
- The (non-exported) prelude is in prelude/Prelude.hs. - It exports Monoid and Applicative, like base 4.8 prelude, but works with older base versions. - It exports (<>) for mappend. - It hides 'catch' on older base versions. This allows us to remove many imports of Data.Monoid and Control.Applicative, and remove Text.Pandoc.Compat.Monoid. It should allow us to use -Wall again for ghc 7.10.
2015-08-17[BUG] Haddock : * and ^ to be escaped in docsGrégory Bataille1-6/+6
2015-07-23Added odt readerMarLinn11-0/+4035
Fully implemented features: * Paragraphs * Headers * Basic styling * Unordered lists * Ordered lists * External Links * Internal Links * Footnotes, Endnotes * Blockquotes Partly implemented features: * Citations Very basic, but pandoc can't do much more * Tables No headers, no sizing, limited styling