GNOME Bugzilla – Bug 753911
Missing "Add to Dictionary" with multiple languages enabled
Last modified: 2015-08-28 13:04:29 UTC
Moving this from a downstream bug report: https://bugzilla.redhat.com/show_bug.cgi?id=1255525 Description of problem: Can't add new words to any dictionary used by the spell checker. Version-Release number of selected component (if applicable): 3.16.4 How reproducible: Always happens Steps to Reproduce: 1. Start writing a new e-mail message 2. Type a sentence containing an unknown word, e.g. Messerschmitt, followed by a space. The word is underlined in red as expected 3. Right click on the word. The pop-up menu appears with items to: - allow spelling correction using the dictionary(s) - Ignore misspelt word - Undo - Redo - Cut - Copy (disabled) - Paste (disabled) - Paste Quotation - Input methods However, there is no item that can be used to add the word to a dictionary. Selecting a dictionary (I have two configured) allows the spelling to be corrected (but I'm unable to get it to display more than a single choice) but once again, there is no way shown to add the new word to the dictionary. Actual results: As described. No way of extending the dictionary is offered and there is never more than one alternative word shown. Expected results: Selecting a dictionary should offer the choice of one or more replacement words *and* a way to add the word being checked to the dictionary Previous versions of Evolution have always provided both these abilities.
Testing it here, the main difference is the multiple dictionary case. For example, I wrote "apstair". With English (United States) dictionary Firefox suggests "upstairs" and "stair". The composer suggests the same when only this one dictionary is selected, together with the "Add Word to Dictionary" menu item and "Ignore Misspelled Word" menu item. When I enable also another dictionary, then the US dictionary contains only "upstairs", the second choice is missing for some reason. When the composer is opened with multiple dictionaries selected, the "Add Word to Dictionary" is completely missing, but disabling all but one dictionary and then enable the others makes it show. That said, there is some oddity when multiple dictionaries are enabled.
Couple issues in the code, one about not increasing 'ii' variable, thus multiple suggestions simply failed due to using the same action name. It also printed runtime warning on the console. The other was more complex, having always hidden languages (unless enabled within the composer), which breaks things a bit. Also rather update spell checking menus more often, than less. Created commit 91010e0 in evo master (3.17.91+)