diff options
Diffstat (limited to 'scintilla/src/CaseConvert.cxx')
-rw-r--r-- | scintilla/src/CaseConvert.cxx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/scintilla/src/CaseConvert.cxx b/scintilla/src/CaseConvert.cxx index b4c8bcf..66185ba 100644 --- a/scintilla/src/CaseConvert.cxx +++ b/scintilla/src/CaseConvert.cxx @@ -11,6 +11,7 @@ #include <cstring>
#include <stdexcept>
+#include <string>
#include <vector>
#include <algorithm>
@@ -630,6 +631,14 @@ size_t CaseConvertString(char *converted, size_t sizeConverted, const char *mixe return pCaseConv->CaseConvertString(converted, sizeConverted, mixed, lenMixed);
}
+std::string CaseConvertString(const std::string &s, enum CaseConversion conversion) {
+ std::string retMapped(s.length() * maxExpansionCaseConversion, 0);
+ size_t lenMapped = CaseConvertString(&retMapped[0], retMapped.length(), s.c_str(), s.length(),
+ conversion);
+ retMapped.resize(lenMapped);
+ return retMapped;
+}
+
#ifdef SCI_NAMESPACE
}
#endif
|