You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When adding a new word to the Project Word List via context menu in the Editor, if the word is surrounded by emphasis markups, i.e. underscores _, novelWriter adds a new entry in the PWL including any underscore as it appears in the editor, instead of stripping the markup before the addition.
This has the obvious side effect of still detecting the word as a misspell wherever it appears in the editor.
Tested on main branch.
The text was updated successfully, but these errors were encountered:
Also, right now, when you add a new word to the Project Word List from the context menu, if the word is adjacent by novelWriter symbols, specifically any dash, and any character under the Other Symbols entry under the Insert menu.
E.g., adding the word ÷rawr (“rawr” preceded by the division sign as inserted by novelWriter) creates an entry in the PWL without stripping the division sign.
It sounds too close to the current issue for me to create a new one. But it perhaps is like that by design, so then it may just be a feature request? Beats me.
Yes, the right click action uses Qt's own word selector method to select the word that is added. I have already rewritten this entire logic in PR #1525, so from release 2.2 the spell check errors will be saved as meta data with each paragraph and used for the spell check correction logic that is called by the right click actions.
Both underscore and other symbols are considered as parts of words by the Qt text editor. I have added some post-processing logic to it from previous issue tickets (see #1415), but at the end of the day, rewriting the logic is a better approach than chasing all these corner cases. As far as I can tell, the new logic fixes all of this on a fundamental level by using Unicode word boundary detection via RegEx instead. It also means what is selected and what is underlined will match.
I'll add your ticket to the current PR as that PR will solve the issue, and I'll double check how it handles symbols.
vkbo
added
editor
Component: Editor
usability
Issue: Could do with some improvement
planned
Note: Feature planned for a later release
and removed
bug
Issue: Something isn't working
labels
Oct 14, 2023
When adding a new word to the Project Word List via context menu in the Editor, if the word is surrounded by emphasis markups, i.e. underscores
_
, novelWriter adds a new entry in the PWL including any underscore as it appears in the editor, instead of stripping the markup before the addition.This has the obvious side effect of still detecting the word as a misspell wherever it appears in the editor.
Tested on
main
branch.The text was updated successfully, but these errors were encountered: