You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an application where I want to detect if a given word is an acronym. The way I would like to do this is to do a case-sensitive search for the uppercased string in the dict, e.g. given 'json' convert to 'JSON' and do a case-sensitive search for that. However, enchant_pwl_check is lower-casing the word so I may get false positives.
I just looked through the code, and there seem to be 2 ways to handle this:
Add a gboolean normalizeCase flag to the enchant_pwl_check (This would break binary compatibility?)
Expose enchant_pwl_contains in the header file
I'll submit a PR for both of these options soon.
The text was updated successfully, but these errors were encountered:
I agree that exposing enchant_pwl_contains seems the simplest thing to do.
You added a FIXME that it doesn't refresh the word-list. But this is quite easy to work around: first, check with enchant_pwl_check, and if it returns true, then follow up with enchant_pwl_contains (in case it was a false positive).
I'm happy to help land this patch. For starters, please could you get the patch to pass the existing tests, and add some new tests for enchant_pwl_contains?
I have an application where I want to detect if a given word is an acronym. The way I would like to do this is to do a case-sensitive search for the uppercased string in the dict, e.g. given 'json' convert to 'JSON' and do a case-sensitive search for that. However, enchant_pwl_check is lower-casing the word so I may get false positives.
I just looked through the code, and there seem to be 2 ways to handle this:
Add a(This would break binary compatibility?)gboolean normalizeCase
flag to theenchant_pwl_check
enchant_pwl_contains
in the header fileI'll submit a PR for both of these options soon.
The text was updated successfully, but these errors were encountered: