git.iko.soy/typeable/pandoc
on master help sign in
Changed handling of titles in HTML writer so you don't get "titleprefix - "

followed by nothing. git-svn-id: https://pandoc.googlecode.com/svn/trunk@1159 788f1e2b-df1e-0410-8736-df70ead52e1b

commita465c4f659b5bd2b67f1a00f64a70eb535ba6ef8 authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> dateSat 29 Dec 2007, 21:11 (19 years ago) parent5e65598
1 file changed+4−2
Text/Pandoc/Writers/HTML.hs+4−2
Text/Pandoc/Writers/HTML.hs+4−2
@@ -71,8 +71,10 @@ writeHtml opts (Pandoc (Meta tit authors date) blocks) =
7171 let titlePrefix = writerTitlePrefix opts
7272 topTitle = evalState (inlineListToHtml opts tit) defaultWriterState
7373 topTitle' = if null titlePrefix
74− then topTitle
75− else titlePrefix +++ " - " +++ topTitle
74+ then topTitle
75+ else if null tit
76+ then stringToHtml titlePrefix
77+ else titlePrefix +++ " - " +++ topTitle
7678 metadata = thetitle topTitle' +++
7779 meta ! [httpequiv "Content-Type",
7880 content "text/html; charset=UTF-8"] +++