Spell check textbox in Win10 - Slow

后端 未结 3 1136
长发绾君心
长发绾君心 2020-12-21 01:46

I\'m using the built in spell checker in WPF. It was working just fine until I had users start upgrading to windows 10... I think the issue is that it\'s being used for a

3条回答
  •  情书的邮戳
    2020-12-21 02:25

    We have experienced a similar issue and saw improved performance by avoiding re-registering custom dictionaries on every TextBox control during load.

    Unfortunately, we hit another issue with the way custom dictionaries are handled which can also result in very long loading times if you have even a small number of TextBox controls.

    When a WPF application registers a custom dictionary in .NET 4.6.1 on Windows 8.1/10, a temporary dictionary file is created in %localappdata%\Temp and this is registered in the multistring value _GLOBAL_ in the registry key "Computer\HKEY_CURRENT_USER\Software\Microsoft\Spelling\Dictionaries".

    If the _GLOBAL_ value ends up referencing a dictionary file which does not exist, the application starts to exhibit very slow loading whenever a control with spell check enabled is initialized.

    This can happen by using the "Stop debugging" button in Visual Studio and then running the Disk Clean-up or CCleaner after enough time has passed for these to delete the temp dictionary files.

    We managed to fix this by clearing the _GLOBAL_ value of any links to dictionary files which did not exist. The our application began to work as expected.

    We raised the following connect bug: https://connect.microsoft.com/VisualStudio/feedback/details/2153484

提交回复
热议问题