Commit graph

7160 commits

Author SHA1 Message Date
John MacFarlane
bbd7b533ae make_oxs_package.sh - use OSX env variable. 2016-07-14 10:29:34 -07:00
John MacFarlane
d5c3551276 Version to 1.17.2. 2016-07-14 10:26:00 -07:00
John MacFarlane
0b0a0e730f Removed some redundant class constraints. 2016-07-14 08:54:06 -07:00
John MacFarlane
3d86228c5b Fixed lts6 travis build. 2016-07-14 08:46:56 -07:00
John MacFarlane
06a3e6a03f Merge pull request #3019 from tarleb/org-verbatim-fix
Org reader: fix parsing of verbatim inlines
2016-07-14 08:43:39 -07:00
John MacFarlane
00b11bcbcf Fixed exponential parsing bug in textile reader.
Closes #3020.
2016-07-14 08:42:38 -07:00
Albert Krewinkel
529146decf Org reader: fix parsing of verbatim inlines
Org rules for allowed characters before or after markup chars were not
checked for verbatim text.  This resultet in wrong parsing outcomes of
if the verbatim text contained e.g. space enclosed markup characters as
part of the text (`=is_substr = True=`).  Forcing the parser to update
the positions of allowed/forbidden markup border characters fixes this.

This fixes #3016.
2016-07-14 13:33:25 +02:00
John MacFarlane
106786ef1b stack.yaml - use ghc 8.01 and nightly. 2016-07-13 23:03:08 -07:00
John MacFarlane
418ad5cc81 Allow QuickCheck 2.9. 2016-07-11 08:34:35 +01:00
John MacFarlane
e2659a46db Merge pull request #3014 from tarleb/org-writer-div
Org writer: improve Div handling
2016-07-05 12:46:13 -07:00
Albert Krewinkel
5378b7c5bd
Org writer: improve Div handling
Div blocks handling is changed to make the output look more like
idiomatic org mode:

  - Div-wrapped content is output as-is if the div's attribute is the
    null attribute.
  - Div containers with an id but neither classes nor key-value pairs
    are unwrapped and the id is added as an anchor.
  - Divs with classes associated with greater block elements are
    wrapped in a `#+BEGIN`...`#+END` block.
  - The old behavior for Divs with more complex attributes is kept.
2016-07-05 11:49:45 +02:00
John MacFarlane
6ea8ff19c3 Added http-client dependencies to stack.yaml files. 2016-07-04 10:24:28 -07:00
John MacFarlane
374614aaf7 Depend on http-client 0.5, http-client-tls 0.3 2016-07-04 10:23:37 -07:00
John MacFarlane
46f3deb248 Merge pull request #3012 from tarleb/org-drop-ugly-pragma
Org reader: replace ugly code with view pattern
2016-07-04 10:03:24 -07:00
Albert Krewinkel
f417fecf5f
Org reader: replace ugly code with view pattern
Some less-than-smart code required a pragma switching of overlapping
pattern warnings in order to compile seamlessly.  Using view patterns
makes the code easier to read and also doesn't require overlapping
pattern checks to be disabled.
2016-07-04 11:20:05 +02:00
John MacFarlane
e548b8df07 Merge pull request #3010 from tarleb/org-header-tree
Org reader: support archived trees, headline levels export setting
2016-07-03 22:57:22 -07:00
John MacFarlane
4099b2dca4 Odt reader: Removed redundant Monoid constraints. 2016-07-03 22:47:32 -07:00
John MacFarlane
b203a31ba7 Fix warning for parseURl import. 2016-07-03 22:26:08 -07:00
John MacFarlane
261c3af053 CPP workaround for deprecation of parseUrl in http-client. 2016-07-03 21:29:47 -07:00
Albert Krewinkel
5ffa4abf72
Org reader: support headline levels export setting
The depths of headlines can be modified using the `H` option.  Deeper
headlines will be converted to lists.
2016-07-03 23:28:45 +02:00
John MacFarlane
1dbbb2f41a Travis: don't test on lts-5. 2016-07-03 13:28:28 -07:00
John MacFarlane
40caf516aa Allow 'standout' as a beamer frame option.
## Slide title {.standout}

Closes #3007.
2016-07-03 11:56:03 -07:00
John MacFarlane
44ce21e134 stack.yaml: use 6.5 resolver. 2016-07-03 11:54:11 -07:00
Albert Krewinkel
c1f6bd2640
Org reader: put export setting parser into module
Export option parsing is distinct enough from general block parsing to
justify putting it into a separate module.
2016-07-02 13:14:09 +02:00
John MacFarlane
e0cc9e4463 LaTeX reader: strip off double quotes around image source if present.
Avoids interpreting these as part of the literal filename.
See #2825.
2016-07-01 15:47:42 -07:00
John MacFarlane
7e712abfa6 LaTeX writer: don't URI-escape image source.
Usually this is a local file, and replacing spaces with `%20`
ruins things.  Closes #2825.
2016-07-01 15:41:33 -07:00
John MacFarlane
da38bebbdc beamer, latex templates: pass biblatexoptions directly in package load.
This allows runtime optinos to be used.  Fixes jgm/pandoc-citeproc#201
2016-07-01 15:13:46 -07:00
Albert Krewinkel
c4cf6d237f
Org reader: support archived trees export options
Handling of archived trees can be modified using the `arch` option.
Archived trees are either dropped, exported completely, or collapsed to
include just the header when the `arch` option is nil, non-nil, or
`headline`, respectively.
2016-07-01 23:05:33 +02:00
Albert Krewinkel
1ebaf6de11
Org reader: refactor comment tree handling
Comment trees were handled after parsing, as pattern matching on lists
is easier than matching on sequences.  The new method of reading
documents as trees allows for more elegant subtree removal.
2016-07-01 23:05:32 +02:00
Albert Krewinkel
17484ed01a
Org reader: parse as headlines, convert to blocks
Emacs org-mode is based on outline-mode, which treats documents as trees
with headlines are nodes.  The reader is refactored to parse into a
similar tree structure.  This simplifies transformations acting on
document (sub-)trees.
2016-07-01 23:05:32 +02:00
Albert Krewinkel
2f8d6755f4
Org reader: improve tag and properties type safety
Specific newtype definitions are used to replace stringly typing of tags
and properties.  Type safety is increased while readability is improved.
2016-07-01 23:05:32 +02:00
John MacFarlane
b3382cf377 ZimWiki writer: removed commented out code that confused Haddock.
See https://travis-ci.org/jgm/pandoc/jobs/141542247
2016-07-01 10:39:32 -07:00
Alex Ivkin
7fdcd9a6e2 Added ZimWiki format to documentation and cabal description. 2016-07-01 00:12:25 -07:00
Alex Ivkin
a73c95f61d Added Zim Wiki writer, template and tests. 2016-06-30 23:59:43 -07:00
Jesse Rosenthal
b103f829f0 Docx writer: set paragraph to FirstPara after display math
We treat display math like block quotes, and apply FirstParagraph style
to paragraphs that follow them. These can be styled as the user
wishes. (But, when the user is using indentation, this allows for
paragraphs to continue after display math without indentation.)
2016-07-01 01:14:16 -04:00
Jesse Rosenthal
2c62f0e122 Writers: treat SoftBreak as space for stripping
In Writers.Shared, we strip leading and trailing spaces for display
math. Since SoftBreak's are treated as spaces, we should strip those
too.
2016-07-01 00:52:52 -04:00
John MacFarlane
3429fa6438 LaTeX reader: fixed \cite so it is a NormalCitation not AuthorInText. 2016-06-29 07:59:00 -07:00
John MacFarlane
a349814665 Merge pull request #3001 from tarleb/org-figure-label
Org reader: support figure labels
2016-06-26 17:51:51 -07:00
John MacFarlane
7ded9d4af0 Include table of contents in README.html in Windows package. 2016-06-26 17:24:15 -07:00
Albert Krewinkel
0f3f5ce1a1 Org reader: support figure labels
Figure labels given as `#+LABEL: thelabel` are used as the ID of the
respective image.  This allows e.g. the LaTeX to add proper `\label`
markup.

This fixes half of #2496 and #2999.
2016-06-26 20:42:22 +02:00
John MacFarlane
38c97320ef Textile reader: Fix overly aggressive interpretation as images.
Spaces are not allowed in the image URL in textile.

Closes #2998.
2016-06-25 14:04:47 -07:00
John MacFarlane
0f9c6c4db0 Added secnumdepth variable to LaTeX template.
Closes #2920.
2016-06-25 13:13:09 -07:00
John MacFarlane
d283f9c864 Fixed RST links with no explicit link text.
The link

    `<foo>`_

should have `foo` as both its link text and its URL.

See RST spec at
<http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#embedded-uris-and-aliases>

"The reference text may also be omitted, in which case the URI will be
duplicated for use as the reference text. This is useful for relative
URIs where the address or file name is also the desired reference text:

See `<a_named_relative_link>`_ or `<an_anonymous_relative_link>`__
for details."

Closes Debian #828167 -- reported by Christian Heller.
2016-06-25 10:56:37 -07:00
John MacFarlane
a4294800bf Make --webtex work with the Markdown writer.
Closes #1177.  This is a convenient option for people using
websites whose Markdown flavors don't provide for math.
2016-06-24 14:57:21 -07:00
John MacFarlane
5bdf217135 Added texmath 0.8.6.4 to windows/stack.yaml. 2016-06-24 10:45:01 -07:00
John MacFarlane
69e59e7f29 Process markdown extensions on command line in L->R order.
Previously they were processed, very unintuitively, in R->L
order, so that `markdown-tex_math_dollars+tex_math_dollars`
had `tex_math_dollars` disabled.

Closes #2995.
2016-06-23 23:04:42 -07:00
John MacFarlane
7f4ee830c9 Improved Windows installer - don't ignore properties set on command-line.
See #2708.  Needs testing to see if this resolves the issue.

Thanks to @nkalvi.
2016-06-23 11:09:25 -07:00
John MacFarlane
a820c1bd1c Textile reader: fixed attributes.
Attributes can't be followed by a space.

So,

    _(class)emph_

but

    _(noclass) emph_

Closes #2984.
2016-06-23 10:28:54 -07:00
John MacFarlane
139d418d4b Markdown writer: use raw HTML for simple, pipe tables with linebreaks.
Markdown line breaks involve a newline, and simple and pipe
tables can't contain one.

Closes #2993.
2016-06-23 10:00:33 -07:00
Jesse Rosenthal
5fac8266d8 README: update to include track-changes comments. 2016-06-23 10:50:46 -04:00