diff options
Diffstat (limited to 'tdecore')
-rw-r--r-- | tdecore/CMakeLists.txt | 2 | ||||
-rw-r--r-- | tdecore/kdemacros.h | 1 | ||||
-rw-r--r-- | tdecore/kglobalaccel_x11.cpp | 2 | ||||
-rw-r--r-- | tdecore/libtdecore.nmcheck | 2 | ||||
-rw-r--r-- | tdecore/tdeapplication.h | 2 | ||||
-rw-r--r-- | tdecore/tdeglobal.cpp | 17 | ||||
-rw-r--r-- | tdecore/tdeglobal.h | 20 | ||||
-rw-r--r-- | tdecore/tdemacros.h.cmake | 8 | ||||
-rw-r--r-- | tdecore/tdemacros.h.in | 4 |
9 files changed, 46 insertions, 12 deletions
diff --git a/tdecore/CMakeLists.txt b/tdecore/CMakeLists.txt index 7fb7cdccf..24348088e 100644 --- a/tdecore/CMakeLists.txt +++ b/tdecore/CMakeLists.txt @@ -73,7 +73,7 @@ install( FILES kmanagerselection.h kmountpoint.h kuser.h klockfile.h kidna.h ktempdir.h kshell.h fixx11h.h kxerrorhandler.h tdelibs_export.h kde_file.h ktimezones.h - ${CMAKE_CURRENT_BINARY_DIR}/tdemacros.h kdemacros.h + ${CMAKE_CURRENT_BINARY_DIR}/tdemacros.h DESTINATION ${INCLUDE_INSTALL_DIR} ) diff --git a/tdecore/kdemacros.h b/tdecore/kdemacros.h deleted file mode 100644 index 73808c60d..000000000 --- a/tdecore/kdemacros.h +++ /dev/null @@ -1 +0,0 @@ -#include <tdemacros.h> diff --git a/tdecore/kglobalaccel_x11.cpp b/tdecore/kglobalaccel_x11.cpp index d76b8cdac..41e58b959 100644 --- a/tdecore/kglobalaccel_x11.cpp +++ b/tdecore/kglobalaccel_x11.cpp @@ -30,7 +30,7 @@ #include <tqregexp.h> #include <tqwidget.h> #include <tqmetaobject.h> -#include <tqucomextra_p.h> +#include <private/tqucomextra_p.h> #include <tdeapplication.h> #include <kdebug.h> #include <kkeynative.h> diff --git a/tdecore/libtdecore.nmcheck b/tdecore/libtdecore.nmcheck index 7c017a6e4..92ec3ff8f 100644 --- a/tdecore/libtdecore.nmcheck +++ b/tdecore/libtdecore.nmcheck @@ -44,6 +44,8 @@ operator>> operator<< qt_qclipboard_bailout_hack kasciistricmp +kasciitolower +kasciitoupper # from libtldl lt_dl* diff --git a/tdecore/tdeapplication.h b/tdecore/tdeapplication.h index f90e8a42b..7a3dff0cf 100644 --- a/tdecore/tdeapplication.h +++ b/tdecore/tdeapplication.h @@ -30,8 +30,6 @@ class KCharsets; class DCOPClient; class DCOPObject; -#include <tqtglobaldefines.h> - typedef unsigned long Atom; #if !defined(TQ_WS_X11) typedef void Display; 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; +} diff --git a/tdecore/tdeglobal.h b/tdecore/tdeglobal.h index 1269c36a9..d604a4244 100644 --- a/tdecore/tdeglobal.h +++ b/tdecore/tdeglobal.h @@ -234,7 +234,25 @@ inline const T& kClamp( const T& x, const T& low, const T& high ) * tqstricmp fails with e.g. the Turkish locale where 'I'.lower() != 'i' * @since 3.4 */ -int TDECORE_EXPORT kasciistricmp( const char *str1, const char *str2 ); +TDECORE_EXPORT int kasciistricmp( const char *str1, const char *str2 ); + +/** + Locale-independent function to convert ASCII strings to lower case ASCII + strings. This means that it affects @em only the ASCII characters A-Z. + + @param str pointer to the string which should be converted to lower case + @return pointer to the converted string (same as @a str) +*/ +TDECORE_EXPORT char* kasciitolower( char *str ); + +/** + Locale-independent function to convert ASCII strings to upper case ASCII + strings. This means that it affects @em only the ASCII characters a-z. + + @param str pointer to the string which should be converted to upper case + @return pointer to the converted string (same as @a str) +*/ +TDECORE_EXPORT char* kasciitoupper( char *str ); /** diff --git a/tdecore/tdemacros.h.cmake b/tdecore/tdemacros.h.cmake index b8d5abd43..34c945872 100644 --- a/tdecore/tdemacros.h.cmake +++ b/tdecore/tdemacros.h.cmake @@ -1,5 +1,5 @@ -/* This file is part of the KDE libraries - Copyright (c) 2002-2003 KDE Team +/* This file is part of the TDE libraries + Copyright (c) 2002-2003 TDE Team This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public @@ -22,7 +22,7 @@ /* Set by configure */ #cmakedefine __TDE_HAVE_TDEHWLIB 1 -#cmakedefine __KDE_HAVE_GCC_VISIBILITY 1 +#cmakedefine __TDE_HAVE_GCC_VISIBILITY 1 /** * The TDE_NO_EXPORT macro marks the symbol of the given variable @@ -38,7 +38,7 @@ * \end */ -#ifdef __KDE_HAVE_GCC_VISIBILITY +#ifdef __TDE_HAVE_GCC_VISIBILITY #define TDE_NO_EXPORT __attribute__ ((visibility("hidden"))) #define TDE_EXPORT __attribute__ ((visibility("default"))) #elif defined(TQ_WS_WIN) diff --git a/tdecore/tdemacros.h.in b/tdecore/tdemacros.h.in index 721b6849b..9df1a77ab 100644 --- a/tdecore/tdemacros.h.in +++ b/tdecore/tdemacros.h.in @@ -21,7 +21,7 @@ #define _TDE_MACROS_H_ /* Set by configure */ -#undef __KDE_HAVE_GCC_VISIBILITY +#undef __TDE_HAVE_GCC_VISIBILITY /** * The TDE_NO_EXPORT macro marks the symbol of the given variable @@ -37,7 +37,7 @@ * \end */ -#ifdef __KDE_HAVE_GCC_VISIBILITY +#ifdef __TDE_HAVE_GCC_VISIBILITY #define TDE_NO_EXPORT __attribute__ ((visibility("hidden"))) #define TDE_EXPORT __attribute__ ((visibility("default"))) #elif defined(TQ_WS_WIN) |