#! /bin/sh

(
cat << /END
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<h3>Mined mnemonic character input support</h3>
Mined mnemonic input support for Unicode characters 
recognizes the following character mnemonics:

<ul>
<li>Mnemos from <a href=http://rfc.sunsite.dk/rfc/rfc1345.html>
	RFC 1345</a>; in ambiguous cases, the RFC 1345 mnemos must be 
	prepended a digit "1".
<li><a href=http://selfhtml.teamone.de/html/referenz/zeichen.htm#benannte_iso8859_1>
	HTML mnemos</a>; in ambiguous cases, the HTML mnemos must be 
	prepended a "&".
<li>TeX mnemos (macros) and substitutes, leaving out any "\".
<li>Additional mnemos as listed in the table below
	(best viewed with Netscape 7).
	<br><font style="background-color: yellow">&nbsp;</font> means: 
	enter a blank character (only works in two-character 
	combination shortcut ^Vxy).
</ul>

<table border=1>
<tr><th>character<th>description<th>hex value<th>mnemo
/END

#	{"|T", 0x00DE /* Þ */},

sed	-e 's,^[ 	]*/\*\(.*\)\*/,<tr><td colspan=4><br><h4>\1</h4>,' \
	-e t \
	-e 's,{"",{"  ",' \
	-e 's/},.*/},/' \
	-e '/^[	 ]*{/ b entry' -e d \
	-e ': entry' \
	-e 's,\\",",g' \
	-e 's+{"\(.*\)", *0x\([0-9A-Fa-f]*\) */\* *\(.*\) *\*/},*+<tr><td>\&#x\2;<td>\3<td>\2<td>\1+' \
	-e 's,  $,<font style="background-color: yellow">\&nbsp;\&nbsp;</font>,' \
	-e 's, $,<font style="background-color: yellow">\&nbsp;</font>,' \
	mnemos.add

echo '</table>'
) > ../doc/mnemodoc.html
