Apache OpenOffice (AOO) Bugzilla – Issue 90729
Anchor of a table is corrupt
Last modified: 2013-08-07 14:38:26 UTC
The following code produces an InvalidArgumentException if it is applied on a TextDocument with at least one table: tt = ThisComponent.TextTables for i=0 to tt.count-1 table = tt.getByIndex(i) cursor = table.Anchor.Text.createTextCursorByRange(table.Anchor) next i It seems that table.Anchor is corrupt as also xray produces a lot of Exceptions when inspecting the object. IMO table.Anchor should be an object that represents a XTextRange in the Text-Objects that contains the table. The object is not comparable via table.Anchor.Text.compareRegionStarts(table.Anchor, table.Anchor.Text.Start), too.
Reassigned to JSK
API, to CN
cn->tl: as discussed please take over
In theory the anchor of the table should mark the start /end node pair of the table in Writer's text model implementation. In practice it is not possible for cursors in Writer to select non-text nodes. This is definitely a bug but as long as the core implementation doesn't change the API implementation will cannot be improved. Dependency to issue 7747 set.