diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-11-17 08:39:19 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-11-17 08:39:19 (GMT) |
commit | 969ef21225d3b195d58f9bb37d8b1f8f3c8b6d99 (patch) | |
tree | c2130e2b59f4222d948814efdb7a5327683523d1 /tools | |
parent | 0566be32d57a7bc95e5b46e7049e37016d1cb13f (diff) | |
download | tcl-969ef21225d3b195d58f9bb37d8b1f8f3c8b6d99.zip tcl-969ef21225d3b195d58f9bb37d8b1f8f3c8b6d99.tar.gz tcl-969ef21225d3b195d58f9bb37d8b1f8f3c8b6d99.tar.bz2 |
Extend tcltk-man2html-utils.tcl, so it can handle the TIP #588 man-page. Also fix 2 (minor) syntax errors in man-pages
Diffstat (limited to 'tools')
-rw-r--r-- | tools/tcltk-man2html-utils.tcl | 70 |
1 files changed, 58 insertions, 12 deletions
diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index 65d81de..0aa1d5c 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -130,8 +130,8 @@ proc htmlize-text {text {charmap {}}} { \" {"} \ {<} {<} \ {>} {>} \ - \u201c "“" \ - \u201d "”" + \u201c "“" \ + \u201d "”" return [string map $charmap $text] } @@ -144,20 +144,62 @@ proc process-text {text} { {\&} "\t" \ {\%} {} \ "\\\n" "\n" \ - {\(+-} "±" \ + {\(r!} "¡" \ + {\(ct} "¢" \ + {\(Po} "£" \ + {\(Cs} "¤" \ + {\(Ye} "¥" \ + {\(bb} "¦" \ + {\(sc} "§" \ + {\(ad} "¨" \ {\(co} "©" \ - {\(em} "—" \ - {\(en} "–" \ - {\(fm} "′" \ - {\(mc} "µ" \ - {\(mu} "×" \ - {\(mi} "−" \ - {\(->} "<font size=\"+1\">→</font>" \ + {\(Of} "ª" \ + {\(Fo} "«" \ + {\(no} "¬" \ + {\(rg} "®" \ + {\(a-} "¯" \ + {\(de} "°" \ + {\(+-} "±" \ + {\(S2} "²" \ + {\(S3} "³" \ + {\(aa} "´" \ + {\(mc} "µ" \ + {\(ps} "¶" \ + {\(pc} "·" \ + {\(ac} "¸" \ + {\(S1} "¹" \ + {\(Om} "º" \ + {\(Fc} "»" \ + {\(14} "¼" \ + {\(12} "½" \ + {\(34} "¾" \ + {\(r?} "¿" \ + {\(AE} "Æ" \ + {\(-D} "Ð" \ + {\(mu} "×" \ + {\(TP} "Þ" \ + {\(ss} "ß" \ + {\(ae} "æ" \ + {\(Sd} "ð" \ + {\(di} "÷" \ + {\(Tp} "þ" \ + {\(em} "—" \ + {\(en} "–" \ + {\(bu} "•" \ + {\(fm} "′" \ + {\(mi} "−" \ + {\(->} "<font size=\"+1\">→</font>" \ {\fP} {\fR} \ {\.} . \ - {\(bu} "•" \ - {\*(qo} "ô" \ ] + # This might make a few invalid mappings, but we don't use them + foreach c {a c e i n o u y A C E I N O U Y} { + foreach {prefix suffix} { + o ring / slash : uml ' acute ^ circ ` grave ~ tilde , cedilla + } { + lappend charmap "\\\[${prefix}${c}\]" "&${c}${suffix};" + } + } lappend charmap {\-\|\-} -- ; # two hyphens lappend charmap {\-} - ; # a hyphen @@ -1559,6 +1601,10 @@ proc make-manpage-section {outputDir sectionDescriptor} { puts stderr "" } + if {![llength $manual(wing-toc)]} { + fatal "not table of contents." + } + # # make the wing table of contents for the section # |