-
Notifications
You must be signed in to change notification settings - Fork 15k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expose spellcheck_platform::CheckSpelling
API
#22829
Comments
@craftzdog That method is not cross platform, can you clarify your usecase for this method? |
@MarshallOfSound Thanks for the reply. My usecase is that I'm building a Markdown editor based on CodeMirror which browser's spellchecker doesn't work. I found |
@MarshallOfSound On what operating system is the Exposing the API will benefit a lot of applications using a custom editor. The electron site shows 65 applications that contain "editor" in their description. We have the same problem at https://caret.io/. |
I have the same setup with CodeMirror. After digging around for a few hours, I did not find any undocumented spellcheck access 😂 The current alternative is to use typo.js and self-manage hunspell libraries downloading from the renderer. Other than having to do all that repeated work, it also doesn't support multiple languages (cfinke/Typo.js#37) A second alternative is to bring in electron-spellchecker (or a variant of it) which is what we were trying to move away from in the first place with native spellchecker support. Hoping we can make this a reality. Thanks again for all the hard work! |
Maybe also expose |
@MarshallOfSound I've put down a few hours into exploring the codebase and hooking up a working prototype. Currently having some trouble with how to properly expose the API. Would really appreciate if you have some tips. As for use case, adding to the others here, I'm working on https://obsidian.md which is also based on CodeMirror. @craftzdog @astoilkov @abnerlee Also wanted to say hi, big fan of all your work! 😃 |
@lishid hi 👋 Great to know you made a PR for the issue! |
Hi, thank you for creating such a great framework!
I have a feature request which I think I can contribute, but let me check if you are interested in supporting it.
Preflight Checklist
Problem Description
The builtin spellchecker has been supported in #20692.
But it does not allow us to check spells programmatically, like node-spellchecker's
isMisspelled
method.Chrome's spellcheck_platform provides CheckSpelling to do that exactly.
Proposed Solution
Add a method to call
spellcheck_platform::CheckSpelling
like so:in
shell/browser/api/atom_api_session.cc
.It's simple and won't affect other features.
Alternatives Considered
I don't know.
Additional Information
None
Thanks!
The text was updated successfully, but these errors were encountered: