Age | Commit message (Collapse) | Author | Files | Lines |
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@810 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ -m|--asciimathml option now takes an *optional* argument,
the URL to an asciiMathML.js script. This is much better
in situations where multiple files with math must be served,
as the script can be cached.
+ If the argument is provided, a link is inserted; otherwise,
the whole script is inserted as before.
+ Nothing is inserted unless there is inline LaTeX.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@799 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
introduced by the revision in the WriterState type).
git-svn-id: https://pandoc.googlecode.com/svn/trunk@793 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
easy extensibility.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@769 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
is actually used in the document.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@768 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
strikeout to all writers. (Thanks to Bradley Kuhn
for the patches for strikeout, here slightly modified.)
+ Refactored character escaping using the new functions
escapeStringUsing and backslashEscapes.
+ Added state to LaTeX writer, which now keeps track of what
packages need to be included in the preamble, based on the
content of the document. (Thus, e.g., ulem is only required
if you use strikeout.)
git-svn-id: https://pandoc.googlecode.com/svn/trunk@755 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
backlink on a line by itself, after the content of the note,
we now put it at the end of the last paragraph of the footnote.
This saves space and looks better. More specifically:
+ If the last block of the note is a Para or Plain block, the
backlink is put at the end of that block's contents.
+ Otherwise, the backlink is put in a separate Plain block by
itself, after the footnote's contents.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@697 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
to Text.Pandoc.Shared.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@656 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
- punctuation is now all removed (except -)
- spaces are turned into -
- all lowercase
This scheme should be fairly predictable.
Updated tests accordingly.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@655 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ change in scheme for construction of unique identifiers for headers:
- all lowercase
- spaces turn into -, not _
+ TOC items now have their own identifiers, starting with TOC-
+ when there is a TOC, headers link back to the corresponding TOC items,
rather than the top of the TOC.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@653 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
identifiers. The numbers used after duplicate identifiers
are now separated from them by a hyphen: Duplicate-1
rather than Duplicate1.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@648 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
real email address instead of lamely attempting
to obfuscate.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@640 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@635 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ Added code to HTML Writer to generate a table of contents if the
writerTableOfContents option is specified. This is an unordered list
with links to the headers. It is constructed hierarchically, based on
the order of the headers and their levels.
+ If a TOC is used, the headers become links back to the TOC.
+ Removed Toc from WriterState; instead, the TOC is generated at the top
level, by the function tableOfContents.
+ Fixed a bug in uniqueIdentifiers which prevented it from handling more than
one duplicate.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@634 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
headers and table of contents:
+ WriterState now includes a list of header identifiers and a table
of contents in addition to notes.
+ The function uniqueIdentifiers creates a list of unique identifiers
from a list of inline lists (e.g. headers).
+ This list is part of WriterState and gets consumed by blockToHtml
each time a header is encountered.
+ Headers are now printed with unique identifiers based on their names,
e.g. Shell_scripts for "# Shell scripts". Fancy stuff like links,
italics, etc. gets ignored. A numerical index is added to the end if
there is already an identifier by the same name, e.g. "Shell_scripts1".
+ Provision has been made for a table-of-contents block element, but this
has not yet been added.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@630 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
structure. Key and Note blocks have been removed. Link and image URLs
are now stored directly in Link and Image inlines, and note blocks
are stored in Note inlines. This requires changes in both parsers
and writers. Markdown and RST parsers need to extract data from key
and note blocks and insert them into the relevant inline elements.
Other parsers can be simplified, since there is no longer any need to
construct separate key and note blocks. Markdown, RST, and HTML writers
need to construct lists of notes; Markdown and RST writers need to
construct lists of link references (when the --reference-links option
is specified); and the RST writer needs to construct a list of image
substitution references. All writers have been rewritten to use the
State monad when state is required. This rewrite yields a small speed
boost and considerably cleaner code.
* Text/Pandoc/Definition.hs:
+ blocks: removed Key and Note
+ inlines: removed NoteRef, added Note
+ modified Target: there is no longer a 'Ref' target; all targets
are explicit URL, title pairs
* Text/Pandoc/Shared.hs:
+ Added 'Reference', 'isNoteBlock', 'isKeyBlock', 'isLineClump',
used in some of the readers.
+ Removed 'generateReference', 'keyTable', 'replaceReferenceLinks',
'replaceRefLinksBlockList', along with some auxiliary functions
used only by them. These are no longer needed, since
reference links are resolved in the Markdown and RST readers.
+ Moved 'inTags', 'selfClosingTag', 'inTagsSimple', and 'inTagsIndented'
to the Docbook writer, since that is now the only module that uses
them.
+ Changed name of 'escapeSGMLString' to 'escapeStringForXML'
+ Added KeyTable and NoteTable types
+ Removed fields from ParserState; 'stateKeyBlocks', 'stateKeysUsed',
'stateNoteBlocks', 'stateNoteIdentifiers', 'stateInlineLinks'.
Added 'stateKeys' and 'stateNotes'.
+ Added clause for Note to 'prettyBlock'.
+ Added 'writerNotes', 'writerReferenceLinks' fields to WriterOptions.
* Text/Pandoc/Entities.hs: Renamed 'escapeSGMLChar' and
'escapeSGMLString' to 'escapeCharForXML' and 'escapeStringForXML'
* Text/ParserCombinators/Pandoc.hs: Added lineClump parser: parses a raw
line block up to and including following blank lines.
* Main.hs: Replaced --inline-links with --reference-links.
* README:
+ Documented --reference-links and removed description of --inline-links.
+ Added note that footnotes may occur anywhere in the document, but must
be at the outer level, not embedded in block elements.
* man/man1/pandoc.1, man/man1/html2markdown.1: Removed --inline-links
option, added --reference-links option
* Markdown and RST readers:
+ Rewrote to fit new Pandoc definition. Since there are no longer
Note or Key blocks, all note and key blocks are parsed on a first pass
through the document. Once tables of notes and keys have been constructed,
the remaining parts of the document are reassembled and parsed.
+ Refactored link parsers.
* LaTeX and HTML readers: Rewrote to fit new Pandoc definition. Since
there are no longer Note or Key blocks, notes and references can be
parsed in a single pass through the document.
* RST, Markdown, and HTML writers: Rewrote using state monad new Pandoc
and definition. State is used to hold lists of references footnotes to
and be printed at the end of the document.
* RTF and LaTeX writers: Rewrote using new Pandoc definition. (Because
of the different treatment of footnotes, the "notes" parameter is no
longer needed in the block and inline conversion functions.)
* Docbook writer:
+ Moved the functions 'attributeList', 'inTags', 'selfClosingTag',
'inTagsSimple', 'inTagsIndented' from Text/Pandoc/Shared, since
they are now used only by the Docbook writer.
+ Rewrote using new Pandoc definition. (Because of the different
treatment of footnotes, the "notes" parameter is no longer needed
in the block and inline conversion functions.)
* Updated test suite
* Throughout: old haskell98 module names replaced by hierarchical module
names, e.g. List by Data.List.
* debian/control: Include libghc6-xhtml-dev instead of libghc6-html-dev
in "Build-Depends."
* cabalize:
+ Remove haskell98 from BASE_DEPENDS (since now the new hierarchical
module names are being used throughout)
+ Added mtl to BASE_DEPENDS (needed for state monad)
+ Removed html from GHC66_DEPENDS (not needed since xhtml is now used)
git-svn-id: https://pandoc.googlecode.com/svn/trunk@580 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
contains an entity, this needs to be decoded before obfuscation.
Thanks to thsutton for the patch.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@579 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@578 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
Cleaned up bullet and ordered list code by using
ordList and unordList instead of raw olist and ulist.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@571 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
The problem is that the "href" function escapes &, so
(href "l") is 'href="l"'. Fixed by using
primHtml for the whole link. Resolves issue 9.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@569 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
& instead of &
git-svn-id: https://pandoc.googlecode.com/svn/trunk@557 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@550 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
in cleaner, faster code, and it makes it easier to use Pandoc in
other projects, like wikis, that use Text.XHtml. Two functions
are now provided, writeHtml and writeHtmlString: the former outputs
an Html structure, the latter a rendered string. The S5 writer is
also changed, in parallel ways (writeS5, writeS5String). The Html
header is now written programmatically, so it has been removed from
the 'headers' directory. The S5 header is still needed, but the
doctype and some of the meta declarations have been removed, since
they are written programatically. The INSTALL file and cabalize
have been updated to reflect the new dependency on the xhtml package.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@549 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@520 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
It is no longer needed now that all entities are processed in the markdown
and HTML readers. All calls to stringToSGML have been replaced by calls
to encodeEntities.
+ Since inTag's attribute handling already encodes entities,
calls to encodeEntities are no longer needed for attribute values, so
they've been removed.
+ The HTML and Markdown readers now call decodeEntities on all raw
strings (e.g. authors, dates, link titles), to ensure that no unprocessed
entities are included in the native representation of the document.
(In the HTML reader, most of this work is done by a change in
extractAttributeName.)
+ The result is a small speed improvement (around 5% on my benchmark)
and cleaner code.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@519 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
Str inline in Docbook and HTML writers, since now these
strings should not contain literal entity references.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@518 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
above 128 in HTML and Docbook output, we now just use unicode. After all,
we're declaring UTF-8 content in the header. This makes the HTML and
docbook files produced by pandoc much more readable and editable.
Changes to Entities.hs:
+ Removed specialCharToEntity
+ Added escapeSGMLChar (which just escapes the basic four, <>&")
+ Modified encodeEntities and stringToSGML to use escapeSGMLChar
+ Removed encodeEntitiesNumerical
+ Rewrote encodeEntities for better performance
+ Rewrote stringToSGML for better performance
git-svn-id: https://pandoc.googlecode.com/svn/trunk@516 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ Entities are parsed (and unicode characters returned) in both
Markdown and HTML readers.
+ Parsers characterEntity, namedEntity, decimalEntity, hexEntity added
to Entities.hs; these parse a string and return a unicode character.
+ Changed 'entity' parser in HTML reader to use the 'characterEntity'
parser from Entities.hs.
+ Added new 'entity' parser to Markdown reader, and added '&' as a
special character. Adjusted test suite accordingly since now we
get 'Str "AT",Str "&",Str "T"' instead of 'Str "AT&T"..
+ stringToSGML moved to Entities.hs. escapeSGML removed as redundant,
given encodeEntities.
+ stringToSGML, encodeEntities, and specialCharToEntity are given a
boolean parameter that causes only numerical entities to be used.
This is used in the docbook writer. The HTML writer uses named
entities where possible, but not all docbook-consumers know about
the named entities without special instructions, so it seems safer
to use numerical entities there.
+ decodeEntities is rewritten in a way that avoids Text.Regex, using
the new parsers.
+ charToEntity and charToNumericalEntity added to Entities.hs.
+ Moved specialCharToEntity from Shared.hs to Entities.hs.
+ Removed unneeded 'decodeEntities' from 'str' parser in HTML and
Markdown readers.
+ Removed sgmlHexEntity, sgmlDecimalEntity, sgmlNamedEntity, and
sgmlCharacterEntity from Shared.hs.
+ Modified Docbook writer so that it doesn't rely on Text.Regex for
detecting "mailto" links.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@515 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@501 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
DocBook, and HTML writers. The syntax is documented in
README. Tests have been added to the test suite.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@493 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
Markdown.pl:
+ title attribute comes after alt attribute
+ title is included even if null
git-svn-id: https://pandoc.googlecode.com/svn/trunk@445 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
is now handled in the Markdown and LaTeX readers, rather than in
the writers. The HTML writer has been rewritten to use the
prettyprinting library.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@436 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
Text/Shared/Pandoc. (escapeSGML, stringToSGML, inTag,
inTagSimple, inTagIndented, selfClosingTag) These can be
used by both the HTML and Docbook writers.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@417 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@386 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
option to pandoc, which forces it to stay as close as possible
to official Markdown syntax.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@347 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ Removed invisible anchors in front of header tags in HTML output.
Reason: no way to prevent duplicate ID attributes (which is invalid
HTML), since there might be duplicate header titles. See
http://six.pairlist.net/pipermail/markdown-discuss/2005-January/000975.html.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@306 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@258 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@257 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
(which seems to be the term that is used in this context).
git-svn-id: https://pandoc.googlecode.com/svn/trunk@255 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
by combining it with entity obfuscation.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@254 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ Reformatted code consistently.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@252 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
heading. The anchors are derived form the text of the section
heading as described in README. This makes it easy to insert
links that jump from one part of a document to another:
for example, '[back to the Introduction](#Introduction)'.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@246 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
'comparing' is from Data.Ord, which is not available in GHC 6.4.
+ Added line break after </li> in HTML footnote output, for easier
inspection of the source.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@245 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@241 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
and symbols accordingly.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@224 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
cases where latex commands or HTML entity references appear
after quotes.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@202 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@171 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
+ LaTeX reader did not parse metadata correctly. Now the title,
author, and date are parsed correctly, and everything else in
the preamble is skipped.
+ Simplified parsing of LaTeX command arguments and options.
The function commandArgs now returns a list of arguments OR
options (in whatever order they appear). The brackets are
included, and a new stripFirstAndLast function is provided
to strip them off when needed. This fixes a problem in dealing
with \newcommand, etc.
+ Added a "try" before "parser" in definition of notFollowedBy'
combinator. Adjusted the code using this combinator accordingly.
+ Changed handling of code blocks. Previously, some readers allowed
trailing newlines, while others stripped them. Now, all readers
strip trailing newlines in code blocks; writers insert a newline
at the end of code blocks as needed.
+ Changed test suite to reflect these changes.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@137 788f1e2b-df1e-0410-8736-df70ead52e1b
|
|
git-svn-id: https://pandoc.googlecode.com/svn/trunk@2 788f1e2b-df1e-0410-8736-df70ead52e1b
|