Posted: Tue Dec 30, 2014 10:14 am Post subject: Fixes for bugs when using the NeoOffice :: Services menu
The new native "speak to text" feature uses NeoOffice's OS X Services code and while working on this new feature, I found and fixed the following bugs that occurred when selecting the NeoOffice :: Services menu:
When in a Calc document, the Services menu would use text from the last selected combobox instead of the currently selected cell
When in a Writer document, the Services menu would use the last selected text even after unselecting all text
The fixes for these bugs are in the following test patches for anyone who wants to test the fix. I fixed the bug by forcing NeoOffice's underlying OpenOffice code to copy the currently selection to the system clipboard and then passing any text in the system clipboard the various OS X services:
Posted: Tue Dec 30, 2014 3:02 pm Post subject: Re: Fixes for bugs when using the NeoOffice :: Services menu
pluby wrote:
When in a Calc document, the Services menu would use text from the last selected combobox instead of the currently selected cell
FWIW, on 10.8.5, it seems that Neo would use the last selected text regardless of where it was (e.g., selected text in a cell/edit bar during editing) or alternately claim that no Services were available, but regardless, Patch-10-Test-2 seems to fix the behavior so Neo always uses the currently selected cell when there's no other explicitly selected text.
As a side-effect, I notice that whenever you highlight the Services menu, the "this cell has been copied" highlighting happens to the cell (which makes sense, given your description of the changes in the fix.)
pluby wrote:
When in a Writer document, the Services menu would use the last selected text even after unselecting all text
I could not figure out how to trigger this in 10.8.5 (3.4.1 Patch-10 or 2014.6); whenever I selected text, then deselected all text, the Services menu reported there were no Services available.
Quote:
I fixed the bug by forcing NeoOffice's underlying OpenOffice code to copy the currently selection to the system clipboard and then passing any text in the system clipboard the various OS X services
I assume there's no way to force-copy into the Services' pasteboard(s) directly? I ask because generally speaking in Mac OS X (and in NeoOffice prior to these patches), Service requests don't stomp the contents of the general pasteboard ("the clipboard"). Practically speaking, I don't know if it's a big deal--I'm guessing it's not a common workflow to copy something, perform a Service request on something else, and then paste the clipboard somewhere, though I have been known, when working in various apps, to cut something, do a bunch of editing on what's left, and then paste the cut stuff post-editing. So any time there's a NeoOffice Service or Text-to-Speech request in the middle of something like that, there's potential dataloss due to unexpected behavior, because normally only another explicit copy/cut operation replaces the current contents of the clipboard. Like I said, I don't know how common any of these scenarios are, but because they do potentially involve dataloss now, I wanted to mention it.
Smokey _________________ "[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
Posted: Wed Dec 31, 2014 1:31 pm Post subject: Re: Fixes for bugs when using the NeoOffice :: Services menu
sardisson wrote:
I assume there's no way to force-copy into the Services' pasteboard(s) directly? I ask because generally speaking in Mac OS X (and in NeoOffice prior to these patches), Service requests don't stomp the contents of the general pasteboard ("the clipboard")....
I think there might be a way to get NeoOffice's underlying OpenOffice code to copy to an internal buffer instead of the general pasteboard. I should know if this is possible in the next few days.
Posted: Fri Jan 02, 2015 9:55 am Post subject: Re: Fixes for bugs when using the NeoOffice :: Services menu
I found a way to get NeoOffice's underlying OpenOffice code to copy to an internal buffer instead of the general pasteboard.
In the following test patches, the NeoOffice :: Services menu and OS X's "text to speech" feature should no longer change what is in the general pasteboard:
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum