Age | Commit message (Collapse) | Author | Files | Lines |
|
Writer helper functions were defined in the top-level Text.Pandoc
module. These functions are moved to the Writer submodule as to enable
reuse in other submodules.
|
|
Reader helper functions were defined in the top-level Text.Pandoc
module. These functions are moved to the Readers submodule as to enable
reuse in other submodules.
|
|
Extension parsing and processing functions were defined in the top-level
Text.Pandoc module. These functions are moved to the Extensions
submodule as to enable reuse in other submodules.
|
|
|
|
Meta elements that are treated as lua tables (i.e. MetaList,
MetaInlines, MetaBlocks, and MetaMap), are no longer wrapped in an
additional table but simply marked via a metatable. This allows
treating those meta values just like normal tables, while still making
empty elements of those values distinguishable.
|
|
|
|
Avoid constructing list of one element ([B.str url]) just to flatten it
back with mconcat.
|
|
|
|
We now issue `<div class="line-block">` and include a
default definition for `line-block` in the default
templates, instead of hard-coding a `style` on the
div.
Closes #1623.
|
|
LaTeX requires something before a line break, so we insert a
`~` if no printable content has yet been emitted.
Closes #2874.
|
|
A figure with two subfigures turns into two pandoc
figures; the subcaptions are used and the main caption
ignored, unless there are no subcaptions.
Closes #3577.
|
|
|
|
The reader now correctly parses src block parameter list even if
parameter arguments contain multiple words.
Closes: #3477
|
|
Source block parameter names are no longer prefixed with *rundoc*. This
was intended to simplify working with the rundoc project, a babel
runner. However, the rundoc project is unmaintained, and adding those
markers is not the reader's job anyway.
The original language that is specified for a source element is now
retained as the `data-org-language` attribute and only added if it
differs from the translated language.
|
|
The line-numbering switch that can be given to source blocks (`-n` with
an start number as an optional parameter) is parsed and translated to a
class/key-value combination used by highlighting and other readers and
writers.
|
|
Previously we always added an empty div before the list
item, but this created problems with spacing in tight
lists. Now we do this:
If the list item contents begin with a Plain block,
we modify the Plain block by adding a Span around
its contents.
Otherwise, we add a Div around the contents of the
list item (instead of adding an empty Div to the
beginning, as before).
Closes #3596.
|
|
For example:
```latex
\SI[round-precision=2]{1}{m} is equal to \SI{1000}{mm}.
\SI[round-precision=2]{1}[\$]{} is equal to \SI{0.938094}{\euro}
```
|
|
The return-type parameter for lua filter functions is removed. It only
complicated the code without introducing any additional type safety.
|
|
Closes: #3577
|
|
|
|
Closes: #3576
|
|
We want to provide an interface familiar to users of other filtering
libraries.
|
|
Closes #3548.
|
|
This avoids parsing bare URIs that start with a scheme
+ colon + `*`, `_`, or `]`.
Closes #3570.
|
|
Use this instead of PandocAppError when appropriate.
Removed exit code from PandocAppError, use 1 for all.
|
|
|
|
No longer necessary with pandoc 2.0 framework.
|
|
|
|
|
|
|
|
- PandocSyntaxMapError String
- PandocFailOnWarningError
- PandocPDFProgramNotFoundError String
|
|
|
|
Element attributes are pushed to the stack via the `Attributes`
function. `Attributes` creates an Attr like triple, but the triple also
allows table-like access to key-value pairs.
|
|
Allow to use functions named `SingleQuoted`, `DoubleQuoted`,
`DisplayMath`, and `InlineMath` in filters.
|
|
|
|
Lua string are used to represent nullary data constructors. The previous
table-based representation was based on the JSON serialization, but can
be simplified. This also matches the way those arguments are passed to
custom writers.
|
|
The lua filters and custom lua writer system defined very similar
StackValue instances for strings and tuples. These instance definitions
are extracted to a separate module to enable sharing.
|
|
|
|
Native lua booleans and strings are used to represent MetaBool and
MetaString values. This is more natural than the previous table-based
representation. The old lua representation can still be read back to
haskell, ensuring compatibility with the `pandoc.MetaBool` and
`pandoc.MetaString` lua constructors.
|
|
Filtering functions take element components as arguments instead of the
whole block elements. This resembles the way elements are handled in
custom writers.
|
|
Pushing values to the lua stack via custom functions is faster and more
flexible.
|
|
All element creation tasks are handled by lua functions defined in the
pandoc module.
|
|
All element creation tasks are handled in the lua module.
|
|
|
|
Instead of taking the whole inline element, forcing users to destructure it
themselves, the components of the elements are passed to the filtering
functions.
|
|
|
|
Previously pandoc emitted incorrect markup for bold + italic, for example,
or bold + code.
Closes #3568.
|
|
Inline elements are no longer pushed and pulled via aeson's Value.
|
|
The docx writer takes components from the distribution's
version of reference.docx when it can't find them in a
user's custom reference.docx. (This sometimes happens
because Word will sometimes omit components needed for larger
documents when saving a simple one.)
Previously, we allowed a reference.docx in the data directory
(e.g. `~/.pandoc`) to be used as the distribution's reference.docx.
This led to a bizarre situation where pandoc would produce a
good docx using `--template ~/.pandoc/ref.docx`, but if `ref.docx`
were moved to `~/.pandoc/reference.docx`, it would then produce
a corrupted docx.
Closes #3322 (I think).
|
|
Pandoc elements are pushed and pulled from the lua stack via custom
instances.
|