X-Git-Url: http://git.megacz.com/?p=wix.git;a=blobdiff_plain;f=src%2FHtml.lhs;h=a3ff54f19c3f0780bf5debf114110aa991bc5a5e;hp=74259f77291880423ad1ab3b0e9e6bbfc7b53d10;hb=78e11871be7fa7677a0e3822b6e08b3beca1c4b7;hpb=e6b058675419bdc7fb164809807837eb5e49c7dd diff --git a/src/Html.lhs b/src/Html.lhs index 74259f7..a3ff54f 100644 --- a/src/Html.lhs +++ b/src/Html.lhs @@ -183,8 +183,9 @@ instance ToHtml Paragraph where toHtml (P t) = stag "p" $ toHtml t -link ref body = ""++icon++body++"" +link ref body = ""++icon++body++"" where + urlify = toHtml icon = if ".pdf" `isSuffixOf` ref then " " else if "mailto:" `isPrefixOf` ref then " " else "" @@ -274,7 +275,7 @@ instance ToHtml Text where toHtml (GlyphText TradeMark) = "™" toHtml (GlyphText ServiceMark) = "™" toHtml (GlyphText Emdash) = "—" - toHtml (GlyphText Ellipsis) = "…" + toHtml (GlyphText Ellipsis) = "…" -- &cdots;? toHtml (GlyphText Cent) = "½" toHtml (GlyphText Daggar) = "†" toHtml (GlyphText DoubleDaggar) = "‡" @@ -284,7 +285,8 @@ instance ToHtml Text where toHtml (GlyphText Sharp) = "⋘" toHtml (GlyphText CheckMark) = "✓" toHtml (GlyphText XMark) = "✗" - toHtml (GlyphText LeftArrow) = "&#;" -- FIXME + toHtml (GlyphText LeftArrow) = "←" + toHtml (GlyphText RightArrow) = "→" toHtml (GlyphText DoubleLeftArrow) = "&#;" -- FIXME toHtml (GlyphText DoubleRightArrow) = "&#;" -- FIXME toHtml (GlyphText DoubleLeftRightArrow) = "&#;" -- FIXME @@ -312,7 +314,7 @@ htmlEscapeChar '\'' = "'" htmlEscapeChar '\"' = """ htmlEscapeChar c = [c] -pre x = "\n
"++ (pre' x) ++ "\n
\n" +pre x = "\n
"++ (pre' x) ++ "\n
\n" where pre' (' ':b) = " "++(pre' b) pre' ('\n':b) = "
\n"++(pre' b)