kovidgoyal/calibre — pull request #240 by pgarst (2014-05-02 05:05:00+00:00)
Title: Fixes bugs in numbering custom numbered styles

I'll send a document illustrating this issue.
There are cases where docx paragraphs which include bullets or numbers in the styles are losing their numbers in the epub document.

The changes here fix this issue in the test document, but I'm not sure it is the right fix.

The immediate cause of the missing numbers is that the para_link field of the Level object was not being set. I introduced a new section in numbering.py to set this field.
Setting that field depends on a new numbering_style_defs field in the styles object. That has a lot of overlap with the numbering_style_links field, and there may be a cleaner way to get that information.