aboutsummaryrefslogtreecommitdiff
path: root/data
AgeCommit message (Collapse)AuthorFilesLines
2017-12-29data/pandoc.lua: fix documentation for global_filterAlbert Krewinkel1-5/+5
2017-12-28Fixed some doc comments in data/pandoc.lua.John MacFarlane1-10/+10
2017-12-27data/sample.lua: use `next` instead of for loopAlbert Krewinkel1-4/+3
Each definition list item contains just a single key and the associated value. Using `next` to get the key/value pair is more idiomatic than iterating over the single-element table.
2017-12-27Removed extra comment.John MacFarlane1-1/+0
2017-12-27Revert "data/sample.lua: Fixed problem with definition lists."John MacFarlane1-3/+5
This reverts commit 0e3736422ee97a5cfedc255705f566a319f954f9 in favor of @tarleb's fix.
2017-12-27data/sample.lua: fixed problem with tables.John MacFarlane1-1/+1
Closes #4202.
2017-12-27data/sample.lua: Fixed problem with definition lists.John MacFarlane1-5/+3
2017-12-26Updated reference.docx.John MacFarlane10-38/+415
Instead of just "Hello, world", the document now contains exemplars of most of the styles that have an effect on pandoc documents. This makes it easier to see the effect of style changes. Closes #4175.
2017-12-26HTML writer: Use br elements in line blocks...John MacFarlane9-9/+0
instead of relying on CSS. Closes #4162. HTML-based templates have had the custom CSS for div.line-block removed. Those maintaining custom templates will want to remove this too. We still enclose line blocks in a div with class line-block.
2017-12-23data/init.lua: load pandoc.utils by defaultAlbert Krewinkel1-0/+1
2017-12-21Lua modules: added pandoc.utils moduleAlbert Krewinkel1-0/+5
A new module `pandoc.utils` has been created. It holds utility functions like `sha1`, which was moved from the main `pandoc` module.
2017-12-21Removed default.theme data file.John MacFarlane1-177/+0
It is no longer needed now that we have `--print-highlight-style`. See #4096.
2017-12-20Lua modules: turn pipe, read into full Haskell functionsAlbert Krewinkel1-47/+0
The `pipe` and `read` utility functions are converted from hybrid lua/haskell functions into full Haskell functions. This avoids the need for intermediate `_pipe`/`_read` helper functions, which have dropped.
2017-12-19pandoc.lua: re-add missing MetaMap functionAlbert Krewinkel1-1/+4
This was a bug introduced in version 2.0.4 (commit 3f1f9536d4817bbdd797c01050a887fe4cdf347c).
2017-12-13Update latex template to work with recent versions of beamer.John MacFarlane1-6/+18
The old template produced numbered sections with some recent versions of beamer. Thanks to Thomas Hodgson.
2017-12-11Added support for LaTeX pagestyle variable (#4135)Thomas Hodgson1-0/+3
* Add pagestyle support * Add pagestyle option to MANUAL.txt * Moved mention of pagestyle to the section on variables
2017-12-11Add default pptx data for Powerpoint writer.Jesse Rosenthal39-0/+76
2017-12-06Lua filters: use script to initialize the interpreterAlbert Krewinkel1-0/+6
The file `init.lua` is used to initialize the Lua interpreter which is used in Lua filters. This gives users the option to require libraries which they want to use in all of their filters, and to extend default modules.
2017-12-02Lua filters: refactor lua module handlingAlbert Krewinkel2-1/+1
The integration with Lua's package/module system is improved: A pandoc-specific package searcher is prepended to the searchers in `package.searchers`. The modules `pandoc` and `pandoc.mediabag` can now be loaded via `require`.
2017-12-04reveal.js template: add title-slide identifier to title slide.John MacFarlane1-1/+1
This allows it to be styled more easily. Closes #4120.
2017-12-03Include default CSS for 'underline' class in HTML-based templates.John MacFarlane9-0/+9
2017-12-01revealjs template: added a necessary escape.John MacFarlane1-1/+1
2017-12-01reveal.js template: include tex2jax configuration.John MacFarlane1-0/+12
This ensures that we don't use $..$ delimiters, which gives bad results when $ is used as a currency sign. This depends on the current dev version of reveal.js.
2017-12-01pandoc.lua: set metatable on List MetaValuesAlbert Krewinkel1-10/+10
The `List` metatable is assigned to the tables which get passed to the constructors `MetaBlocks`, `MetaInline`, and `MetaList`. This enables the use of the resulting objects as lists. This is part of the changes discussed in #4081.
2017-12-01Lua/StackInstances: push Pandoc and Meta via constructorAlbert Krewinkel1-0/+15
Pandoc and Meta elements are now pushed by calling the respective constructor functions of the pandoc Lua module. This makes serialization consistent with the way blocks and inlines are pushed to lua and allows to use List methods with the `blocks` value.
2017-12-01List.lua: add missing fixes as discussed in #4099Albert Krewinkel2-23/+34
The changes were missing due to an error while using git.
2017-11-29List.lua: add _VERSION to module, drop unused varAlbert Krewinkel1-4/+3
2017-11-28Add basic lua List module (#4099)Albert Krewinkel2-41/+149
The List module is automatically loaded, but not assigned to a global variable. It can be included in filters by calling `List = require 'List'`. Lists of blocks, lists of inlines, and lists of classes are now given `List` as a metatable, making working with them more convenient. E.g., it is now possible to concatenate lists of inlines using Lua's concatenation operator `..` (requires at least one of the operants to have `List` as a metatable): function Emph (emph) local s = {pandoc.Space(), pandoc.Str 'emphasized'} return pandoc.Span(emph.content .. s) end Closes: #4081
2017-11-20data/pandoc.lua: enable table-like behavior of attributes (#4080)Albert Krewinkel1-1/+92
Attribute lists are represented as associative lists in Lua. Pure associative lists are awkward to work with. A metatable is attached to attribute lists, allowing to access and use the associative list as if the attributes were stored in as normal key-value pair in table. Note that this changes the way `pairs` works on attribute lists. Instead of producing integer keys and two-element tables, the resulting iterator function now returns the key and value of those pairs. Use `ipairs` to get the old behavior. Warning: the new iteration mechanism only works if pandoc has been compiled with Lua 5.2 or later (current default: 5.3). The `pandoc.Attr` function is altered to allow passing attributes as key-values in a normal table. This is more convenient than having to construct the associative list which is used internally. Closes #4071
2017-11-14LaTeX template: include natbib/biblatex after polyglossia.John MacFarlane1-10/+10
Otherwise we seem to get an error; biblatex wants polyglossia language to be defined. Closes #4073.
2017-11-11Fixed URIs in jats.csl.John MacFarlane1-4/+1
They were being rendered twice, leading to invalid XML.
2017-11-09Removed etc. from abbreviations file.John MacFarlane1-1/+0
Reason: often etc. ends a sentence, and we want the . to be treated as a sentence-ending period.
2017-11-03Added a few abbreviations and sorted the list. (#3984)Wandmalfarbe1-19/+42
2017-11-02Improved support for columns in HTML.John MacFarlane9-24/+27
* Move as much as possible to the CSS in the template. * Ensure that all the HTML-based templates (including epub) contain the CSS for columns. * Columns default to 50% width unless they are given a width attribute. Closes #4028.
2017-10-31HTML Writer: consistently use dashed class-namesmb212-2/+2
see #3556
2017-10-25pandoc.lua: define default list attributesAlbert Krewinkel1-1/+2
The second argument of the OrderedList constructor, which should define the list's attributes, is made optional. Default attributes are used if the parameter is omitted.
2017-10-17pandoc.lua: destructure attr for Link and ImageAlbert Krewinkel1-2/+2
Make Attr values accessible through through the keys `identifier`, `classes` and `attributes`. This is already used in other elements with attributes and is now fixed for Link and Image.
2017-10-05pandoc.lua: throw better error when pipe command failsAlbert Krewinkel1-3/+3
A table containing the error code, command, and command output is thrown instead of just a string error message.
2017-10-03Merge pull request #3951 from greut/patch-1John MacFarlane1-1/+1
Load Google Font using HTTPS by default
2017-10-03pandoc.lua: use wrapper funciton for pipe commandAlbert Krewinkel1-0/+23
The pipe command is wrapped in a lua function, throwing a lua error if the command returns with an error. A wrapper is needed as Haskell functions exposed to lua may not throw lua errors due to limitations of hslua. The error handling is written such that a table can be returned as an error object in the future. This is potentially useful when finer control is required while catching the error in lua code. Current limitations of hslua require error objects to be strings.
2017-10-03Load Google Font using HTTPS by defaultYoan Blanc1-1/+1
Otherwise they won't show up in current version of firefox/chromium.
2017-10-03Lua.PandocModule: promote addFunction to top levelAlbert Krewinkel1-1/+1
This reduces some boilerplate.
2017-09-12Move 'tables in footnotes' fix out of beamer part of default.latex.John MacFarlane1-2/+3
This caused an error in beamer. Footnotes already work in tables in beamer, without this code.
2017-09-11Support for PDF generation via `weasyprint` and `prince` (#3909)Mauro Bieg1-2/+2
* Rename --latex-engine to --pdf-engine * In `Text.Pandoc.Options.WriterOptions`, rename `writerLaTeXEngine` to `writerPdfEngine` and `writerLaTeXArgs` to `writerPdfArgs`. * Add support for `weasyprint` and `prince`, in addition to `wkhtmltopdf`, for PDF generation via HTML (closes #3906). * `Text.Pandoc.PDF.html2pdf`: use stdin instead of intermediate HTML file
2017-09-08Write euro symbol directly in LaTeXAndrew Dunning1-6/+1
The textcomp package allows pdfLaTeX to parse `€` directly, making the \euro command unneeded. Closes #3801.
2017-09-08Removed old beamer template.John MacFarlane1-285/+0
We now use the default.latex template for both latex and beamer. It contains conditionals for the beamer-specific things. `pandoc -D beamer` will return this template.
2017-09-08Use starred versions of xcolor namesAndrew Dunning1-1/+1
Prevents changes to documents defined using the dvipsnames list (e.g. `Blue` gives a different result with svgnames enabled).
2017-09-08Merge branch 'master' into patch-1Andrew Dunning2-11/+11
2017-09-07LaTeX template: load polyglossia after header-includes.John MacFarlane1-9/+9
It needs to be loaded as late as possible. Closes #3898.
2017-09-07Merge pull request #3885 from tarleb/lua-module-docsJohn MacFarlane1-2/+2
Lua module documentation