Extending TOC_Helper or subclassing it

From: Volodymyr Rudyj <vladimir.rudoy_at_gmail.com>
Date: Tue Jul 05 2011 - 10:14:31 CEST

Good day everyone !

While adding one new feature to HTML exporter (splitting exported
document into several HTML`s by using heading styles) i found out that
i need to create listener class for detecting headings and their
positions. But existing classes (TOC_Helper and TOC_Listener) have
part of required functionality - they only detect header styles, but
don`t save their positions. Can I add one new method to this class
(something like UT_DocPosition getNthTOCPosition(int nth), it will not
change existing behavior) or I should write my own class ?

P.S. One more question : Which type of splitting document seems to you
more comfortable :
 1. Split document using only top level toc styles (that have level
value = 1, if there are no such elements in the document - it will not
be splitted)
 2. Split document using toc style with the least level value in the
document (e.g. if there are only Heading 2 and Heading 3, document
will be splitted using 'Heading 2' style in this case)
3. Give an option to user

Thanks!
Received on Tue Jul 5 10:14:59 2011

This archive was generated by hypermail 2.1.8 : Tue Jul 05 2011 - 10:14:59 CEST