Updated dictionary

Added new <nospellcheck> tag, to prevent spell-checking of words within.
Prevented spellchecking of anything a) matching a keyword or b) formed from a cardname atom
Replaced ` as LEGENDNAME alternative; I think it's a bug that it's gone


git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@1288 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
coppro
2009-01-03 06:16:02 +00:00
parent 697bfc3e7e
commit ed16dd6864
3 changed files with 37 additions and 32 deletions
+3 -1
View File
@@ -20,8 +20,10 @@ inline size_t spelled_correctly(const String& input, size_t start, size_t end, S
String word = untag(input.substr(start,end-start));
if (word.empty()) return true;
// symbol?
if (in_tag(input,_("<sym"),start,end) != String::npos) {
if (in_tag(input,_("<sym"),start,end) != String::npos ||
in_tag(input,_("<nospellcheck"),start,end) != String::npos) {
// symbols are always spelled correctly
// and <nospellcheck> tags should prevent spellcheck
return true;
}
// run through spellchecker(s)