summaryrefslogtreecommitdiffstats
path: root/tdecore/tdeglobal.cpp
diff options
context:
space:
mode:
authorMichele Calgaro <[email protected]>2024-09-24 15:01:57 +0900
committerMichele Calgaro <[email protected]>2024-09-24 21:03:43 +0900
commit3d22170e60dfbc9aa756c1a4322a7dbdb0354364 (patch)
tree14f03fe8e715595c6c486cc1ebcd64af1584909b /tdecore/tdeglobal.cpp
parent48dd6d8de2d691c24f56a292aa40454affd73f16 (diff)
downloadtdelibs-3d22170e60dfbc9aa756c1a4322a7dbdb0354364.tar.gz
tdelibs-3d22170e60dfbc9aa756c1a4322a7dbdb0354364.zip
Add kascii* methods previously part of tdepim/libemailfunctions
Signed-off-by: Michele Calgaro <[email protected]>
Diffstat (limited to 'tdecore/tdeglobal.cpp')
-rw-r--r--tdecore/tdeglobal.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/tdecore/tdeglobal.cpp b/tdecore/tdeglobal.cpp
index 09f496034..aeac6f744 100644
--- a/tdecore/tdeglobal.cpp
+++ b/tdecore/tdeglobal.cpp
@@ -282,3 +282,20 @@ int kasciistricmp( const char *str1, const char *str2 )
return *s1 ? res : (*s2 ? -1 : 0);
}
+char* kasciitolower( char *s )
+{
+ if ( !s )
+ return 0;
+ for ( unsigned char *p = (unsigned char *) s; *p; ++p )
+ *p = ( *p >= 'A' && *p <= 'Z' ) ? (*p - 'A' + 'a') : *p;
+ return s;
+}
+
+char* kasciitoupper( char *s )
+{
+ if ( !s )
+ return 0;
+ for ( unsigned char *p = (unsigned char *) s; *p; ++p )
+ *p = ( *p >= 'a' && *p <= 'z' ) ? (*p - 'a' + 'A') : *p;
+ return s;
+}