mirror of
https://github.com/jgm/pandoc.git
synced 2026-08-26 18:26:36 +00:00
Added parsing for \url to LaTeX reader.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@833 788f1e2b-df1e-0410-8736-df70ead52e1b
This commit is contained in:
@@ -405,7 +405,7 @@ inline = choice [ strong, emph, strikeout, superscript, subscript,
|
||||
accentedChar, specialChar, specialInline, escapedChar,
|
||||
unescapedChar, str, endline, whitespace ] <?> "inline"
|
||||
|
||||
specialInline = choice [ link, image, footnote, rawLaTeXInline ]
|
||||
specialInline = choice [ url, link, image, footnote, rawLaTeXInline ]
|
||||
<?> "link, raw TeX, note, or image"
|
||||
|
||||
accentedChar = normalAccentedChar <|> specialAccentedChar
|
||||
@@ -654,6 +654,11 @@ math2 = try (do
|
||||
-- links and images
|
||||
--
|
||||
|
||||
url = try (do
|
||||
string "\\url"
|
||||
url <- charsInBalanced '{' '}'
|
||||
return (Link [Code url] (url, "")))
|
||||
|
||||
link = try (do
|
||||
string "\\href{"
|
||||
url <- manyTill anyChar (char '}')
|
||||
|
||||
Reference in New Issue
Block a user