John MacFarlane
de5102a22c
Error: Changed PandocFileReadError to PandocIOError
2017-02-23 16:21:49 +01:00
John MacFarlane
4a9069130f
Shared.openURL: Changed type from an Either.
...
Now it will just raise an exception to be trapped later.
2017-02-23 16:21:03 +01:00
John MacFarlane
2d964dd4ee
PDF: make sure that verbosity is respected when we fetch items.
2017-02-23 15:06:49 +01:00
John MacFarlane
2bbf98a613
Put makeSelfContained in PandocMonad instead of IO.
...
This removes the need to pass MediaBag around and improves
exceptions. It also opens up the possibility of using
makeSelfContained purely.
2017-02-23 15:06:25 +01:00
John MacFarlane
86d8e1ef89
Pretty: simplified definition of realLength.
2017-02-23 09:54:31 +01:00
John MacFarlane
9614835ea7
Added emf to mimeTypes with type application/x-msmetafile.
...
See #1713 .
2017-02-22 21:20:40 +01:00
John MacFarlane
f4a452f891
When parsing raw LaTeX commands, include trailing space.
...
Otherwise things like `\noindent foo` break and turn into
`\noindentfoo`.
Affects `-f latex+raw_tex` and `-f markdown` (and other formats
that allow `raw_tex`).
Closes #1773 .
2017-02-22 21:15:25 +01:00
mb21
3f6b50e525
imageSize interface change
...
`imageSize img` is now `imageSize opts img`
2017-02-22 15:34:53 +01:00
mb21
b312ac6d2d
make imageSize recognize basic SVG dimensions, see #3462
2017-02-22 15:34:53 +01:00
John MacFarlane
5d71e37f26
MediaWiki reader: ensure that list starts begin at left margin.
...
Including when they're in tables or other list items.
Closes #2606 .
2017-02-21 23:41:32 +01:00
John MacFarlane
f90b82d3d9
MediaWiki writer: Remove newline before </ref>
.
...
Closes #2652 .
2017-02-21 23:03:10 +01:00
John MacFarlane
e462f80d74
MediaWiki writer: add display attribute on <math>
tags.
...
This allows display math to be rendered properly.
Closes #3452 .
2017-02-21 22:57:48 +01:00
John MacFarlane
5269724ad3
MediaWiki reader: fixed more table issues.
...
Closes #2649 .
2017-02-21 21:28:24 +01:00
John MacFarlane
1d06e8c5a5
MediaWiki reader: Allow blank line after table start.
...
See #2649 .
2017-02-21 18:34:21 +01:00
John MacFarlane
598ffa3a94
MediaWiki tables: allow extra hyphens after |-
in tables.
...
I didn't see this documented anywhere, but it seems to be allowed
(and common).
See #2649 . This addresses some of the cases there, but not all.
2017-02-21 17:30:13 +01:00
John MacFarlane
7af3d90ae1
MediaWiki writer: Updated list of syntax highlighting languages.
...
Now 'r' gets you `<source>` rather than `<code>` (among others).
Closes #3461 .
2017-02-21 17:13:59 +01:00
John MacFarlane
612f1238aa
Use lazy loading for reveal.js slide shows.
...
* In HTML writer, with reveal.js we use data-src instead of src
for images.
* In SelfContained, we also load resources from data-src.
Closes #2283 .
2017-02-20 22:21:20 +01:00
John MacFarlane
172320ac66
Added Functor constraint to keep ghc 7.8.4 happy.
2017-02-20 16:34:33 +01:00
John MacFarlane
547c32939b
Tighten up HasQuoteContext instance in HTML reader.
...
We constrain it to the state used in the HTML reader.
Otherwise we can get overlap with the general instance
for ParserState m.
2017-02-20 15:51:49 +01:00
John MacFarlane
b246e8e9af
Revert "Refined constraint for HasQuoteContext instance."
...
This reverts commit 3c427fc17d
.
2017-02-20 15:44:33 +01:00
John MacFarlane
3c427fc17d
Refined constraint for HasQuoteContext instance.
...
in hopes that this will help the ghc 7.8.4 build...
2017-02-20 15:25:47 +01:00
John MacFarlane
3ccf3fad2c
Removed redundant constraint.
2017-02-20 15:12:20 +01:00
John MacFarlane
3165e14b17
Error: added PandocMakePDFError
2017-02-19 09:53:24 +01:00
John MacFarlane
3c3138b133
Added warnings for non-rendered blocks to some writers.
2017-02-17 23:11:31 +01:00
John MacFarlane
aee10a719b
FB2 writer: don't render RawBlock as code.
2017-02-17 21:41:47 +01:00
John MacFarlane
1e43e3767e
Markdown reader: Use logMessage instead of report.
2017-02-17 19:59:54 +01:00
John MacFarlane
a3412354a4
Fixed repeated log messages in RST reader.
...
See #3447 . To complete fixes on this issue, we need to
do the same for the other readers. Note that the changes
required are minimal -- add reportLogMessages to the end
of the main parser, and replace report with logMessage.
(except for trace)
2017-02-17 13:01:55 +01:00
John MacFarlane
38daf9de68
Parsing: Added HasLogMessages, logMessage, reportLogMessages.
...
We need to do logging by updating parser state, or we'll get
inappropriate and repeated log messages when there is parser
backtracking.
See #3447 .
2017-02-17 12:56:07 +01:00
John MacFarlane
575014975e
Fix indirect hyperlink targets. Closes #512 .
2017-02-15 17:36:16 +01:00
John MacFarlane
ebe4072bd9
Add CircularReference constructor to LogMessage.
2017-02-15 17:35:29 +01:00
Alex Ivkin
93f0a9c2e5
ZimWiki writer: removed internal formatting from note and table cells, because ZimWiki does not support it ( #3446 )
2017-02-15 11:28:02 +01:00
John MacFarlane
c44a3f61c2
LaTeX reader: include contents of \parbox
.
2017-02-14 23:12:46 +01:00
Alexander Krotov
a58112f6bc
Simplify toRomanNumeral using guards ( #3445 )
2017-02-14 23:00:23 +01:00
John MacFarlane
2a3c2b01ea
Removed unnecessary import.
2017-02-14 15:02:59 +01:00
John MacFarlane
cfdbe85e71
LaTeX reader: properly handle column prefixes/suffixes.
...
For example, in
\begin{tabular}{>{$}l<{$}>{$}l<{$} >{$}l<{$}}
each cell will be interpreted as if it has a `$`
before its content and a `$` after (math mode).
2017-02-13 22:39:59 +01:00
Alexander Krotov
9e3f5a5147
Do not strip # from Org anchor links
...
Links with # are perfectly valid according to http://orgmode.org/manual/Internal-links.html#Internal-links
2017-02-12 17:09:44 +03:00
John MacFarlane
48c78713c8
Rename logMessagesToJSON -> encodeLogMessages.
2017-02-11 22:58:22 +01:00
John MacFarlane
cf26bc5f68
RST reader: Support .. line-block
directive.
...
This is deprecated but may still be in older documents.
2017-02-11 22:47:05 +01:00
John MacFarlane
2759960204
RST reader/writer: properly handle table captions.
...
Currently the support for the `.. table` directive is a bit
limited; we don't yet support the `widths` field. But at least
you can have a proper captioned table.
2017-02-11 22:37:07 +01:00
John MacFarlane
510a6ee059
RST reader: Initial support of .. table directive.
...
This allows adding captions to tables.
2017-02-11 22:21:49 +01:00
John MacFarlane
1a23bc65b8
Fixed small bug in RST list parsing.
...
See #3432 . Previously the parser didn't handle properly this
case:
* - a
- b
* - c
- d
2017-02-11 20:55:13 +01:00
John MacFarlane
92a5445aa1
Logging: export logMessagesToJSON.
...
Use a deterministic order for fields.
2017-02-11 20:13:33 +01:00
John MacFarlane
a6c649cfc8
Added --log option to save log messages in JSON format to a file.
...
See #3392 .
2017-02-11 09:59:54 +01:00
John MacFarlane
e0d21dbb82
Class.report: Save all log messages in state.
...
Verbosity level only affects which are printed to stdout.
(Exception: DEBUG messages are only printed, never saved to
state.)
2017-02-11 09:06:49 +01:00
John MacFarlane
31f5c02743
HTML writer: report when not rendering raw inline/block.
2017-02-11 00:20:45 +01:00
John MacFarlane
76c55466d3
Use new warnings throughout the code base.
2017-02-11 00:14:44 +01:00
John MacFarlane
8ad7e2c21f
Logging: added ToJSON instance and showLogMessage.
...
This gives us the possibility of both machine-readable
and human-readable output for log messages.
See #3392 .
2017-02-10 22:06:07 +01:00
John MacFarlane
5e1249481b
Added Text.Pandoc.Logging (exported module).
...
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 .
2017-02-10 20:59:54 +01:00
John MacFarlane
c76eec97d4
LaTeX reader: Improved messages for skipped environments.
2017-02-10 10:00:23 +01:00
John MacFarlane
29b1ed0b84
LaTeX reader: Improved warning messages for unknown commands.
2017-02-10 08:36:04 +01:00