Skip to content
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

Minimal language support for speller in comments #832

Closed
zorgnac opened this issue Nov 2, 2021 · 4 comments
Closed

Minimal language support for speller in comments #832

zorgnac opened this issue Nov 2, 2021 · 4 comments

Comments

@zorgnac
Copy link

zorgnac commented Nov 2, 2021

Sabaki v0.52.0 - linux x64

When editing comments, Sabaki underlines misspelled words with a red wave. The notion of misspelling is built-in according to some reference language - namely English - and is not affected by user interface localization. This makes editing quite uncomfortable, as you may type perfect spelling in your own language - or even worse use proper go vocabulary - and get distracted by those red waves you cannot do anything about.

Sabaki may, as a minimal support, either let the user choose not to underline misspelled, or to specify the list of languages he is editing for.

If anyone is interested, I've made patch that implements a demo of the latter alternative. It defines a new entry comments.langs in settings, and adjusts setSpellCheckerLanguages in main.js:newWindow. It's worth about 5 lines of code. There no UI here, it relies on manual editing of settings.json.

@apetresc
Copy link
Member

apetresc commented Nov 3, 2021

That's a great point, thank you! Yeah, feel free to post up your initial pull request as a starting point :)

@zorgnac
Copy link
Author

zorgnac commented Nov 12, 2021

Not sure I've done it the expected way.

However, here is pull request #833

@zorgnac
Copy link
Author

zorgnac commented Jan 6, 2022

I've worked on this and added some UI around, namely a context menu in the comment box with option to replace misspelled or add to dictionary.

Shall I close the PR and replace by another one?

@zorgnac
Copy link
Author

zorgnac commented Jan 6, 2022

custom

@zorgnac zorgnac closed this as completed Jan 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants