With theis modification, it is now possible to include a simple table of contents (TOC) in your RTF file.
I have modified Container.php to implement :
1/ local links (modification of writeHyperLink() method)
2/ bookmarks (new writeBookmark() method).
New Container.php (this one includes also the horizontal ruler in writeText() method).