Created attachment 141073 [details] Python-only reproducer for bibisect purposes. Steps to reproduce: 1) Apply the attached python patch, so you have a python script that can register a selection listener. 2) Create a writer document and run the python script. 3) Type some characters, create a bookmark covering some of the characters in the document and move around with your cursor: you can see on the console that XText from the selection and from the bookmark is the same SwXBodyText, same pointer address. 4) Now insert a table and do the same (insert characters, insert bookmark) in a table cell. Expected result: similar to outside a table, the XText is the same SwXCell in both the selection and the cell case. Actual result: we hand out two separate SwXCell instances (different pointer address). This is problematic, as later XTextRangeCompare will require that the text ranges come from the same XText, so you can't compare ranges from in-table text.
Miklos Vajna committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=b9f7535e499002706f276c0275c1e6c3c7b6bdd4 tdf#116789 sw: fix caching of the SwXCell UNO wrapper It will be available in 6.1.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.