在系统范围内更改可可单词补全 - 可能吗?
在您自己的应用程序中,从 NNTextView 修改单词补全就像实现 textView:completions:forPartialWordRange:indexOfSelectedItem:
是否有任何方法可以为其他应用程序执行 tjis,即替换或增强内置单词补全建议?
In your own app modifying the word completions from NNTextView is as simple as implementing textView:completions:forPartialWordRange:indexOfSelectedItem:
Is there any way to do tjis for other apps, that is replacing or augmenting the built-in word completion suggestions?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
![扫码二维码加入Web技术交流群](/public/img/jiaqun_03.jpg)
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
是的,在某种程度上。您需要编写一个拼写服务器。安装后,您可以在系统首选项中选择默认的拼写检查器。有关文档,请参阅 Apple 的介绍和详细信息参考文献,例如
NSSpellServer
。然而,我不认为你可以在你自己的拼写服务器中实现苹果标准拼写/语法检查器所做的一切;比较
NSSpellServer
需要实现的方法列表,以及方法NSSpellChecker
有。 Apple 正在慢慢向NSSpellServer
添加与NSSpellChecker
相对应的方法...让我们希望 Apple 能尽快做到这一点。Yes, to some extent. You need to write a spell server. Once installed, you can select the default spell checker in the system preferences. For documentation, see Apple's introduction and detailed references, e.g. for
NSSpellServer
.However, I don't think you can implement everything in your own spell server what Apple's standard spell/grammar checker does; compare the list of methods
NSSpellServer
needs to implement, and methodsNSSpellChecker
has. Apple slowly adds toNSSpellServer
the methods which correspond to those ofNSSpellChecker
... let's hope Apple does this quickly.