LaTeX writer: don't escape _ in url.

This commit is contained in:
John MacFarlane 2012-09-15 20:42:24 -07:00
parent fc4ae15337
commit d9e34ce34d
2 changed files with 2 additions and 2 deletions

View file

@ -189,7 +189,7 @@ stringToLaTeX isUrl (x:xs) = do
'$' -> "\\$" ++ rest
'%' -> "\\%" ++ rest
'&' -> "\\&" ++ rest
'_' -> "\\_" ++ rest
'_' | not isUrl -> "\\_" ++ rest
'#' -> "\\#" ++ rest
'-' -> case xs of -- prevent adjacent hyphens from forming ligatures
('-':_) -> "-{}" ++ rest

View file

@ -786,7 +786,7 @@ Just a \href{/url/}{URL}.
\href{/url/}{URL and title}
\href{/url/with\_underscore}{with\_underscore}
\href{/url/with_underscore}{with\_underscore}
\href{mailto:nobody@nowhere.net}{Email link}