ikarago / Notepad

A Fluent-style Notepad-application because Microsoft doesn't make it.
MIT License
118 stars 14 forks source link

SpellChecker isn't enabled when turned on #50

Open ikarago opened 4 years ago

ikarago commented 4 years ago

The SpellChecker doesn't work when booting the app; it needs to be turned off and back on again in order to work.

Repo steps: 1) Open the app with the SpellChecker toggle enabled in Settings 2) Type something with a spelling error. 3) SpellChecker doesn't mark the incorrectly spelled word.

Workaround mode: 4) Open Settings 5) Turn off Spell Checker 6) Turn it back on again 7) Close the Settings Dialog The incorrectly spelled word will now be marked as such.

yaira2 commented 4 years ago

Just a note, any new words that are misspelled are underlined but existing ones are not. I am fairly certain this is bug with the TextBox control and not how you are implementing it. Maybe this is something for the WinUI repo.

prayaas-a commented 4 years ago

Just a note, any new words that are misspelled are underlined but existing ones are not. I am fairly certain this is bug with the TextBox control and not how you are implementing it. Maybe this is something for the WinUI repo.

+1. Literally just discovered the same thing. If you start with a blank document, spellcheck works if enabled in a new instance. Existing words don't get underlined unless you go tap/click on them. I can think of workarounds but they'd likely be impractical. Seems like a TextBox control issue.

yaira2 commented 4 years ago

@prayaas-a What potential workaround can you think of? The one I have been thinking about is reloading the text after the setting is changes, its kind of messy but it might be the best solution for now.

prayaas-a commented 4 years ago

@prayaas-a What potential workaround can you think of? The one I have been thinking about is reloading the text after the setting is changes, its kind of messy but it might be the best solution for now.

Yes, I was thinking of reloading all the text. Not even sure if it would work. It depends on where the bug is. If it's a focus bug (i.e. the text needs to be focused at some point to be spell checked), we could show an overlap ("applying") while we iterate through and focus on all the characters. Both solutions are very messy.