summaryrefslogtreecommitdiffstats
path: root/src/tools/qglobal.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/qglobal.cpp')
-rw-r--r--src/tools/qglobal.cpp92
1 files changed, 46 insertions, 46 deletions
diff --git a/src/tools/qglobal.cpp b/src/tools/qglobal.cpp
index baf6e6f69..f2c92c2e0 100644
--- a/src/tools/qglobal.cpp
+++ b/src/tools/qglobal.cpp
@@ -63,12 +63,12 @@
3.0.5's \c TQT_VERSION is 0x030005.
*/
-const char *qVersion()
+const char *tqVersion()
{
return TQT_VERSION_STR;
}
-bool qSharedBuild()
+bool tqSharedBuild()
{
#ifdef QT_SHARED
return TRUE;
@@ -94,12 +94,12 @@ static bool si_bigEndian;
*wordSize. The \a *bigEndian is set to TRUE if this is a big-endian
machine, or to FALSE if this is a little-endian machine.
- In debug mode, this function calls qFatal() with a message if the
+ In debug mode, this function calls tqFatal() with a message if the
computer is truly weird (i.e. different endianness for 16 bit and
32 bit integers); in release mode it returns FALSE.
*/
-bool qSysInfo( int *wordSize, bool *bigEndian )
+bool tqSysInfo( int *wordSize, bool *bigEndian )
{
#if defined(QT_CHECK_NULL)
Q_ASSERT( wordSize != 0 );
@@ -124,14 +124,14 @@ bool qSysInfo( int *wordSize, bool *bigEndian )
*wordSize != 32 &&
*wordSize != 16 ) { // word size: 16, 32 or 64
#if defined(QT_CHECK_RANGE)
- qFatal( "qSysInfo: Unsupported system word size %d", *wordSize );
+ tqFatal( "qSysInfo: Unsupported system word size %d", *wordSize );
#endif
return FALSE;
}
if ( sizeof(Q_INT8) != 1 || sizeof(Q_INT16) != 2 || sizeof(Q_INT32) != 4 ||
sizeof(Q_ULONG)*8 != si_wordSize || sizeof(float) != 4 || sizeof(double) != 8 ) {
#if defined(QT_CHECK_RANGE)
- qFatal( "qSysInfo: Unsupported system data type size" );
+ tqFatal( "qSysInfo: Unsupported system data type size" );
#endif
return FALSE;
}
@@ -154,7 +154,7 @@ bool qSysInfo( int *wordSize, bool *bigEndian )
if ( be16 != be32 ) { // strange machine!
#if defined(QT_CHECK_RANGE)
- qFatal( "qSysInfo: Inconsistent system byte order" );
+ tqFatal( "qSysInfo: Inconsistent system byte order" );
#endif
return FALSE;
}
@@ -321,7 +321,7 @@ int qWinVersion()
} else if ( osver.dwMinorVersion == 2 ) {
winver = TQt::WV_2003;
} else {
- qWarning("Untested Windows version detected!");
+ tqWarning("Untested Windows version detected!");
winver = TQt::WV_NT_based;
}
}
@@ -346,7 +346,7 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
*****************************************************************************/
/*!
- \fn void qDebug( const char *msg, ... )
+ \fn void tqDebug( const char *msg, ... )
\relates TQApplication
@@ -358,7 +358,7 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
Example:
\code
- qDebug( "my window handle = %x", myWidget->id() );
+ tqDebug( "my window handle = %x", myWidget->id() );
\endcode
Under X11, the text is printed to stderr. Under Windows, the text
@@ -367,15 +367,15 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
\warning The internal buffer is limited to 8196 bytes (including
the '\0'-terminator).
- \warning Passing (const char *)0 as argument to qDebug might lead
+ \warning Passing (const char *)0 as argument to tqDebug might lead
to crashes on certain platforms due to the platforms printf implementation.
- \sa qWarning(), qFatal(), qInstallMsgHandler(),
+ \sa tqWarning(), tqFatal(), qInstallMsgHandler(),
\link debug.html Debugging\endlink
*/
/*!
- \fn void qWarning( const char *msg, ... )
+ \fn void tqWarning( const char *msg, ... )
\relates TQApplication
@@ -390,7 +390,7 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
void f( int c )
{
if ( c > 200 )
- qWarning( "f: bad argument, c == %d", c );
+ tqWarning( "f: bad argument, c == %d", c );
}
\endcode
@@ -400,15 +400,15 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
\warning The internal buffer is limited to 8196 bytes (including
the '\0'-terminator).
- \warning Passing (const char *)0 as argument to qWarning might lead
+ \warning Passing (const char *)0 as argument to tqWarning might lead
to crashes on certain platforms due to the platforms printf implementation.
- \sa qDebug(), qFatal(), qInstallMsgHandler(),
+ \sa tqDebug(), tqFatal(), qInstallMsgHandler(),
\link debug.html Debugging\endlink
*/
/*!
- \fn void qFatal( const char *msg, ... )
+ \fn void tqFatal( const char *msg, ... )
\relates TQApplication
@@ -423,7 +423,7 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
int divide( int a, int b )
{
if ( b == 0 ) // program error
- qFatal( "divide: cannot divide by zero" );
+ tqFatal( "divide: cannot divide by zero" );
return a/b;
}
\endcode
@@ -434,10 +434,10 @@ TQt::WindowsVersion qt_winver = (TQt::WindowsVersion)qWinVersion();
\warning The internal buffer is limited to 8196 bytes (including
the '\0'-terminator).
- \warning Passing (const char *)0 as argument to qFatal might lead
+ \warning Passing (const char *)0 as argument to tqFatal might lead
to crashes on certain platforms due to the platforms printf implementation.
- \sa qDebug(), qWarning(), qInstallMsgHandler(),
+ \sa tqDebug(), tqWarning(), qInstallMsgHandler(),
\link debug.html Debugging\endlink
*/
@@ -465,7 +465,7 @@ static void mac_default_handler( const char *msg )
#endif
-void qDebug( const char *msg, ... )
+void tqDebug( const char *msg, ... )
{
char buf[QT_BUFFER_LENGTH];
va_list ap;
@@ -516,7 +516,7 @@ void debug( const char *msg, ... )
}
}
-void qWarning( const char *msg, ... )
+void tqWarning( const char *msg, ... )
{
char buf[QT_BUFFER_LENGTH];
va_list ap;
@@ -568,7 +568,7 @@ void warning( const char *msg, ... )
}
}
-void qFatal( const char *msg, ... )
+void tqFatal( const char *msg, ... )
{
char buf[QT_BUFFER_LENGTH];
va_list ap;
@@ -646,7 +646,7 @@ void fatal( const char *msg, ... )
This function does nothing when TQt is built with \c QT_NO_DEBUG
defined.
*/
-void qSystemWarning( const char* msg, int code )
+void tqSystemWarning( const char* msg, int code )
{
#ifndef QT_NO_DEBUG
#if defined(Q_OS_WIN32)
@@ -666,7 +666,7 @@ void qSystemWarning( const char* msg, int code )
0,
NULL );
- qWarning( "%s\n\tError code %d - %s", msg, code, TQString::fromUcs2(string).latin1() );
+ tqWarning( "%s\n\tError code %d - %s", msg, code, TQString::fromUcs2(string).latin1() );
}, {
FormatMessageA( FORMAT_MESSAGE_ALLOCATE_BUFFER|FORMAT_MESSAGE_FROM_SYSTEM,
NULL,
@@ -676,14 +676,14 @@ void qSystemWarning( const char* msg, int code )
0,
NULL );
- qWarning( "%s\n\tError code %d - %s", msg, code, (const char*)string );
+ tqWarning( "%s\n\tError code %d - %s", msg, code, (const char*)string );
} );
LocalFree( (HLOCAL)string );
#else
if ( code != -1 )
- qWarning( "%s\n\tError code %d - %s", msg, code, strerror( code ) );
+ tqWarning( "%s\n\tError code %d - %s", msg, code, strerror( code ) );
else
- qWarning( "%s", msg );
+ tqWarning( "%s", msg );
#endif
#else
Q_UNUSED( msg );
@@ -719,12 +719,12 @@ void qSystemWarning( const char* msg, int code )
\endcode
If \c b is zero, the Q_ASSERT statement will output the following
- message using the qWarning() function:
+ message using the tqWarning() function:
\code
ASSERT: "b != 0" in div.cpp (9)
\endcode
- \sa qWarning(), \link debug.html Debugging\endlink
+ \sa tqWarning(), \link debug.html Debugging\endlink
*/
@@ -748,7 +748,7 @@ void qSystemWarning( const char* msg, int code )
TQ_CHECK_PTR( a );
\endcode
- \sa qWarning(), \link debug.html Debugging\endlink
+ \sa tqWarning(), \link debug.html Debugging\endlink
*/
@@ -757,14 +757,14 @@ void qSystemWarning( const char* msg, int code )
//
#if (TQT_VERSION-0 >= 0x040000)
#if defined(Q_CC_GNU)
-#warning "Change TQ_CHECK_PTR to '{if ((p)==0) qt_check_pointer(__FILE__,__LINE__);}'"
-#warning "No need for qt_check_pointer() to return a value - make it void!"
+#warning "Change TQ_CHECK_PTR to '{if ((p)==0) tqt_check_pointer(__FILE__,__LINE__);}'"
+#warning "No need for tqt_check_pointer() to return a value - make it void!"
#endif
#endif
-bool qt_check_pointer( bool c, const char *n, int l )
+bool tqt_check_pointer( bool c, const char *n, int l )
{
if ( c )
- qWarning( "In file %s, line %d: Out of memory", n, l );
+ tqWarning( "In file %s, line %d: Out of memory", n, l );
return TRUE;
}
@@ -775,7 +775,7 @@ static bool firstObsoleteWarning(const char *obj, const char *oldfunc )
if ( !obsoleteDict ) { // first time func is called
obsoleteDict = new TQAsciiDict<int>;
#if defined(QT_DEBUG)
- qDebug(
+ tqDebug(
"You are using obsolete functions in the TQt library. Call the function\n"
"qSuppressObsoleteWarnings() to suppress obsolete warnings.\n"
);
@@ -793,44 +793,44 @@ static bool firstObsoleteWarning(const char *obj, const char *oldfunc )
static bool suppressObsolete = FALSE;
-void qSuppressObsoleteWarnings( bool suppress )
+void tqSuppressObsoleteWarnings( bool suppress )
{
suppressObsolete = suppress;
}
-void qObsolete( const char *obj, const char *oldfunc, const char *newfunc )
+void tqObsolete( const char *obj, const char *oldfunc, const char *newfunc )
{
if ( suppressObsolete )
return;
if ( !firstObsoleteWarning(obj, oldfunc) )
return;
if ( obj )
- qDebug( "%s::%s: This function is obsolete, use %s instead.",
+ tqDebug( "%s::%s: This function is obsolete, use %s instead.",
obj, oldfunc, newfunc );
else
- qDebug( "%s: This function is obsolete, use %s instead.",
+ tqDebug( "%s: This function is obsolete, use %s instead.",
oldfunc, newfunc );
}
-void qObsolete( const char *obj, const char *oldfunc )
+void tqObsolete( const char *obj, const char *oldfunc )
{
if ( suppressObsolete )
return;
if ( !firstObsoleteWarning(obj, oldfunc) )
return;
if ( obj )
- qDebug( "%s::%s: This function is obsolete.", obj, oldfunc );
+ tqDebug( "%s::%s: This function is obsolete.", obj, oldfunc );
else
- qDebug( "%s: This function is obsolete.", oldfunc );
+ tqDebug( "%s: This function is obsolete.", oldfunc );
}
-void qObsolete( const char *message )
+void tqObsolete( const char *message )
{
if ( suppressObsolete )
return;
if ( !firstObsoleteWarning( "TQt", message) )
return;
- qDebug( "%s", message );
+ tqDebug( "%s", message );
}
@@ -886,7 +886,7 @@ void qObsolete( const char *message )
}
\endcode
- \sa qDebug(), qWarning(), qFatal(), \link debug.html Debugging\endlink
+ \sa tqDebug(), tqWarning(), tqFatal(), \link debug.html Debugging\endlink
*/
TQtMsgHandler qInstallMsgHandler( TQtMsgHandler h )