TitleIndex macro: refactor for clarity, document internal helper functions
TitleIndex macro: refactor for clarity, document internal helper functions

pkdevbox/trac,pkdevbox/trac,pkdevbox/trac,pkdevbox/trac