Branch: refs/heads/master Author: Enrico Tröger enrico.troeger@uvena.de Committer: Enrico Tröger enrico.troeger@uvena.de Date: Wed, 28 Dec 2016 21:37:33 UTC Commit: 446a0bf57ad42f9edcd441315eb492d50e73636a https://github.com/geany/geany-plugins/commit/446a0bf57ad42f9edcd441315eb492...
Log Message: ----------- SpellCheck: Reset wordchars only if we modified it before
Modified Paths: -------------- spellcheck/src/speller.c
Modified: spellcheck/src/speller.c 14 lines changed, 7 insertions(+), 7 deletions(-) =================================================================== @@ -256,15 +256,15 @@ gint sc_speller_process_line(GeanyDocument *doc, gint line_number) g_free(word); }
- if (underscore_in_wordchars != NULL) + if (wordchars_modified) { - /* re-add underscore if we removed it above */ - *underscore_in_wordchars = '_'; + if (underscore_in_wordchars != NULL) + /* re-add underscore if we removed it above */ + *underscore_in_wordchars = '_'; + /* reset wordchars for the current document */ + wordchars[wordchars_len] = '\0'; + scintilla_send_message(doc->editor->sci, SCI_SETWORDCHARS, 0, (sptr_t)wordchars); } - /* reset wordchars for the current document */ - wordchars[wordchars_len] = '\0'; - scintilla_send_message(doc->editor->sci, SCI_SETWORDCHARS, 0, (sptr_t)wordchars); - g_free(wordchars); return suggestions_found; }
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
plugins-commits@lists.geany.org