Index: TOC.py
===================================================================
--- TOC.py	(revision 112)
+++ TOC.py	(working copy)
@@ -6,6 +6,7 @@
 
 rules = re.compile(r"""(?P<heading>^\s*(?P<hdepth>=+)\s(?P<header>.*)\s(?P=hdepth)\s*$)""")
 anchor = re.compile('[^\w\d]+')
+list_types = ['I', 'A', '1', 'a', 'i']
 
 def parse_toc(env, out, page, body):
     depth = 1
@@ -22,7 +23,8 @@
             elif new_depth > depth:
                 while new_depth > depth:
                     depth += 1
-                    out.write("<ol><li>\n")
+                    list_type = list_types[(depth-1)%len(list_types)]
+                    out.write("<ol class=\"toc-depth%d\" type=\"%s\"><li>\n" % (depth, list_type))
             else:
                 out.write("</li><li>\n")
             link = page + "#" + anchor.sub("", header)
@@ -34,8 +36,9 @@
 def execute(hdf, args, env):
     db = env.get_db_cnx()
     out = StringIO()
-    out.write("<div class='wiki-toc'>\n<ol>\n")
+    out.write("<div class='wiki-toc'>\n")
     out.write("<h4>Table of Contents</h4>\n")
+    out.write("<ol class=\"toc-depth%d\" type=\"%s\">\n" % (1, list_types[0]))
     # Has the user supplied a list of pages?
     if not args:
         args = hdf.getValue("args.page", "WikiStart")
@@ -50,3 +53,4 @@
             out.write('<div class="system-message"><strong>Error: Page %s does not exist</strong></div>' % page)
     out.write("</ol>\n</div>\n")
     return out.getvalue()
