check_spelling: various improvements

- Use the custom dictionary when checking hyphenated words.
- Add the custom dictionary to the existing dictionary so
  suggestions will include words from the custom dictionary.
- Refactor spell checking functions into wrapper calls.

Removes over 200 false positives.
This commit is contained in:
Campbell Barton
2021-10-06 13:06:49 +11:00
parent f4a13d25a5
commit 937a66e76a
2 changed files with 65 additions and 19 deletions

View File

@ -111,7 +111,7 @@ dict_custom = {
"parameterization",
"parentless",
"passepartout",
"pixelated", "pixelisation",
"pixelate", "pixelated", "pixelisation",
"planarity",
"polytope",
"postprocessed",
@ -422,3 +422,14 @@ dict_ignore = {
"bugprone-suspicious-enum-usage",
"bugprone-use-after-move",
}
# Allow: `un-word`, `re-word` ... etc, in this case only check `word`.
dict_ignore_hyphenated_prefix = {
"de",
"mis",
"non",
"post",
"pre",
"re",
"un",
}