summaryrefslogtreecommitdiffstats
path: root/source/StringUtils.h
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-07-07 16:42:07 +0200
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-07-07 16:42:07 +0200
commit5951bc76ec8fbb188777de66cb965f05446c7f38 (patch)
tree505f8463f2d4ae553f0f7a21d3590f2089f40122 /source/StringUtils.h
parentFixed sprinting in 1.6.1, made speeds available through API; fixed messages containing quotes. (diff)
downloadcuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.tar
cuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.tar.gz
cuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.tar.bz2
cuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.tar.lz
cuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.tar.xz
cuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.tar.zst
cuberite-5951bc76ec8fbb188777de66cb965f05446c7f38.zip
Diffstat (limited to 'source/StringUtils.h')
-rw-r--r--source/StringUtils.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/source/StringUtils.h b/source/StringUtils.h
index be2fe2359..211799e91 100644
--- a/source/StringUtils.h
+++ b/source/StringUtils.h
@@ -40,19 +40,19 @@ extern AStringVector StringSplit(const AString & str, const AString & delim);
extern AStringVector StringSplitAndTrim(const AString & str, const AString & delim);
/// Trime whitespace at both ends of the string
-extern AString TrimString(const AString & str);
+extern AString TrimString(const AString & str); // tolua_export
/// In-place string conversion to uppercase; returns the same string
extern AString & StrToUpper(AString & s);
/// Case-insensitive string comparison; returns 0 if the strings are the same
-extern int NoCaseCompare(const AString & s1, const AString & s2);
+extern int NoCaseCompare(const AString & s1, const AString & s2); // tolua_export
/// Case-insensitive string comparison that returns a rating of equal-ness between [0 - s1.length()]
extern unsigned int RateCompareString(const AString & s1, const AString & s2 );
/// Replaces *each* occurence of iNeedle in iHayStack with iReplaceWith
-extern void ReplaceString(AString & iHayStack, const AString & iNeedle, const AString & iReplaceWith);
+extern void ReplaceString(AString & iHayStack, const AString & iNeedle, const AString & iReplaceWith); // tolua_export
/// Returns the list of all items in the specified directory (files, folders, nix pipes, whatever's there)
extern AStringList GetDirectoryContents(const char * a_Directory);
@@ -67,7 +67,10 @@ extern AString & UTF8ToRawBEUTF16(const char * a_UTF8, size_t a_UTF8Length, AStr
extern AString & CreateHexDump(AString & a_Out, const void * a_Data, int a_Size, int a_BytesPerLine);
/// Returns a copy of a_Message with all quotes and backslashes escaped by a backslash
-extern AString EscapeString(const AString & a_Message);
+extern AString EscapeString(const AString & a_Message); // tolua_export
+
+/// Removes all control codes used by MC for colors and styles
+extern AString StripColorCodes(const AString & a_Message); // tolua_export
// If you have any other string helper functions, declare them here