From b36a8def513d0fdd96fce220cf1f14409853c7b5 Mon Sep 17 00:00:00 2001 From: Adam Chlipala Date: Fri, 15 Jul 2011 17:31:57 -0400 Subject: Tutorial section headings --- src/tutorial.sml | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) (limited to 'src/tutorial.sml') diff --git a/src/tutorial.sml b/src/tutorial.sml index 2b875c0b..a2156adc 100644 --- a/src/tutorial.sml +++ b/src/tutorial.sml @@ -75,7 +75,26 @@ fun fixupFile (fname, title) = val (befor, after) = Substring.position "(* " source in if Substring.isEmpty after then - TextIO.outputSubstr (outf, source) + let + val (befor, after) = Substring.position "(** " source + in + if Substring.isEmpty after then + TextIO.outputSubstr (outf, source) + else + let + val (befor', after) = Substring.position " *)" + (Substring.slice (after, 65, NONE)) + in + if Substring.isEmpty after then + TextIO.outputSubstr (outf, source) + else + (TextIO.outputSubstr (outf, befor); + TextIO.output (outf, "

"); + proseLoop befor'; + TextIO.output (outf, "

"); + loop (Substring.slice (after, 49, NONE))) + end + end else let val (befor', after) = Substring.position "
*)" @@ -105,6 +124,12 @@ fun fixupFile (fname, title) = TextIO.output (outf, "\t\tpadding: 5px;\n"); TextIO.output (outf, "\t\tfont-size: larger;\n"); TextIO.output (outf, "\t}\n"); + TextIO.output (outf, "\th2 {\n"); + TextIO.output (outf, "\t\tfont-family: Arial;\n"); + TextIO.output (outf, "\t\tfont-size: 20pt;\n"); + TextIO.output (outf, "\t\tbackground-color: #99FF99;\n"); + TextIO.output (outf, "\t\tpadding: 5px;\n"); + TextIO.output (outf, "\t}\n"); TextIO.output (outf, "-->\n"); TextIO.output (outf, "\n"); TextIO.output (outf, ""); -- cgit v1.2.3