Commit graph

970 commits

Author SHA1 Message Date
John MacFarlane
9a46d75506 Implemented --citation-abbreviations option.
Mostly due to Andrea Rossato.
2011-11-11 17:54:34 -08:00
John MacFarlane
d74e8d14a5 Markdown citations: don't strip off initial space in locator.
Previously `[@item1 and nowhere else]` yielded the locator ", and nowhere
else", or, with the new citeproc-hs, "and nowhere else".
Now it yields " and nowhere else".
2011-11-09 13:18:01 -08:00
John MacFarlane
c2f7ba3b69 TeXMath writer: Use unicode thin spaces for thin spaces.
Partially resolves issue #333.
2011-11-08 18:22:28 -08:00
John MacFarlane
4f95aeb6d2 HTML writer: Use <section> for footnotes if html5. 2011-11-07 12:23:05 -08:00
John MacFarlane
05fa195bf7 Biblio: Fixed mess created by my removing procInlines.
Now I see that procInlines was needed to prevent bottomUp
from acting on sublists.

This should fix the problem where '@item1, @item1' yielded
"Doe (1999), Doe Doe Doe Doe (1999)".
2011-11-07 11:32:08 -08:00
John MacFarlane
1af2ebce43 Biblio - fixed author-in-text citations so they don't double. 2011-11-07 11:03:33 -08:00
John MacFarlane
e95e6f3664 Biblio - Removed redundancy. 2011-11-07 10:31:25 -08:00
John MacFarlane
ca98cd8f18 Biblio: Put whole author-in-text citation in a Cite.
Previously just the date and other info went in the Cite.
2011-11-06 17:28:39 -08:00
John MacFarlane
ca5f4434c2 Further simplification of Biblio. 2011-11-06 16:48:16 -08:00
John MacFarlane
380fa06720 Further cleanup of Biblio. 2011-11-06 16:37:50 -08:00
John MacFarlane
3bf1984df6 Simplified Biblio, removed procInlines, use generics instead. 2011-11-06 16:16:06 -08:00
John MacFarlane
dd6ed88707 Markdown reader: allow punctuation only internally in cite keys.
The characters '.',':',';','$','<','>','~','#','-','_' can
be used only between two letters or digits in a citation key.

This means that '@item1.' will be parsed as a citation, 'item1',
followed by a period, instead of a citation 'item1.', as was the
case previously.

Thanks to David Sanson for alerting us to the problem.
2011-11-06 16:00:23 -08:00
John MacFarlane
e8bfabeeeb Don't add comma+space to prefix if it ends in punctuation.
Patch from Andrea Rossato.
2011-11-04 17:38:18 -07:00
John MacFarlane
f4dbd85347 Text.Pandoc.Biblio: Expand citations recursively inside nested inlines.
Closes #331.
2011-10-28 13:18:58 -07:00
John MacFarlane
565113fb6b Biblio: Treat \160 as space when parsing locator and suffix.
This fixes a bug with "p. 33" when `--smart` is used. Previously
the whole "p. 33" would be included in the suffix, with no locator.
2011-10-27 13:58:10 -07:00
John MacFarlane
40cb070fe6 Don't generate superfluous file cover-image.jpg.
Closes #319.
2011-10-27 12:53:46 -07:00
John MacFarlane
1a1f6cb08b Added TOC identifier in EPUB page template.
Closes #329.
2011-10-27 12:00:34 -07:00
John MacFarlane
1b81981c5f HTML reader now recognizes DocBook block and inline tags.
It was always possible to include raw DocBook tags in a markdown
document, but now pandoc will be able to distinguish block from
inline tags and behave accordingly. Thus, for example,

    <sidebar>
    hello
    </sidebar>

will not be wrapped in `<para>` tags.
2011-10-25 12:44:20 -07:00
John MacFarlane
c335b6cbd8 HTML slides: only add id to div/section if --section-divs selected. 2011-10-02 23:19:03 -07:00
John MacFarlane
072df3f5dd Simplified slide creation in HTML writer.
A horizontal rule now gets transformed into an empty H1 header
before 'hierarchicalize' is called.

If the document that does not begin with an H1 header, an
empty one is provided.

This avoids the need for kludgy raw HTML.

Also, the 'titleslide' class is added to any section containing
just a title:

----

----
2011-10-02 11:49:56 -07:00
John MacFarlane
9b37c9cc35 Added dzslides output option.
* Added DZSlides to HTMLSlideVariant.
* Added support for dzslides in HTML writer.
* Added dzslides template.
2011-10-01 23:02:24 -07:00
John MacFarlane
44bcb5da51 LaTeX writer: don't escape # or ~ inside href{...}.
Closes #309.
2011-10-01 22:21:39 -07:00
John MacFarlane
f8df0f50fd Added escaping of euro character to LaTeX writer.
Partially resolves #309.
2011-09-23 14:58:16 -07:00
John MacFarlane
e3c560ac3d RST writer: Fixed bug involving empty table cells.
isSimple was being calculated in a way that assumed there
were no non-empty cells.

Resolves #299. Thanks to rmunoz for reporting the bug.
2011-09-05 19:13:30 -07:00
takahashim
724de8314c allow footnotes followed by newline without space chars 2011-08-23 09:56:58 +09:00
John MacFarlane
24095e0615 ConTeXt writer: Changed 'descr' to 'description', fixed alignment. 2011-08-20 15:30:57 -07:00
John MacFarlane
fa03bf52cb ConTeXt: Use buffering for footnotes containing code blocks.
Closes #291.
2011-08-18 19:23:34 -07:00
John MacFarlane
f9ae93d854 ConTeXt: Escape # in link URLs.
Partially addresses #291.
2011-08-18 12:16:39 -07:00
John MacFarlane
f2fb733e0d Templates: Return empty string for json template.
Thanks to Dirk Laurie for pointing out the bug.
2011-08-18 10:49:19 -07:00
John MacFarlane
6c639d3420 HTML reader: Fixed bug parsing tables w both thead and tbody.
See bug #274, which was not completely fixed by the last patch.
2011-08-01 11:56:15 -07:00
John MacFarlane
8be6cc210c Added PRAGMA needed for ghc 6.12. 2011-07-30 19:58:46 -07:00
John MacFarlane
81381a9305 Removed applicative stuff in Markdown reader.
It requires parsec 3, and currently pandoc can build with parsec 2.
2011-07-30 19:43:20 -07:00
John MacFarlane
b66b7a791c Markdown reader: Improved emph/strong parsing.
Ported code from pandoc2.
Now all tests pass.
2011-07-30 18:08:49 -07:00
John MacFarlane
2d14c9b436 Added nonspaceChar to Text.Pandoc.Parsing. 2011-07-30 18:08:02 -07:00
John MacFarlane
45b8520af8 Fix template problem for epub. 2011-07-28 18:53:59 -07:00
John MacFarlane
57821e1cdf Added s5-url and slidy-url variables, instead of hard-coding.
If you want to put your slidy files in the slidy subdirectory,
for example, you can do

    pandoc -t slidy -V slidy-url=slidy -s
2011-07-28 17:35:26 -07:00
John MacFarlane
0f0c1579f8 Smart quotes: handle '...hi' properly.
Also added test case.
2011-07-25 23:49:45 -07:00
John MacFarlane
a3327835be Docbook writer: Use programlisting for code blocks.
Instead of screen, as before.
2011-07-24 23:36:30 -07:00
John MacFarlane
07c7cd1945 Docbook writer: Use CALS tables (instead of XHTML tables).
Reason:  Some older docbook software does not work with XHTML
tables.

Closes #77.
2011-07-24 23:24:03 -07:00
John MacFarlane
3162adbd9b HTML writer: Removed English title on footnote back links.
This is incongruous in non-English documents.
2011-07-24 16:24:27 -07:00
John MacFarlane
7b4c1b171c Use data: protocol to embed s5 css in <link> tags.
Using inline css didn't work properly with Chrome and Safari.
2011-07-24 11:36:54 -07:00
John MacFarlane
d6df566a75 Reordered offline slidy includes. 2011-07-24 10:39:46 -07:00
John MacFarlane
d5e0c449bd Use yuicompressor-packed js for s5.
Removed s5/default/slides.js.comment,
s5/default/slides.js.packed. Added s5/default/slides.min.js.
2011-07-24 09:27:08 -07:00
John MacFarlane
c872d9f7ef Insert CDATA around inline js/css in HTML, slidy. 2011-07-24 08:23:38 -07:00
John MacFarlane
835dc412d2 Enclose s5 scripts and css in CDATA tags. 2011-07-24 07:52:44 -07:00
John MacFarlane
35cef01659 RST reader: Partial support for labeled footnotes.
Also made simpleReferenceName parser more accurate, which
affects several other parsers.
2011-07-23 18:51:02 -07:00
John MacFarlane
81c403d2d1 Use \enquote{..} for latex quotes if template uses csquotes package.
This provides better support for foreign language quoting.
Thanks to Andreas Wagner for the idea.
2011-07-23 13:12:11 -07:00
John MacFarlane
6424e7d02c Properly handle characters in the 128..159 range.
These aren't valid in HTML, but many HTML files produced by
Windows tools contain them.  We substitute correct unicode
characters.
2011-07-23 12:43:01 -07:00
John MacFarlane
26418b7d14 HTML writer/templates: Made TOC more customizable.
The container for the TOC is now in the template, so users
can insert a header or other styling. Thanks to Bruce D'Arcus
for the suggestion.
2011-07-23 12:04:31 -07:00
John MacFarlane
48368061a1 LaTeX writer: don't set stVerbInNote unnecessarily. 2011-07-23 08:36:41 -07:00