gedit-intelligent-text-completion
gedit-intelligent-text-completion copied to clipboard
Destructive side-effect on GeditDocument.get_text()
Hello,
i am developing a python plugin for gedit (3.10.4). In that plugin i hook to the event 'changed' on the GeditDocument. In that event i try to get the current contents of the document using "document.get_text(start, end, False)".
When i have no other plugins active i get the correct content of the document. When this plugin (gedit-intelligent-text-completion) is active, i get weird results when creating newlines after '{' signs. For better domenstration i have recorded what is happening and attached it as a gif to this issue. Notice how lines 2 and 3 merges in the return of 'GeditDocument.get_text()'.
This behaviour conflicts with my plugin and potentially with other plugins that try to fetch the document-content when it's changes.