Commit Graph
10211 Commits
Author SHA1 Message Date
John MacFarlane 67cabb2a0d Use Default-extensions rather than ghc-options for NoImplicitPrelude.
To satisfy 'cabal check'.
2015-11-08 21:10:31 -08:00
John MacFarlane 5a9ca26172 Merge pull request #2502 from minoki/latex-comment-environment
LaTeX reader: Handle `comment` environment.
2015-11-08 17:57:52 -08:00
John MacFarlane 237c10992e Merge pull request #2505 from tarleb/org-header-markup-fix
Org reader: fix markup parsing in headers
2015-11-08 17:17:19 -08:00
John MacFarlane c423dbb5a3 Use -XNoImplicitPrelude and 'import Prelude' explicitly.
This is needed for ghci to work with pandoc, given that we
now use a custom prelude.

Closes #2503.
2015-11-08 16:56:59 -08:00
Albert Krewinkel e3b4844bd7 Org reader: fix markup parsing in headers
Markup as the very first item in a header wasn't recognized.  This was
caused by an incorrect parser state: positions at which inline markup
can start need to be marked explicitly by changing the parser state.
This wasn't done for headers.  The proper function to update the state
is now called at the beginning of the header parser, fixing this issue.

This fixes #2504.
2015-11-08 22:32:00 +01:00
ARATA Mizuki 94500f7469 LaTeX reader: Handle comment environment.
The `comment` environment is handled in a similar way to the `verbatim` environment, except that its content is discarded.
2015-11-08 02:24:25 +09:00
John MacFarlane da05619118 Merge pull request #2472 from adunning/patch-1
Update LaTeX/ConTeXt variable usage in README.
2015-11-04 15:58:46 -08:00
John MacFarlane 411a25306c LaTeX writer: properly handle footnotes in captions.
Closes #1506.
2015-11-01 15:30:05 -08:00
John MacFarlane c4ea64203a LaTeX writer: avoid footnotes in list of figures.
Footnotes aren't allowed in the list of figures.  This
patch causes footnotes to be stripped from captions when
entered into the list of figures.

Footnotes still don't actually WORK in captions in latex/pdf,
but at least an error is no longer raised.

See #1506.
2015-11-01 13:42:36 -08:00
John MacFarlane eb8aee477d Pipe tables with long lines now get relative cell widths.
If a pipe table contains a line longer than the column
width (as set by `--columns` or 80 by default), relative
widths are computed based on the widths of the separator lines
relative to the column width.

This should solve persistent problems with long pipe tables in
LaTeX/PDF output, and give more flexibility for determining
relative column widths in other formats, too.

For narrower pipe tables, column widths of 0 are used,
telling pandoc not to specify widths explicitly in output
formats that permit this.

Closes #2471.
2015-10-30 12:37:08 -07:00
John MacFarlane 7843b5759a HTML writer: use width on whole table if col widths sum to < 100%.
Otherwise some browsers display the table with the columns
separated far apart.
2015-10-30 12:36:36 -07:00
John MacFarlane 893ba9863c Beamer template: added code to prevent slide breaks inside paragraphs.
This will matter, in practice, only when `allowframebreaks` is used.

It is especially helpful for bibliography slides.

Closes #2442. Thanks to Nick Bart for the solution.
2015-10-30 11:07:44 -07:00
John MacFarlane 12a0110a0a Beamer template: added code to prevent slide breaks inside paragraphs.
This will matter, in pracitce, only when `allowframebreaks` is used.

It is especially helpful for bibliography slides.

Closes #2442. Thanks to Nick Bart for the solution.
2015-10-30 11:04:48 -07:00
John MacFarlane 532ae22c29 Textile reader: don't do smart punctuation unless explicitly asked.
Closes #2480.

Note that although smart punctuation is part of the textile
spec, it's not always wanted when converting from textile
to, say, Markdown.  So it seems better to make this an option.
2015-10-30 10:54:07 -07:00
John MacFarlane d1ba023d9e Beamer template: fix incompatibility of section slides with natbib.
Natbib (and presumably biblatex) bibliography commands create
their own section.  Since these are in frame environments,
we have an incompatibility with the `\AtBeginSection` macro
which creates a special frame when a new section occurs.
(We can't have a frame inside another frame.)

This change disables `\AtBeginSection` inside bibliography
slides.

Thinks to Yihui Xie for bringing the problem to my attention.
This supersedes #145.  See discussion there.
2015-10-29 10:21:56 -07:00
John MacFarlane a3c8439ad6 Beamer template: fix incompatibility of section slides with natbib.
Natbib (and presumably biblatex) bibliography commands create
their own section.  Since these are in frame environments,
we have an incompatibility with the `\AtBeginSection` macro
which creates a special frame when a new section occurs.
(We can't have a frame inside another frame.)

This change disables `\AtBeginSection` inside bibliography
slides.

This supersedes #145.  See discussion tehre.
2015-10-29 10:10:42 -07:00
John MacFarlane 95201a0885 Revert "New approach to stack build on appveyor."
This reverts commit cdd6389e91.
2015-10-28 12:41:06 -07:00
John MacFarlane cdd6389e91 New approach to stack build on appveyor.
This uses system lua library.
See https://github.com/osa1/hslua/issues/22#issuecomment-151281274
2015-10-28 11:01:38 -07:00
John MacFarlane fb1843ecde Fixed omitted url(...) in CSS data-uri with --self-contained.
Fixes #2489.
2015-10-28 10:06:40 -07:00
John MacFarlane 1d53d452c3 LaTeX writer: add \protect to \hyperlink.
Thanks to Hadrien Mary for the problem and solution.

Closes #2490.
2015-10-28 09:37:05 -07:00
John MacFarlane 3b4d5d26a5 Change default for old-locale flag to False. 2015-10-27 23:26:02 -07:00
John MacFarlane d5efa9b35c LaTeX writer: Use \hypertarget and \hyperlink for links.
This works correctly to link to Div or Span elements.
We now don't bother defining `\label` for Div or Span
elements.

Closes jgm/pandoc-citeproc#174.
2015-10-27 14:08:35 -07:00
John MacFarlane 3ea444666a Markdown reader: improved parser for mmd_title_block.
We now allow blank metadata fields.  These were explicitly
disallowed before.

For background see #2026.  The issue in #2026 has since
been fixed in another way, so there is no need to forbid
blank metadata fields.
2015-10-26 22:06:34 -07:00
John MacFarlane 2c08913c78 Merge pull request #2484 from nickbart1980/patch-4
Added de-CH-1901, fixed el-polyton
2015-10-26 06:48:36 -07:00
nickbart1980 143093eabd Added de-CH-1901, fixed el-polyton
el-polyton, not el-poly, see http://www.iana.org/assignments/language-subtag-registry/language-subtag-registry
2015-10-26 10:34:32 +00:00
John MacFarlane 89d399b6b1 Merge pull request #2481 from mb21/textarabic
LaTeX writer: \textarabic fix
2015-10-25 12:42:41 -07:00
John MacFarlane 7d4f174047 Template improvements (Andrew Dunning).
- Added `keywords` to HTML templates and fixed alignment.
- Updated dzslides template from source.
- Added `lang`, `dir`, `quotes` to HTML templates;
  always make author and date display conditional.
- Fixed `author` and `date` in asciidoc; added `keywords`, `abstract`.
- Updated tests.
2015-10-25 12:28:28 -07:00
John MacFarlane de2e524e7d Merge pull request #144 from adunning/html-keywords
Add keywords to HTML templates; realign.
2015-10-25 12:18:14 -07:00
John MacFarlane 2d4df824cd Merge pull request #143 from adunning/patch-1
Update dzslides template from source.
2015-10-25 12:17:19 -07:00
John MacFarlane 219dea4059 Merge pull request #142 from adunning/asciidoc
Fix author, date in AsciiDoc; add keywords, abstract.
2015-10-25 12:16:32 -07:00
John MacFarlane 45df87cf15 Merge pull request #2477 from tarleb/org-toggling-header-args
Org reader: allow toggling header args
2015-10-25 12:10:07 -07:00
mb21 f3f6483510 LaTeX writer: \textarabic fix 2015-10-25 18:31:35 +01:00
Albert Krewinkel 27a8603278 Org reader: allow toggling header args
Org-mode allows to skip the argument of a code block header argument if
it's toggling a value.  Argument-less headers are now recognized,
avoiding weird parsing errors.

The fixes are not exactly pretty, but neither is the code that was
fixed.  So I guess it's about par for the course.  However, a rewrite of
the header parsing code wouldn't hurt in the long run.

Thanks to @jo-tham for filing the bug report.

This fixes #2269.
2015-10-25 08:54:00 +01:00
John MacFarlane f3e559c43c deb/Makefile: added 'clean'. 2015-10-24 22:58:59 -07:00
John MacFarlane c9693ae1f4 deb/Vagrantfile: share .., so we can put the deb there. 2015-10-24 22:57:16 -07:00
John MacFarlane 31e46c1cc1 Added Vagrantfile for building deb in vm.
This should help in automating binary package creation.

'make package' will make the package.
'make package COMMIT=blah' will make the package from commit blah.
2015-10-24 22:52:41 -07:00
John MacFarlane 34bcaed62a Fixed typo. 2015-10-24 22:18:13 -07:00
John MacFarlane ac1c0a9334 Fixed typo. 2015-10-24 22:12:58 -07:00
John MacFarlane a777c6e2ae Added Paths_pandoc to other-modules for executable stanza. 2015-10-24 22:11:46 -07:00
John MacFarlane 0914f7f713 make_deb: changed path for man page.
stack doesn't install it as cabal did.
2015-10-24 22:06:53 -07:00
John MacFarlane f8e58dea02 Improved fetching of pandoc-citeproc man page. 2015-10-24 22:00:44 -07:00
John MacFarlane 797ec7cb75 Moved PATH setting in make_deb, make_osx_package.
Otherwise 'which hsb2hs' won't find the local one.
2015-10-24 21:23:40 -07:00
John MacFarlane d7e6a95a3a Set paths in make_deb and make_osx_package.
This is needed to include a locally installed hsb2hs.
2015-10-24 21:22:24 -07:00
John MacFarlane d355163b7d Changed path . to .. in deb/osx stack.yaml. 2015-10-24 21:17:05 -07:00
John MacFarlane aafccdb0bd Changes for deb and osx package generators.
- Use stack for make_deb.sh.
- Use osx/stack.yaml or deb/stack.yaml.
- deb/stack.yaml doesn't want the same ghc-options.
2015-10-24 21:12:43 -07:00
John MacFarlane 68ca646e65 Added stack.hsb2hs.yaml, for easy installation of hsb2hs. 2015-10-24 16:59:05 -07:00
John MacFarlane 69178d5b0b make_osx_package: don't create man5. 2015-10-24 16:53:49 -07:00
John MacFarlane 8aa9e839c7 Merge pull request #2475 from tarleb/org-paragraph-before-list
Org reader: fix paragraph/list interaction
2015-10-24 15:18:42 -07:00
Albert Krewinkel b27366780f Org reader: fix paragraph/list interaction
Paragraphs can be followed by lists, even if there is no blank line
between the two blocks.  However, this should only be true if the
paragraph is not within a list, were the preceding block should be
parsed as a plain instead of paragraph (to allow for compact lists).

Thanks to @rgaiacs for bringing this up.

This fixes #2464.
2015-10-24 19:05:56 +02:00
Andrew Dunning 7c20cf11cf Note expanded support for abstract, keywords.
Based on <https://github.com/jgm/pandoc-templates/pull/144>, <https://github.com/jgm/pandoc-templates/pull/142>.
2015-10-23 09:03:53 -04:00