Fix #258: Dashes to spaces.

This commit is contained in:
Waleed Khan 2014-08-07 12:24:49 -04:00
parent af4d662c54
commit ffc5b59fec

View file

@ -477,6 +477,10 @@ QString CardInfo::simplifyName(const QString &name) {
// Replace Jötun Grunt with Jotun Grunt.
simpleName = simpleName.normalized(QString::NormalizationForm_KD);
// Replace dashes with spaces so that we can say "garruk the veil cursed"
// instead of the unintuitive "garruk the veilcursed".
simpleName = simpleName.replace("-", " ");
simpleName.remove(QRegExp("[^a-zA-Z0-9 ]"));
simpleName = simpleName.toLower();
return simpleName;