Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
|
|
This now contains the Verbosity definition previously
in Options, as well as a new LogMessage datatype that
will eventually be used instead of raw strings for
warnings.
This will enable us, among other things, to provide
machine-readable warnings if desired.
See #3392.
|
|
These were confusing.
Now we rely on the +raw_tex or +raw_html extension with latex
or html input.
Thus, instead of
--parse-raw -f latex
we use
-f latex+raw_tex
and instead of
--parse-raw -f html
we use
-f html+raw_html
|
|
Class:
* Removed getWarnings, withWarningsToStderr
* Added report
* Added logOutput to PandocMonad
* Make logOutput streaming in PandocIO monad
* Properly reverse getLog output
Readers:
* Replaced use of trace with report DEBUG.
TWiki Reader: Put everything inside PandocMonad m.
API changes.
|
|
API changes: Text.Pandoc.Options:
* Added Verbosity.
* Added writerVerbosity.
* Added readerVerbosity.
* Removed writerVerbose.
* Removed readerTrace.
pandoc CLI: The `--trace` option sets verbosity to DEBUG;
the `--quiet` option sets it to ERROR, and the `--verbose`
option sets it to INFO. The default is WARNING.
|
|
API change. CLI option change.
|
|
Since we've unified error types, we can just throw the same error at
the toplevel.
|
|
|
|
|
|
This was only necessary for GHC versions with base below 4.5
(i.e., ghc < 7.4).
|
|
They are meant to be interpreted as literal text in textile.
Closes #3042.
|
|
Closes #3036.
|
|
Also, remove trailing newline in code blocks (consistently
with Markdown reader).
|
|
- Allow multiple terms (which we concatenate with linebreaks).
- Fix exponential parsing bug (closes #3020 for real this time).
|
|
We now handle cell and row attributes, mostly by skipping
them. However, alignments are now handled properly.
Since in pandoc alignment is per-column, not per-cell, we
try to devine column alignments from cell alignments.
Table captions are also now parsed, and textile indicators
for thead and tfoot no longer cause parse failure. (However,
a row designated as tfoot will just be a regular row in pandoc.)
|
|
Closes #3020.
|
|
Spaces are not allowed in the image URL in textile.
Closes #2998.
|
|
Attributes can't be followed by a space.
So,
_(class)emph_
but
_(noclass) emph_
Closes #2984.
|
|
Closes #2674.
|
|
The reader previously did allow this, following redcloth,
which happily parses
Html blocks can be <div>inlined</div> as well.
as
<p>Html blocks can be <div>inlined</div> as well.</p>
This is invalid HTML, and this kind of thing can lead
to parsing problems (stack overflows) as well. So this
commit undoes this behavior. The above sample now produces;
<p>Html blocks can be</p>
<div>
<p>inlined</p>
</div>
<p>as well.</p>
|
|
and use it in Textile reader
|
|
closes #2515
|
|
We don't have a place yet for styles or sizes on images, but
we can skip the attributes rather than incorrectly taking them
to be part of the filename.
Closes #2515.
|
|
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.
|
|
This reverts commit c423dbb5a34c2d1195020e0f0ca3aae883d0749b.
|
|
This is needed for ghci to work with pandoc, given that we
now use a custom prelude.
Closes #2503.
|
|
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.
|
|
- 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.
|
|
|
|
|
|
|
|
* Handle newlines in cells.
* Handle empty cells.
* Closes #1919.
|
|
Closes #1513.
Lists can now start without an intervening blank line.
Also, html block-level tags that don't start a line are parsed
as RawInline and don't interrupt paragraphs, as in RedCloth.
|
|
|
|
This matches behavior of RedCarpet, avoids some ugly bugs, and improves
performance.
|
|
|
|
|
|
Textile reader hung on
pandoc -f textile http://johnmacfarlane.net/pandoc/demo/example25.textile
The reader no longer hangs.
|
|
This is possible because of the rewrite of simpleInline.
Also removed a redundant parser for grouped inlines.
|
|
This way we only look once for the opening `[`.
|
|
@hi
there@
should not be a single code span.
|
|
|
|
(It seems clearer to put the whitespace parsing in the grouped
parser. This also uses stateLastStrPos to determine when the
border is adjacent to an alphanumeric.)
|
|
In particular we now pick up on attributes. Since pandoc links
can't have attributes, we enclose the whole link in a span
if there are attributes.
Closes #1008.
|
|
Instead of being ignored, attributes are now parsed and
included in Span inlines.
The output will be a bit different from stock textile:
e.g. for `*(foo)hi*`, we'll get `<em><span class="foo">hi</span></em>`
instead of `<em class="foo">hi</em>`. But at least the data is
not lost.
|
|
Closes #1115.
|
|
|
|
element and updated files accordingly
|
|
The reader did not correctly parse inline markup. The behavoir is now as follows.
(a) The markup must start at the start of a line, be inside previous
inline markup or be preceeded by whitespace.
(b) The markup can not span across paragraphs (delimited by \n\n)
(c) The markup can not be followed by a alphanumeric character.
(d) Square brackets can be placed around the markup to avoid having
to have white space before it.
In order to make these changes it was either necessary to convert the parser to return a list of inlines or to convert the whole reader to use the builder. The latter approach whilst more work makes a bit more sense as it becomes easy to arbitarily append and prepend elements without changing the type.
Tests are accordingly updated in a later commit to reflect the different normalisation behavoir specified by the builder monoid.
|