diff options
Diffstat (limited to 'core/ustring.h')
-rw-r--r-- | core/ustring.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/core/ustring.h b/core/ustring.h index 9ee3c2042c..d00bfa59b5 100644 --- a/core/ustring.h +++ b/core/ustring.h @@ -98,6 +98,7 @@ public: signed char casecmp_to(const String &p_str) const; signed char nocasecmp_to(const String &p_str) const; + signed char naturalnocasecmp_to(const String &p_str) const; const CharType *c_str() const; /* standard size stuff */ @@ -256,6 +257,14 @@ struct NoCaseComparator { } }; +struct NaturalNoCaseComparator { + + bool operator()(const String &p_a, const String &p_b) const { + + return p_a.naturalnocasecmp_to(p_b) < 0; + } +}; + /* end of namespace */ //tool translate |