@@ -218,7 +218,12 @@ renderExternal fmt width doc
218218 decorate HTMLOutput (AnnData _ _) = tag "idris-data" Nothing
219219 decorate HTMLOutput (AnnType _ _) = tag "idris-type" Nothing
220220 decorate HTMLOutput AnnKeyword = tag "idris-keyword" Nothing
221− decorate HTMLOutput (AnnTextFmt _) = id -- TODO
221+ decorate HTMLOutput (AnnTextFmt fmt) =
222+ case fmt of
223+ BoldText -> mkTag "strong"
224+ ItalicText -> mkTag "em"
225+ UnderlineText -> tag "idris-underlined" Nothing
226+ where mkTag t x = "<"++t++">"++x++"</"++t++">"
222227 decorate HTMLOutput (AnnTerm _ _) = id
223228 decorate HTMLOutput (AnnSearchResult _) = id
224229 decorate HTMLOutput (AnnErr _) = id
@@ -241,7 +246,11 @@ renderExternal fmt width doc
241246 decorate LaTeXOutput (AnnData _ _) = latex "IdrisData"
242247 decorate LaTeXOutput (AnnType _ _) = latex "IdrisType"
243248 decorate LaTeXOutput AnnKeyword = latex "IdrisKeyword"
244− decorate LaTeXOutput (AnnTextFmt _) = id -- TODO
249+ decorate LaTeXOutput (AnnTextFmt fmt) =
250+ case fmt of
251+ BoldText -> latex "textbf"
252+ ItalicText -> latex "emph"
253+ UnderlineText -> latex "underline"
245254 decorate LaTeXOutput (AnnTerm _ _) = id
246255 decorate LaTeXOutput (AnnSearchResult _) = id
247256 decorate LaTeXOutput (AnnErr _) = id
@@ -260,7 +269,8 @@ renderExternal fmt width doc
260269 ".idris-function {color: green; }",
261270 ".idris-keyword { font-weight: bold; }",
262271 ".idris-bound { color: purple; }",
263− ".idris-implicit { font-style: italic; }"]
272+ ".idris-implicit { font-style: italic; }",
273+ ".idris-underlined { text-decoration: underline; }"]
264274 wrap LaTeXOutput str =
265275 concat . intersperse "\n" $
266276 ["\\documentclass{article}",