Rename obsolete tq methods to standard names

pull/1/head
Timothy Pearson 13 years ago
parent f91149819b
commit 2dd6d32bd8

@ -132,7 +132,7 @@
/* define this if you are on a big endian machine */ /* define this if you are on a big endian machine */
/* #undef BIG_ENDIAN_MACHINE_BYTE_ORDER */ /* #undef BIG_ENDIAN_MACHINE_BYTE_ORDER */
/* define this if you want to use the tqunicode-local 8bit charset translation */ /* define this if you want to use the unicode-local 8bit charset translation */
/* #undef COMPILE_USE_LOCAL_8BIT */ /* #undef COMPILE_USE_LOCAL_8BIT */
/* define this if you want to disable the inter-process communication support */ /* define this if you want to disable the inter-process communication support */

@ -236,18 +236,18 @@ inline unsigned int kvi_hash_hash(const TQString &szKey,bool bCaseSensitive)
if(!p)return 0; if(!p)return 0;
if(bCaseSensitive) if(bCaseSensitive)
{ {
while(p->tqunicode()) while(p->unicode())
{ {
uResult += p->tqunicode(); uResult += p->unicode();
p++; p++;
} }
} else { } else {
while(p->tqunicode()) while(p->unicode())
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
uResult += p->toLower().tqunicode(); uResult += p->toLower().unicode();
#else #else
uResult += p->lower().tqunicode(); uResult += p->lower().unicode();
#endif #endif
p++; p++;
} }

@ -54,8 +54,8 @@ namespace KviTQString
bool equalCSN(const TQString &sz1,const TQString &sz2,unsigned int len) bool equalCSN(const TQString &sz1,const TQString &sz2,unsigned int len)
{ {
if(len == 0)return true; // assume equal if(len == 0)return true; // assume equal
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
unsigned int lmin = MY_MIN(sz1.length(),sz2.length()); unsigned int lmin = MY_MIN(sz1.length(),sz2.length());
if(lmin < len)return false; if(lmin < len)return false;
const TQChar * c1e = c1 + len; const TQChar * c1e = c1 + len;
@ -64,7 +64,7 @@ namespace KviTQString
while(c1 < c1e) while(c1 < c1e)
{ {
if(c1->tqunicode() != c2->tqunicode())return false; if(c1->unicode() != c2->unicode())return false;
c1++; c1++;
c2++; c2++;
} }
@ -74,8 +74,8 @@ namespace KviTQString
bool equalCIN(const TQString &sz1,const TQString &sz2,unsigned int len) bool equalCIN(const TQString &sz1,const TQString &sz2,unsigned int len)
{ {
if(len == 0)return true; // assume equal if(len == 0)return true; // assume equal
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
unsigned int lmin = MY_MIN(sz1.length(),sz2.length()); unsigned int lmin = MY_MIN(sz1.length(),sz2.length());
if(lmin < len)return false; if(lmin < len)return false;
const TQChar * c1e = c1 + len; const TQChar * c1e = c1 + len;
@ -85,9 +85,9 @@ namespace KviTQString
while(c1 < c1e) while(c1 < c1e)
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c1->toLower().tqunicode() != c2->toLower().tqunicode())return false; if(c1->toLower().unicode() != c2->toLower().unicode())return false;
#else #else
if(c1->lower().tqunicode() != c2->lower().tqunicode())return false; if(c1->lower().unicode() != c2->lower().unicode())return false;
#endif #endif
c1++; c1++;
c2++; c2++;
@ -98,7 +98,7 @@ namespace KviTQString
bool equalCSN(const TQString &sz1,const char * sz2,unsigned int len) bool equalCSN(const TQString &sz1,const char * sz2,unsigned int len)
{ {
if(len == 0)return true; // assume equal if(len == 0)return true; // assume equal
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
if(sz1.length() < len)return false; if(sz1.length() < len)return false;
const TQChar * c1e = c1 + len; const TQChar * c1e = c1 + len;
@ -107,7 +107,7 @@ namespace KviTQString
while((c1 < c1e) && (*sz2)) while((c1 < c1e) && (*sz2))
{ {
if(c1->tqunicode() != *sz2)return false; if(c1->unicode() != *sz2)return false;
c1++; c1++;
sz2++; sz2++;
} }
@ -117,7 +117,7 @@ namespace KviTQString
bool equalCIN(const TQString &sz1,const char * sz2,unsigned int len) bool equalCIN(const TQString &sz1,const char * sz2,unsigned int len)
{ {
if(len == 0)return true; // assume equal if(len == 0)return true; // assume equal
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
if(sz1.length() < len)return false; if(sz1.length() < len)return false;
const TQChar * c1e = c1 + len; const TQChar * c1e = c1 + len;
@ -127,9 +127,9 @@ namespace KviTQString
while((c1 < c1e) && (*sz2)) while((c1 < c1e) && (*sz2))
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c1->toLower().tqunicode() != tolower(*sz2))return false; if(c1->toLower().unicode() != tolower(*sz2))return false;
#else #else
if(c1->lower().tqunicode() != tolower(*sz2))return false; if(c1->lower().unicode() != tolower(*sz2))return false;
#endif #endif
c1++; c1++;
sz2++; sz2++;
@ -141,19 +141,19 @@ namespace KviTQString
bool equalCIN(const TQString &sz1,const TQChar *sz2,unsigned int len) bool equalCIN(const TQString &sz1,const TQChar *sz2,unsigned int len)
{ {
if(len == 0)return true; // assume equal if(len == 0)return true; // assume equal
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
if(sz1.length() < len)return false; if(sz1.length() < len)return false;
const TQChar * c1e = c1 + len; const TQChar * c1e = c1 + len;
if(!sz2)return !c1; if(!sz2)return !c1;
if(!c1)return !(sz2->tqunicode()); if(!c1)return !(sz2->unicode());
while((c1 < c1e) && (sz2->tqunicode())) while((c1 < c1e) && (sz2->unicode()))
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c1->toLower().tqunicode() != sz2->toLower().tqunicode())return false; if(c1->toLower().unicode() != sz2->toLower().unicode())return false;
#else #else
if(c1->lower().tqunicode() != sz2->lower().tqunicode())return false; if(c1->lower().unicode() != sz2->lower().unicode())return false;
#endif #endif
c1++; c1++;
sz2++; sz2++;
@ -189,15 +189,15 @@ namespace KviTQString
{ {
if(sz1.length() != sz2.length())return false; if(sz1.length() != sz2.length())return false;
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
if(!c1 || !c2)return (c1 == c2); if(!c1 || !c2)return (c1 == c2);
while(c1 < c1e) while(c1 < c1e)
{ {
if(c1->tqunicode() != c2->tqunicode())return false; if(c1->unicode() != c2->unicode())return false;
c1++; c1++;
c2++; c2++;
} }
@ -208,8 +208,8 @@ namespace KviTQString
{ {
if(sz1.length() != sz2.length())return false; if(sz1.length() != sz2.length())return false;
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
if(!c1 || !c2)return (c1 == c2); if(!c1 || !c2)return (c1 == c2);
@ -217,9 +217,9 @@ namespace KviTQString
while(c1 < c1e) while(c1 < c1e)
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c1->toLower().tqunicode() != c2->toLower().tqunicode())return false; if(c1->toLower().unicode() != c2->toLower().unicode())return false;
#else #else
if(c1->lower().tqunicode() != c2->lower().tqunicode())return false; if(c1->lower().unicode() != c2->lower().unicode())return false;
#endif #endif
c1++; c1++;
c2++; c2++;
@ -230,35 +230,35 @@ namespace KviTQString
// sz2 is assumed to be null terminated, sz1 is not! // sz2 is assumed to be null terminated, sz1 is not!
bool equalCI(const TQString &sz1,const TQChar *sz2) bool equalCI(const TQString &sz1,const TQChar *sz2)
{ {
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
if(!c1 || !sz2)return (c1 == sz2); if(!c1 || !sz2)return (c1 == sz2);
while(c1 < c1e) while(c1 < c1e)
{ {
if(!sz2->tqunicode())return false; // sz1 has at least another character if(!sz2->unicode())return false; // sz1 has at least another character
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c1->toLower().tqunicode() != sz2->toLower().tqunicode())return false; if(c1->toLower().unicode() != sz2->toLower().unicode())return false;
#else #else
if(c1->lower().tqunicode() != sz2->lower().tqunicode())return false; if(c1->lower().unicode() != sz2->lower().unicode())return false;
#endif #endif
c1++; c1++;
sz2++; sz2++;
} }
return (c1 == c1e) && (!sz2->tqunicode()); return (c1 == c1e) && (!sz2->unicode());
} }
bool equalCS(const TQString &sz1,const char * sz2) bool equalCS(const TQString &sz1,const char * sz2)
{ {
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
if(!c1)return !sz2; if(!c1)return !sz2;
while((c1 < c1e) && (*sz2)) while((c1 < c1e) && (*sz2))
{ {
if(c1->tqunicode() != *sz2)return false; if(c1->unicode() != *sz2)return false;
c1++; c1++;
sz2++; sz2++;
} }
@ -267,7 +267,7 @@ namespace KviTQString
bool equalCI(const TQString &sz1,const char * sz2) bool equalCI(const TQString &sz1,const char * sz2)
{ {
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
if(!c1)return !sz2; if(!c1)return !sz2;
@ -275,9 +275,9 @@ namespace KviTQString
while((c1 < c1e) && (*sz2)) while((c1 < c1e) && (*sz2))
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c1->toLower().tqunicode() != tolower(*sz2))return false; if(c1->toLower().unicode() != tolower(*sz2))return false;
#else #else
if(c1->lower().tqunicode() != tolower(*sz2))return false; if(c1->lower().unicode() != tolower(*sz2))return false;
#endif #endif
c1++; c1++;
sz2++; sz2++;
@ -287,8 +287,8 @@ namespace KviTQString
int cmpCS(const TQString &sz1,const TQString &sz2) int cmpCS(const TQString &sz1,const TQString &sz2)
{ {
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
const TQChar * c2e = c2 + sz2.length(); const TQChar * c2e = c2 + sz2.length();
@ -304,12 +304,12 @@ namespace KviTQString
{ {
if(c1 >= c1e) if(c1 >= c1e)
{ {
if(c2 < c2e)return /* 0 */ - (c2->tqunicode()); if(c2 < c2e)return /* 0 */ - (c2->unicode());
return 0; return 0;
} }
if(c2 >= c2e)return c1->tqunicode() /* - 0 */; if(c2 >= c2e)return c1->unicode() /* - 0 */;
int diff = c1->tqunicode() - c2->tqunicode(); int diff = c1->unicode() - c2->unicode();
if(diff)return diff; if(diff)return diff;
c1++; c1++;
@ -321,8 +321,8 @@ namespace KviTQString
int cmpCI(const TQString &sz1,const TQString &sz2) int cmpCI(const TQString &sz1,const TQString &sz2)
{ {
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
const TQChar * c1e = c1 + sz1.length(); const TQChar * c1e = c1 + sz1.length();
const TQChar * c2e = c2 + sz2.length(); const TQChar * c2e = c2 + sz2.length();
@ -338,22 +338,22 @@ namespace KviTQString
if(c1 >= c1e) if(c1 >= c1e)
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c2 < c2e)return /* 0 */ - (c2->toLower().tqunicode()); if(c2 < c2e)return /* 0 */ - (c2->toLower().unicode());
#else #else
if(c2 < c2e)return /* 0 */ - (c2->lower().tqunicode()); if(c2 < c2e)return /* 0 */ - (c2->lower().unicode());
#endif #endif
return 0; return 0;
} }
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(c2 >= c2e)return c1->toLower().tqunicode() /* - 0 */; if(c2 >= c2e)return c1->toLower().unicode() /* - 0 */;
#else #else
if(c2 >= c2e)return c1->lower().tqunicode() /* - 0 */; if(c2 >= c2e)return c1->lower().unicode() /* - 0 */;
#endif #endif
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
int diff = c1->toLower().tqunicode() - c2->toLower().tqunicode(); int diff = c1->toLower().unicode() - c2->toLower().unicode();
#else #else
int diff = c1->lower().tqunicode() - c2->lower().tqunicode(); int diff = c1->lower().unicode() - c2->lower().unicode();
#endif #endif
if(diff)return diff; if(diff)return diff;
@ -370,8 +370,8 @@ namespace KviTQString
unsigned int l1 = MY_MIN(len,sz1.length()); unsigned int l1 = MY_MIN(len,sz1.length());
unsigned int l = MY_MIN(l1,sz2.length()); // FIXME: THIS IS NOT OK unsigned int l = MY_MIN(l1,sz2.length()); // FIXME: THIS IS NOT OK
const TQChar * c1 = sz1.tqunicode(); const TQChar * c1 = sz1.unicode();
const TQChar * c2 = sz2.tqunicode(); const TQChar * c2 = sz2.unicode();
const TQChar * c1e = c1 + l; const TQChar * c1e = c1 + l;
if(!c1) if(!c1)
@ -384,9 +384,9 @@ namespace KviTQString
int diff = 0; int diff = 0;
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
while((c1 < c1e) && !(diff = (c1->toLower().tqunicode() - c2->toLower().tqunicode()))) while((c1 < c1e) && !(diff = (c1->toLower().unicode() - c2->toLower().unicode())))
#else #else
while((c1 < c1e) && !(diff = (c1->lower().tqunicode() - c2->lower().tqunicode()))) while((c1 < c1e) && !(diff = (c1->lower().unicode() - c2->lower().unicode())))
#endif #endif
{ {
c1++; c1++;
@ -533,7 +533,7 @@ namespace KviTQString
} }
TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * allocsize); TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * allocsize);
//TQChar * p = (TQChar *)s.tqunicode(); //TQChar * p = (TQChar *)s.unicode();
char *argString; char *argString;
long argValue; long argValue;
@ -561,12 +561,12 @@ namespace KviTQString
} }
for(; fmt->tqunicode() ; ++fmt) for(; fmt->unicode() ; ++fmt)
{ {
if(reallen == allocsize)INCREMENT_MEM if(reallen == allocsize)INCREMENT_MEM
//copy up to a '%' //copy up to a '%'
if(fmt->tqunicode() != '%') if(fmt->unicode() != '%')
{ {
*p++ = *fmt; *p++ = *fmt;
reallen++; reallen++;
@ -574,7 +574,7 @@ namespace KviTQString
} }
++fmt; //skip this '%' ++fmt; //skip this '%'
switch(fmt->tqunicode()) switch(fmt->unicode())
{ {
case 's': // char * string case 's': // char * string
{ {
@ -583,7 +583,7 @@ namespace KviTQString
TQString str(argString); TQString str(argString);
if(str.isEmpty())continue; if(str.isEmpty())continue;
int len = str.length(); int len = str.length();
const TQChar * ch = str.tqunicode(); const TQChar * ch = str.unicode();
if(!ch)continue; if(!ch)continue;
if((allocsize - reallen) < len)INCREMENT_MEM_BY(len) if((allocsize - reallen) < len)INCREMENT_MEM_BY(len)
while(len--)*p++ = *ch++; while(len--)*p++ = *ch++;
@ -606,7 +606,7 @@ namespace KviTQString
if(!str)continue; if(!str)continue;
if(str->isEmpty())continue; if(str->isEmpty())continue;
int len = str->length(); int len = str->length();
const TQChar * ch = str->tqunicode(); const TQChar * ch = str->unicode();
if(!ch)continue; if(!ch)continue;
if((allocsize - reallen) < len)INCREMENT_MEM_BY(len) if((allocsize - reallen) < len)INCREMENT_MEM_BY(len)
while(len--)*p++ = *ch++; while(len--)*p++ = *ch++;
@ -721,7 +721,7 @@ namespace KviTQString
{ {
*p++ = '%'; //write it *p++ = '%'; //write it
reallen++; reallen++;
if(fmt->tqunicode()) if(fmt->unicode())
{ {
if(reallen == allocsize)INCREMENT_MEM if(reallen == allocsize)INCREMENT_MEM
*p++ = *fmt; *p++ = *fmt;
@ -789,21 +789,21 @@ namespace KviTQString
const TQChar * m2 = (const TQChar *)szM2.ucs2(); const TQChar * m2 = (const TQChar *)szM2.ucs2();
#endif #endif
if(!(m1 && m2 && (m1->tqunicode())))return false; if(!(m1 && m2 && (m1->unicode())))return false;
const TQChar * savePos1 = 0; const TQChar * savePos1 = 0;
const TQChar * savePos2 = m2; const TQChar * savePos2 = m2;
while(m1->tqunicode()) while(m1->unicode())
{ {
//loop managed by m1 (initially first mask) //loop managed by m1 (initially first mask)
if(m1->tqunicode()=='*') if(m1->unicode()=='*')
{ {
//Found a wildcard in m1 //Found a wildcard in m1
savePos1 = ++m1; //move to the next char and save the position...this is our jolly savePos1 = ++m1; //move to the next char and save the position...this is our jolly
if(!savePos1->tqunicode())return true; //last was a wildcard , matches everything ahead... if(!savePos1->unicode())return true; //last was a wildcard , matches everything ahead...
savePos2 = m2+1; //next return state for the second string savePos2 = m2+1; //next return state for the second string
continue; //and return continue; //and return
} }
if(!m2->tqunicode())return false; //m2 finished and we had something to match here! if(!m2->unicode())return false; //m2 finished and we had something to match here!
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
if(m1->toLower()==m2->toLower()) if(m1->toLower()==m2->toLower())
#else #else
@ -813,7 +813,7 @@ namespace KviTQString
//chars matched //chars matched
m1++; //Go ahead in the two strings m1++; //Go ahead in the two strings
m2++; // m2++; //
if((!(m1->tqunicode())) && m2->tqunicode() && savePos1) if((!(m1->unicode())) && m2->unicode() && savePos1)
{ {
//m1 finished , but m2 not yet and we have a savePosition for m1 (there was a wildcard)... //m1 finished , but m2 not yet and we have a savePosition for m1 (there was a wildcard)...
//retry matching the string following the * from the savePos2 (one char ahead last time) //retry matching the string following the * from the savePos2 (one char ahead last time)
@ -822,7 +822,7 @@ namespace KviTQString
savePos2++; //next savePos2 will be next char savePos2++; //next savePos2 will be next char
} }
} else { } else {
if(m2->tqunicode() == '*') if(m2->unicode() == '*')
{ {
//A wlidcard in the second string //A wlidcard in the second string
//Invert the game : mask1 <-> mask2 //Invert the game : mask1 <-> mask2
@ -835,11 +835,11 @@ namespace KviTQString
continue; //...and again continue; //...and again
} }
// m1 != m2 , m1 != * , m2 != * // m1 != m2 , m1 != * , m2 != *
if((m1->tqunicode() == '?') || (m2->tqunicode() == '?')) if((m1->unicode() == '?') || (m2->unicode() == '?'))
{ {
m1++; m1++;
m2++; m2++;
if((!(m1->tqunicode())) && m2->tqunicode() && savePos1) if((!(m1->unicode())) && m2->unicode() && savePos1)
{ {
//m1 finished , but m2 not yet and we have a savePosition for m1 (there was a wildcard)... //m1 finished , but m2 not yet and we have a savePosition for m1 (there was a wildcard)...
//retry matching the string following the * from the savePos2 (one char ahead last time) //retry matching the string following the * from the savePos2 (one char ahead last time)
@ -858,7 +858,7 @@ namespace KviTQString
} }
} }
} }
return (!(m2->tqunicode())); //m1 surely finished , so for the match , m2 must be finished too return (!(m2->unicode())); //m1 surely finished , so for the match , m2 must be finished too
} }
bool matchStringCI(const TQString &szExp,const TQString &szStr,bool bIsRegExp,bool bExact) bool matchStringCI(const TQString &szExp,const TQString &szStr,bool bIsRegExp,bool bExact)
@ -870,9 +870,9 @@ namespace KviTQString
TQChar* ptr=(TQChar*)szExp.ucs2(); TQChar* ptr=(TQChar*)szExp.ucs2();
#endif #endif
if(!ptr) return 0; if(!ptr) return 0;
while(ptr->tqunicode()) while(ptr->unicode())
{ {
if((ptr->tqunicode()=='[') || (ptr->tqunicode()==']')) if((ptr->unicode()=='[') || (ptr->unicode()==']'))
{ {
szWildcard.append("["); szWildcard.append("[");
szWildcard.append(*ptr); szWildcard.append(*ptr);
@ -904,9 +904,9 @@ namespace KviTQString
TQChar* ptr=(TQChar*)szExp.ucs2(); TQChar* ptr=(TQChar*)szExp.ucs2();
#endif #endif
if(!ptr) return 0; if(!ptr) return 0;
while(ptr->tqunicode()) while(ptr->unicode())
{ {
if((ptr->tqunicode()=='[')) // <-- hum ? if((ptr->unicode()=='[')) // <-- hum ?
{ {
szWildcard.append("["); szWildcard.append("[");
szWildcard.append(*ptr); szWildcard.append(*ptr);
@ -1043,7 +1043,7 @@ namespace KviTQString
} }
TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * szSrc.length()); TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * szSrc.length());
TQChar * b = buffer; TQChar * b = buffer;
unsigned short us = c->tqunicode(); unsigned short us = c->unicode();
while(us) while(us)
{ {
if(us < 256) if(us < 256)
@ -1052,7 +1052,7 @@ namespace KviTQString
*b = *c; *b = *c;
c++; c++;
b++; b++;
us = c->tqunicode(); us = c->unicode();
} }
TQString ret(buffer,szSrc.length()); TQString ret(buffer,szSrc.length());
kvi_free(buffer); kvi_free(buffer);
@ -1069,7 +1069,7 @@ namespace KviTQString
} }
TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * szSrc.length()); TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * szSrc.length());
TQChar * b = buffer; TQChar * b = buffer;
unsigned short us = c->tqunicode(); unsigned short us = c->unicode();
while(us) while(us)
{ {
if(us < 256) if(us < 256)
@ -1079,7 +1079,7 @@ namespace KviTQString
*b = *c; *b = *c;
c++; c++;
b++; b++;
us = c->tqunicode(); us = c->unicode();
} }
TQString ret(buffer,szSrc.length()); TQString ret(buffer,szSrc.length());
kvi_free(buffer); kvi_free(buffer);

@ -109,7 +109,7 @@ kvi_wslen_t kvi_wstrlen(const kvi_wchar_t * str)
if(pString->length() > 0) \ if(pString->length() > 0) \
{ \ { \
if(len <= ((int)(pString->length())))return (-1); \ if(len <= ((int)(pString->length())))return (-1); \
_WSTRING_WMEMCPY(p,pString->tqunicode(),pString->length()); \ _WSTRING_WMEMCPY(p,pString->unicode(),pString->length()); \
p += pString->length(); \ p += pString->length(); \
len -= pString->length(); \ len -= pString->length(); \
} \ } \
@ -192,8 +192,8 @@ int kvi_wvsnprintf(kvi_wchar_t *buffer,kvi_wslen_t len,const kvi_wchar_t *fmt,kv
bool kvi_qstringEqualCI(const TQString &s1,const TQString &s2) bool kvi_qstringEqualCI(const TQString &s1,const TQString &s2)
{ {
const TQChar * p1 = s1.tqunicode(); const TQChar * p1 = s1.unicode();
const TQChar * p2 = s2.tqunicode(); const TQChar * p2 = s2.unicode();
int l = s1.length() < s2.length() ? s1.length() : s2.length(); int l = s1.length() < s2.length() ? s1.length() : s2.length();
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
while(l-- && (p1->toLower() == p2->toLower()))p1++,p2++; while(l-- && (p1->toLower() == p2->toLower()))p1++,p2++;
@ -1141,23 +1141,23 @@ KviStr::KviStr(char c,int fillLen)
} }
KviStr::KviStr(const kvi_wchar_t * tqunicode) KviStr::KviStr(const kvi_wchar_t * unicode)
{ {
if(!tqunicode) if(!unicode)
{ {
m_len = 0; m_len = 0;
m_ptr = (char *)kvi_malloc(1); m_ptr = (char *)kvi_malloc(1);
*m_ptr = 0; *m_ptr = 0;
} else { } else {
m_len = kvi_wstrlen(tqunicode); m_len = kvi_wstrlen(unicode);
m_ptr = (char *)kvi_malloc(m_len + 1); m_ptr = (char *)kvi_malloc(m_len + 1);
register char * p = m_ptr; register char * p = m_ptr;
while(*tqunicode)*p++ = *tqunicode++; while(*unicode)*p++ = *unicode++;
*p = 0; *p = 0;
} }
} }
KviStr::KviStr(const kvi_wchar_t * tqunicode,int len) KviStr::KviStr(const kvi_wchar_t * unicode,int len)
{ {
m_len = len; m_len = len;
m_ptr = (char *)kvi_malloc(m_len + 1); m_ptr = (char *)kvi_malloc(m_len + 1);
@ -1165,7 +1165,7 @@ KviStr::KviStr(const kvi_wchar_t * tqunicode,int len)
char * end = p + len; char * end = p + len;
while(p != end) while(p != end)
{ {
*p++ = *tqunicode++; *p++ = *unicode++;
} }
*p = 0; *p = 0;
} }

@ -155,9 +155,9 @@ public:
// Creates a string long fillLen characters filled with character c.<br> // Creates a string long fillLen characters filled with character c.<br>
KviStr(char c,int fillLen = 1); KviStr(char c,int fillLen = 1);
KviStr(const kvi_wchar_t * tqunicode); KviStr(const kvi_wchar_t * unicode);
KviStr(const kvi_wchar_t * tqunicode,int len); KviStr(const kvi_wchar_t * unicode,int len);
// just free(m_ptr) // just free(m_ptr)
~KviStr(); ~KviStr();

@ -60,7 +60,7 @@ namespace KviFileUtils
if(tmp_buf[255] == '\r')cur_len--; //Ignore CR... if(tmp_buf[255] == '\r')cur_len--; //Ignore CR...
int lastlen = szBuffer.length(); int lastlen = szBuffer.length();
szBuffer.setLength(lastlen + cur_len); szBuffer.setLength(lastlen + cur_len);
TQChar *p1 = szBuffer.tqunicode() + lastlen; TQChar *p1 = szBuffer.unicode() + lastlen;
char * p2 = tmp_buf; char * p2 = tmp_buf;
for(int i=0;i<cur_len;i++)*p1++ = *p2++; for(int i=0;i<cur_len;i++)*p1++ = *p2++;
cur_len = 0; cur_len = 0;
@ -76,7 +76,7 @@ namespace KviFileUtils
if(tmp_buf[cur_len - 1] == '\r')cur_len--; //Ignore CR... if(tmp_buf[cur_len - 1] == '\r')cur_len--; //Ignore CR...
int lastlen = szBuffer.length(); int lastlen = szBuffer.length();
szBuffer.setLength(lastlen + cur_len); szBuffer.setLength(lastlen + cur_len);
TQChar *p1 = szBuffer.tqunicode() + lastlen; TQChar *p1 = szBuffer.unicode() + lastlen;
char * p2 = tmp_buf; char * p2 = tmp_buf;
for(int i=0;i<cur_len;i++)*p1++ = *p2++; for(int i=0;i<cur_len;i++)*p1++ = *p2++;
} }

@ -232,8 +232,8 @@ KviIrcMask::KviIrcMask(const TQString &szMask)
if(b) if(b)
{ {
const TQChar * p = b; const TQChar * p = b;
while(p->tqunicode() && (p->tqunicode() != '!'))p++; while(p->unicode() && (p->unicode() != '!'))p++;
if(p->tqunicode()) if(p->unicode())
{ {
if(p != b) if(p != b)
{ {
@ -250,8 +250,8 @@ KviIrcMask::KviIrcMask(const TQString &szMask)
} }
p++; p++;
b = p; b = p;
while(p->tqunicode() && (p->tqunicode() != '@'))p++; while(p->unicode() && (p->unicode() != '@'))p++;
if(p->tqunicode()) if(p->unicode())
{ {
if(p != b) if(p != b)
{ {
@ -267,7 +267,7 @@ KviIrcMask::KviIrcMask(const TQString &szMask)
} }
p++; p++;
b=p; b=p;
while(p->tqunicode())p++; while(p->unicode())p++;
if(p != b) if(p != b)
{ {
m_szHost.setUnicode(b,p-b); m_szHost.setUnicode(b,p-b);
@ -291,7 +291,7 @@ bool KviIrcMask::hasNumericHost() const
int nPoints = 0; int nPoints = 0;
int nDoublePoints = 0; int nDoublePoints = 0;
unsigned short uc; unsigned short uc;
while((uc = p->tqunicode())) while((uc = p->unicode()))
{ {
if(uc == '.')nPoints++; // ipv6 masks can contain dots too! if(uc == '.')nPoints++; // ipv6 masks can contain dots too!
else { else {
@ -300,9 +300,9 @@ bool KviIrcMask::hasNumericHost() const
if((uc < '0') || (uc > '9')) if((uc < '0') || (uc > '9'))
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
uc = p->toUpper().tqunicode(); uc = p->toUpper().unicode();
#else #else
uc = p->upper().tqunicode(); uc = p->upper().unicode();
#endif #endif
if((uc < 'A') || (uc > 'F'))return false; if((uc < 'A') || (uc > 'F'))return false;
} }
@ -408,13 +408,13 @@ void KviIrcMask::mask(TQString &szMask,MaskType eMaskType) const
break; break;
default: default:
if (m_szUser.length() > 0) { if (m_szUser.length() > 0) {
if(m_szUser[0].tqunicode() != '*') if(m_szUser[0].unicode() != '*')
szMask.append(m_szWild); szMask.append(m_szWild);
if ((m_szUser[0].tqunicode() == '~') || if ((m_szUser[0].unicode() == '~') ||
(m_szUser[0].tqunicode() == '^') || (m_szUser[0].unicode() == '^') ||
(m_szUser[0].tqunicode() == '+') || (m_szUser[0].unicode() == '+') ||
(m_szUser[0].tqunicode() == '-') || (m_szUser[0].unicode() == '-') ||
(m_szUser[0].tqunicode() == '='))szMask.append(m_szUser.right(m_szUser.length() - 1)); (m_szUser[0].unicode() == '='))szMask.append(m_szUser.right(m_szUser.length() - 1));
else else
szMask.append(m_szUser); szMask.append(m_szUser);
} }
@ -614,13 +614,13 @@ bool KviIrcMask::matchesFixed(const TQString &nick,const TQString &user,const TQ
int KviIrcMask::getIpDomainMaskLen() const int KviIrcMask::getIpDomainMaskLen() const
{ {
int len = m_szHost.length(); int len = m_szHost.length();
const TQChar *p = m_szHost.tqunicode(); const TQChar *p = m_szHost.unicode();
const TQChar *b = p; const TQChar *b = p;
p += len; p += len;
if(b < p) if(b < p)
{ {
p--; p--;
while((b < p) && (p->tqunicode() != '.') && (p->tqunicode() != ':'))p--; while((b < p) && (p->unicode() != '.') && (p->unicode() != ':'))p--;
} }
// 000.000.000.000 // 000.000.000.000
// p // p
@ -632,17 +632,17 @@ int KviIrcMask::getIpDomainMaskLen() const
int KviIrcMask::getLargeIpDomainMaskLen() const int KviIrcMask::getLargeIpDomainMaskLen() const
{ {
int len = m_szHost.length(); int len = m_szHost.length();
const TQChar *p = m_szHost.tqunicode(); const TQChar *p = m_szHost.unicode();
const TQChar *b = p; const TQChar *b = p;
p += len; p += len;
if(b < p) if(b < p)
{ {
p--; p--;
while((b < p) && (p->tqunicode() != '.') && (p->tqunicode() != ':'))p--; while((b < p) && (p->unicode() != '.') && (p->unicode() != ':'))p--;
if(b < p) if(b < p)
{ {
p--; p--;
while((b < p) && (p->tqunicode() != '.') && (p->tqunicode() != ':'))p--; while((b < p) && (p->unicode() != '.') && (p->unicode() != ':'))p--;
} }
} }
// 000.000.000.000 // 000.000.000.000
@ -657,7 +657,7 @@ TQString KviIrcMask::getHostDomainMask() const
const TQChar *p=KviTQString::nullTerminatedArray(m_szHost); const TQChar *p=KviTQString::nullTerminatedArray(m_szHost);
if(!p)return TQString(); if(!p)return TQString();
const TQChar *b = p; const TQChar *b = p;
while(p->tqunicode() && p->tqunicode() != '.')p++; while(p->unicode() && p->unicode() != '.')p++;
TQString ret(p,len - (p - b)); TQString ret(p,len - (p - b));
return ret; return ret;
} }
@ -666,18 +666,18 @@ TQString KviIrcMask::getHostDomainMask() const
TQString KviIrcMask::getLargeHostDomainMask() const TQString KviIrcMask::getLargeHostDomainMask() const
{ {
int len = m_szHost.length(); int len = m_szHost.length();
const TQChar *p = m_szHost.tqunicode(); const TQChar *p = m_szHost.unicode();
const TQChar *b = p; const TQChar *b = p;
p += len; p += len;
if(b < p) if(b < p)
{ {
p--; p--;
while((b < p) && (p->tqunicode() != '.'))p--; while((b < p) && (p->unicode() != '.'))p--;
if(b < p) if(b < p)
{ {
p--; p--;
while((b < p) && (p->tqunicode() != '.'))p--; while((b < p) && (p->unicode() != '.'))p--;
} }
} }
@ -692,14 +692,14 @@ TQString KviIrcMask::getLargeHostDomainMask() const
bool KviIrcMask::hasMaskedIp() const bool KviIrcMask::hasMaskedIp() const
{ {
int len = m_szHost.length(); int len = m_szHost.length();
const TQChar *p = m_szHost.tqunicode(); const TQChar *p = m_szHost.unicode();
const TQChar *b = p; const TQChar *b = p;
if(len == 0)return false; if(len == 0)return false;
//run to the end //run to the end
p += len; p += len;
const TQChar *e = p; const TQChar *e = p;
p--; p--;
while((b < p) && (p->tqunicode() != '.'))p--; while((b < p) && (p->unicode() != '.'))p--;
return ((e - p) > 4); // at the moment 4 should be enough : the largest top part is "name" return ((e - p) > 4); // at the moment 4 should be enough : the largest top part is "name"
} }
@ -721,7 +721,7 @@ bool KviIrcMask::hasWildNick()
const TQChar * aux = KviTQString::nullTerminatedArray(m_szNick); const TQChar * aux = KviTQString::nullTerminatedArray(m_szNick);
if(!aux)return false; if(!aux)return false;
unsigned short uc; unsigned short uc;
while((uc = aux->tqunicode())) while((uc = aux->unicode()))
{ {
if((uc == '*') || (uc == '?'))return true; if((uc == '*') || (uc == '?'))return true;
aux++; aux++;
@ -736,14 +736,14 @@ int KviIrcMask::nonWildChars()
if(!aux)return 0; if(!aux)return 0;
unsigned short uc; unsigned short uc;
while((uc = aux->tqunicode())) while((uc = aux->unicode()))
{ {
if((uc != '*') && (uc != '?'))iCnt++; if((uc != '*') && (uc != '?'))iCnt++;
aux++; aux++;
} }
aux = KviTQString::nullTerminatedArray(m_szUser); aux = KviTQString::nullTerminatedArray(m_szUser);
while((uc = aux->tqunicode())) while((uc = aux->unicode()))
{ {
if((uc != '*') && (uc != '?'))iCnt++; if((uc != '*') && (uc != '?'))iCnt++;
aux++; aux++;
@ -751,7 +751,7 @@ int KviIrcMask::nonWildChars()
aux = KviTQString::nullTerminatedArray(m_szHost); aux = KviTQString::nullTerminatedArray(m_szHost);
while((uc = aux->tqunicode())) while((uc = aux->unicode()))
{ {
if((uc != '*') && (uc != '?'))iCnt++; if((uc != '*') && (uc != '?'))iCnt++;
aux++; aux++;

@ -54,9 +54,9 @@ void KviIrcUserEntry::setRealName(const TQString &rn)
m_szRealName = KviTQString::trimmed(m_szRealName); m_szRealName = KviTQString::trimmed(m_szRealName);
if(m_szRealName.length()>=3) if(m_szRealName.length()>=3)
{ {
if( (m_szRealName[0].tqunicode()==KVI_TEXT_COLOR) && (m_szRealName[2].tqunicode()==KVI_TEXT_RESET) ) if( (m_szRealName[0].unicode()==KVI_TEXT_COLOR) && (m_szRealName[2].unicode()==KVI_TEXT_RESET) )
{ {
switch(m_szRealName[1].tqunicode()) switch(m_szRealName[1].unicode())
{ {
case '1': // hum.. encoded as hidden color code eh ? publish is somewhere, so others might implement this... case '1': // hum.. encoded as hidden color code eh ? publish is somewhere, so others might implement this...
setGender(Male); setGender(Male);

@ -169,7 +169,7 @@ KVILIB_API unsigned int getUnicodeColorBytes(const TQString &szData,unsigned int
return charIdx; return charIdx;
} }
unsigned short c = szData[(int)charIdx].tqunicode(); unsigned short c = szData[(int)charIdx].unicode();
//First we can have a digit or a coma //First we can have a digit or a coma
if(((c < '0') || (c > '9'))) if(((c < '0') || (c > '9')))
@ -189,7 +189,7 @@ KVILIB_API unsigned int getUnicodeColorBytes(const TQString &szData,unsigned int
return charIdx; return charIdx;
} }
c = szData[(int)charIdx].tqunicode(); c = szData[(int)charIdx].unicode();
if(((c < '0') || (c > '9')) && (c != ',')) if(((c < '0') || (c > '9')) && (c != ','))
{ {
@ -207,7 +207,7 @@ KVILIB_API unsigned int getUnicodeColorBytes(const TQString &szData,unsigned int
(*byte_2)=KVI_NOCHANGE; (*byte_2)=KVI_NOCHANGE;
return charIdx; return charIdx;
} }
c = szData[(int)charIdx].tqunicode(); c = szData[(int)charIdx].unicode();
} }
if(c == ',') if(c == ',')
@ -218,7 +218,7 @@ KVILIB_API unsigned int getUnicodeColorBytes(const TQString &szData,unsigned int
(*byte_2)=KVI_NOCHANGE; (*byte_2)=KVI_NOCHANGE;
return charIdx; return charIdx;
} }
c = szData[(int)charIdx].tqunicode(); c = szData[(int)charIdx].unicode();
} else { } else {
(*byte_2)=KVI_NOCHANGE; (*byte_2)=KVI_NOCHANGE;
return charIdx; return charIdx;
@ -227,7 +227,7 @@ KVILIB_API unsigned int getUnicodeColorBytes(const TQString &szData,unsigned int
if((c < '0') || (c > '9')) if((c < '0') || (c > '9'))
{ {
(*byte_2)=KVI_NOCHANGE; (*byte_2)=KVI_NOCHANGE;
if(szData[(int)(charIdx-1)].tqunicode()==',') if(szData[(int)(charIdx-1)].unicode()==',')
return charIdx-1; return charIdx-1;
else else
return charIdx; return charIdx;
@ -237,7 +237,7 @@ KVILIB_API unsigned int getUnicodeColorBytes(const TQString &szData,unsigned int
(*byte_2)=c-'0'; (*byte_2)=c-'0';
charIdx++; charIdx++;
if(charIdx >= szData.length())return charIdx; if(charIdx >= szData.length())return charIdx;
c = szData[(int)charIdx].tqunicode(); c = szData[(int)charIdx].unicode();
if((c >= '0') && (c <='9')) if((c >= '0') && (c <='9'))
{ {
@ -262,7 +262,7 @@ namespace KviMircCntrl
unsigned char b2; unsigned char b2;
while(i < l) while(i < l)
{ {
switch(szData[i].tqunicode()) switch(szData[i].unicode())
{ {
case KVI_TEXT_UNDERLINE: case KVI_TEXT_UNDERLINE:
case KVI_TEXT_BOLD: case KVI_TEXT_BOLD:
@ -288,7 +288,7 @@ namespace KviMircCntrl
i++; i++;
while(i < l) while(i < l)
{ {
if(szData[i].tqunicode() == ' ')break; if(szData[i].unicode() == ' ')break;
else i++; else i++;
} }
begin = i; begin = i;

@ -479,7 +479,7 @@
return; return;
TQPoint pos; TQPoint pos;
int boxsize = lv->tqstyle()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv); int boxsize = lv->style()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv);
if (activatedPos(pos)) { if (activatedPos(pos)) {
bool parentControl = false; bool parentControl = false;
if (parent() && parent()->rtti() == 1 && if (parent() && parent()->rtti() == 1 &&
@ -652,7 +652,7 @@
int h = height(); int h = height();
KviTalListView *lv = listView(); KviTalListView *lv = listView();
if (lv) if (lv)
h = qMax(lv->tqstyle()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv), h = qMax(lv->style()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv),
h); h);
h = qMax(h, TQApplication::globalStrut().height()); h = qMax(h, TQApplication::globalStrut().height());
setHeight(h); setHeight(h);
@ -666,7 +666,7 @@
if (myType == RadioButtonController && pixmap(0)) { if (myType == RadioButtonController && pixmap(0)) {
// r += 0; // r += 0;
} else { } else {
r += lv->tqstyle()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv) + 4; r += lv->style()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv) + 4;
} }
} }
return qMax(r, TQApplication::globalStrut().width()); return qMax(r, TQApplication::globalStrut().width());
@ -700,7 +700,7 @@
parentControl = true; parentControl = true;
TQFontMetrics fm(lv->fontMetrics()); TQFontMetrics fm(lv->fontMetrics());
int boxsize = lv->tqstyle()->pixelMetric(myType == RadioButtonController ? TQStyle::PM_CheckListControllerSize : int boxsize = lv->style()->pixelMetric(myType == RadioButtonController ? TQStyle::PM_CheckListControllerSize :
TQStyle::PM_CheckListButtonSize, 0, lv); TQStyle::PM_CheckListButtonSize, 0, lv);
int marg = lv->itemMargin(); int marg = lv->itemMargin();
int r = marg; int r = marg;
@ -733,7 +733,7 @@
opt.rect.setRect(x, 0, boxsize, fm.height() + 2 + marg); opt.rect.setRect(x, 0, boxsize, fm.height() + 2 + marg);
opt.palette = cg; opt.palette = cg;
opt.state = styleflags; opt.state = styleflags;
lv->tqstyle()->drawPrimitive(TQStyle::PE_Q3CheckListController, &opt, p, lv); lv->style()->drawPrimitive(TQStyle::PE_Q3CheckListController, &opt, p, lv);
r += boxsize + 4; r += boxsize + 4;
} }
} else { } else {
@ -751,7 +751,7 @@
opt.rect.setRect(x, y, boxsize, fm.height() + 2 + marg); opt.rect.setRect(x, y, boxsize, fm.height() + 2 + marg);
opt.palette = cg; opt.palette = cg;
opt.state = styleflags; opt.state = styleflags;
lv->tqstyle()->drawPrimitive((myType == CheckBox || myType == CheckBoxController) lv->style()->drawPrimitive((myType == CheckBox || myType == CheckBoxController)
? TQStyle::PE_Q3CheckListIndicator ? TQStyle::PE_Q3CheckListIndicator
: TQStyle::PE_Q3CheckListExclusiveIndicator, &opt, p, lv); : TQStyle::PE_Q3CheckListExclusiveIndicator, &opt, p, lv);
r += boxsize + 4; r += boxsize + 4;
@ -782,7 +782,7 @@
(lv->rootIsDecorated() || myType == RadioButton || (lv->rootIsDecorated() || myType == RadioButton ||
(myType == CheckBox && parentControl))) { (myType == CheckBox && parentControl))) {
TQRect rect; TQRect rect;
int boxsize = lv->tqstyle()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv); int boxsize = lv->style()->pixelMetric(TQStyle::PM_CheckListButtonSize, 0, lv);
if (lv->columnAlignment(0) == TQt::AlignCenter) { if (lv->columnAlignment(0) == TQt::AlignCenter) {
TQFontMetrics fm(lv->font()); TQFontMetrics fm(lv->font());
int bx = (lv->columnWidth(0) - (boxsize + fm.width(text())))/2 + boxsize; int bx = (lv->columnWidth(0) - (boxsize + fm.width(text())))/2 + boxsize;
@ -1216,7 +1216,7 @@
return; return;
TQPoint pos; TQPoint pos;
int boxsize = lv->tqstyle().pixelMetric(TQStyle::PM_CheckListButtonSize, lv); int boxsize = lv->style().pixelMetric(TQStyle::PM_CheckListButtonSize, lv);
if ( activatedPos( pos ) ) { if ( activatedPos( pos ) ) {
bool parentControl = FALSE; bool parentControl = FALSE;
if ( parent() && parent()->rtti() == 1 && if ( parent() && parent()->rtti() == 1 &&
@ -1388,7 +1388,7 @@
int h = height(); int h = height();
KviTalListView *lv = listView(); KviTalListView *lv = listView();
if ( lv ) if ( lv )
h = TQMAX( lv->tqstyle().pixelMetric(TQStyle::PM_CheckListButtonSize, lv), h = TQMAX( lv->style().pixelMetric(TQStyle::PM_CheckListButtonSize, lv),
h ); h );
h = TQMAX( h, TQApplication::globalStrut().height() ); h = TQMAX( h, TQApplication::globalStrut().height() );
setHeight( h ); setHeight( h );
@ -1402,7 +1402,7 @@
if ( myType == RadioButtonController && pixmap( 0 ) ) { if ( myType == RadioButtonController && pixmap( 0 ) ) {
// r += 0; // r += 0;
} else { } else {
r += lv->tqstyle().pixelMetric(TQStyle::PM_CheckListButtonSize, lv) + 4; r += lv->style().pixelMetric(TQStyle::PM_CheckListButtonSize, lv) + 4;
} }
} }
return TQMAX( r, TQApplication::globalStrut().width() ); return TQMAX( r, TQApplication::globalStrut().width() );
@ -1437,7 +1437,7 @@
parentControl = TRUE; parentControl = TRUE;
TQFontMetrics fm( lv->fontMetrics() ); TQFontMetrics fm( lv->fontMetrics() );
int boxsize = lv->tqstyle().pixelMetric( myType == RadioButtonController ? TQStyle::PM_CheckListControllerSize : int boxsize = lv->style().pixelMetric( myType == RadioButtonController ? TQStyle::PM_CheckListControllerSize :
TQStyle::PM_CheckListButtonSize, lv); TQStyle::PM_CheckListButtonSize, lv);
int marg = lv->itemMargin(); int marg = lv->itemMargin();
int r = marg; int r = marg;
@ -1464,7 +1464,7 @@
if(!parentControl) if(!parentControl)
x += 3; x += 3;
if ( !pixmap( 0 ) ) { if ( !pixmap( 0 ) ) {
lv->tqstyle().tqdrawPrimitive(TQStyle::PE_CheckListController, p, lv->style().tqdrawPrimitive(TQStyle::PE_CheckListController, p,
TQRect(x, 0, boxsize, TQRect(x, 0, boxsize,
fm.height() + 2 + marg), fm.height() + 2 + marg),
cg, styleflags, TQStyleOption(this)); cg, styleflags, TQStyleOption(this));
@ -1482,12 +1482,12 @@
y = (fm.height() + 2 + marg - boxsize) / 2; y = (fm.height() + 2 + marg - boxsize) / 2;
if ( ( myType == CheckBox ) || ( myType == CheckBoxController ) ) { if ( ( myType == CheckBox ) || ( myType == CheckBoxController ) ) {
lv->tqstyle().tqdrawPrimitive(TQStyle::PE_CheckListIndicator, p, lv->style().tqdrawPrimitive(TQStyle::PE_CheckListIndicator, p,
TQRect(x, y, boxsize, TQRect(x, y, boxsize,
fm.height() + 2 + marg), fm.height() + 2 + marg),
cg, styleflags, TQStyleOption(this)); cg, styleflags, TQStyleOption(this));
} else { //radio button look } else { //radio button look
lv->tqstyle().tqdrawPrimitive(TQStyle::PE_CheckListExclusiveIndicator, lv->style().tqdrawPrimitive(TQStyle::PE_CheckListExclusiveIndicator,
p, TQRect(x, y, boxsize, p, TQRect(x, y, boxsize,
fm.height() + 2 + marg), fm.height() + 2 + marg),
cg, styleflags, TQStyleOption(this)); cg, styleflags, TQStyleOption(this));
@ -1519,7 +1519,7 @@
(lv->rootIsDecorated() || myType == RadioButton || (lv->rootIsDecorated() || myType == RadioButton ||
(myType == CheckBox && parentControl) ) ) { (myType == CheckBox && parentControl) ) ) {
TQRect rect; TQRect rect;
int boxsize = lv->tqstyle().pixelMetric(TQStyle::PM_CheckListButtonSize, lv); int boxsize = lv->style().pixelMetric(TQStyle::PM_CheckListButtonSize, lv);
if ( lv->columnAlignment(0) == AlignCenter ) { if ( lv->columnAlignment(0) == AlignCenter ) {
TQFontMetrics fm( lv->font() ); TQFontMetrics fm( lv->font() );
int bx = (lv->columnWidth(0) - (boxsize + fm.width(text())))/2 + boxsize; int bx = (lv->columnWidth(0) - (boxsize + fm.width(text())))/2 + boxsize;

@ -49,7 +49,7 @@
{ {
//setFrameStyle(TQFrame::NoFrame); //setFrameStyle(TQFrame::NoFrame);
setObjectName(nam); setObjectName(nam);
if(!tqlayout()) if(!layout())
this->setLayout(new TQBoxLayout(TQBoxLayout::LeftToRight)); this->setLayout(new TQBoxLayout(TQBoxLayout::LeftToRight));
w->addToolBar(dock,this); w->addToolBar(dock,this);
} }
@ -58,14 +58,14 @@
{ {
//setFrameStyle(TQFrame::NoFrame); //setFrameStyle(TQFrame::NoFrame);
setObjectName(name); setObjectName(name);
if(!tqlayout()) if(!layout())
this->setLayout(new TQBoxLayout(TQBoxLayout::LeftToRight)); this->setLayout(new TQBoxLayout(TQBoxLayout::LeftToRight));
w->addToolBar(this); w->addToolBar(this);
} }
TQBoxLayout * KviTalToolBar::boxLayout() TQBoxLayout * KviTalToolBar::boxLayout()
{ {
return (TQBoxLayout*)this->tqlayout(); return (TQBoxLayout*)this->layout();
} }
void KviTalToolBar::setBoxLayout(TQBoxLayout * l) void KviTalToolBar::setBoxLayout(TQBoxLayout * l)

@ -916,8 +916,8 @@ TQString KviApp::getClipboardText()
return buffer; return buffer;
*/ */
TQString buffer = tqclipboard()->text(TQClipboard::Clipboard); TQString buffer = clipboard()->text(TQClipboard::Clipboard);
if(buffer.isEmpty())return tqclipboard()->text(TQClipboard::Selection); if(buffer.isEmpty())return clipboard()->text(TQClipboard::Selection);
return buffer; return buffer;
} }
@ -945,8 +945,8 @@ void KviApp::setClipboardText(const TQString &str)
#if [[[TQT_VERSION IS DEPRECATED]]] >= 300 #if [[[TQT_VERSION IS DEPRECATED]]] >= 300
} }
#endif*/ #endif*/
tqclipboard()->setText(str,TQClipboard::Clipboard); clipboard()->setText(str,TQClipboard::Clipboard);
tqclipboard()->setText(str,TQClipboard::Selection); clipboard()->setText(str,TQClipboard::Selection);
} }
void KviApp::setClipboardText(const KviStr &str) void KviApp::setClipboardText(const KviStr &str)

@ -127,7 +127,7 @@ void KviCustomToolBarDescriptor::fillToolBar()
{ {
if(m_pActions->count() == 0) if(m_pActions->count() == 0)
{ {
// force tqlayout of the toolbar // force layout of the toolbar
TQApplication::postEvent(m_pToolBar,new TQEvent(TQEvent::LayoutHint)); TQApplication::postEvent(m_pToolBar,new TQEvent(TQEvent::LayoutHint));
} else { } else {
KviPointerList<TQString> dying; KviPointerList<TQString> dying;

@ -67,7 +67,7 @@ void KviIrcConnectionServerInfo::setSupportedChannelModes(const TQString &szSupp
m_bSupportsModesIe = (szSupportedChannelModes.contains('e') && szSupportedChannelModes.contains('I')); m_bSupportsModesIe = (szSupportedChannelModes.contains('e') && szSupportedChannelModes.contains('I'));
TQChar* aux=(TQChar*)szSupportedChannelModes.ucs2(); TQChar* aux=(TQChar*)szSupportedChannelModes.ucs2();
while(aux->tqunicode()) while(aux->unicode())
{ {
if(!m_szSupportedChannelModes.contains(*aux)) if(!m_szSupportedChannelModes.contains(*aux))
m_szSupportedChannelModes.append(*aux); m_szSupportedChannelModes.append(*aux);
@ -98,7 +98,7 @@ void KviIrcConnectionServerInfo::buildModePrefixTable()
// Alexey: FIXED: rethinked:) // Alexey: FIXED: rethinked:)
// Pragma: LOL :DDDD // Pragma: LOL :DDDD
int i=0; int i=0;
while( (uPrefix = cPrefix->tqunicode()) && (uFlag = cFlag->tqunicode()) && i<m_uPrefixes*3) while( (uPrefix = cPrefix->unicode()) && (uFlag = cFlag->unicode()) && i<m_uPrefixes*3)
{ {
m_pModePrefixTable[i]=uPrefix; m_pModePrefixTable[i]=uPrefix;
m_pModePrefixTable[i+1]=uFlag; m_pModePrefixTable[i+1]=uFlag;
@ -131,7 +131,7 @@ bool KviIrcConnectionServerInfo::isSupportedModePrefix(TQChar c)
if(!m_pModePrefixTable) return false; if(!m_pModePrefixTable) return false;
for(int i=0;i<m_uPrefixes;i++) for(int i=0;i<m_uPrefixes;i++)
{ {
if(m_pModePrefixTable[i*3]==c.tqunicode()) return true; if(m_pModePrefixTable[i*3]==c.unicode()) return true;
} }
return false; return false;
} }
@ -141,7 +141,7 @@ bool KviIrcConnectionServerInfo::isSupportedModeFlag(TQChar c)
if(!m_pModePrefixTable) return false; if(!m_pModePrefixTable) return false;
for(int i=0;i<m_uPrefixes;i++) for(int i=0;i<m_uPrefixes;i++)
{ {
if(m_pModePrefixTable[(i*3)+1]==c.tqunicode()) return true; if(m_pModePrefixTable[(i*3)+1]==c.unicode()) return true;
} }
return false; return false;
} }
@ -171,7 +171,7 @@ kvi_u32_t KviIrcConnectionServerInfo::modeFlagFromPrefixChar(TQChar c)
if(!m_pModePrefixTable) return 0; if(!m_pModePrefixTable) return 0;
for(int i=0;i<m_uPrefixes;i++) for(int i=0;i<m_uPrefixes;i++)
{ {
if(m_pModePrefixTable[i*3]==c.tqunicode()) return m_pModePrefixTable[i*3+2]; if(m_pModePrefixTable[i*3]==c.unicode()) return m_pModePrefixTable[i*3+2];
} }
return 0; return 0;
} }
@ -181,7 +181,7 @@ kvi_u32_t KviIrcConnectionServerInfo::modeFlagFromModeChar(TQChar c)
if(!m_pModePrefixTable) return 0; if(!m_pModePrefixTable) return 0;
for(int i=0;i<m_uPrefixes;i++) for(int i=0;i<m_uPrefixes;i++)
{ {
if(m_pModePrefixTable[i*3+1]==c.tqunicode()) return m_pModePrefixTable[i*3+2]; if(m_pModePrefixTable[i*3+1]==c.unicode()) return m_pModePrefixTable[i*3+2];
} }
return 0; return 0;
} }
@ -225,7 +225,7 @@ const TQString & KviBasicIrcServerInfo::getUserModeDescription(TQChar mode)
const TQString & KviBasicIrcServerInfo::getBasicChannelModeDescription(TQChar mode) const TQString & KviBasicIrcServerInfo::getBasicChannelModeDescription(TQChar mode)
{ {
switch(mode.tqunicode()) switch(mode.unicode())
{ {
case 'o': return __tr2qs("Channel operators"); break; case 'o': return __tr2qs("Channel operators"); break;
case 'v': return __tr2qs("Voiced users"); break; case 'v': return __tr2qs("Voiced users"); break;
@ -265,7 +265,7 @@ const TQString & KviBasicIrcServerInfo::getBasicChannelModeDescription(TQChar mo
const TQString & KviBasicIrcServerInfo::getBasicUserModeDescription(TQChar mode) const TQString & KviBasicIrcServerInfo::getBasicUserModeDescription(TQChar mode)
{ {
switch(mode.tqunicode()) switch(mode.unicode())
{ {
case 'o': return __tr2qs("o: IRC operator (OPER)"); break; case 'o': return __tr2qs("o: IRC operator (OPER)"); break;
case 'O': return __tr2qs("O: Local IRC operator (LOCOP)"); break; case 'O': return __tr2qs("O: Local IRC operator (LOCOP)"); break;

@ -44,17 +44,17 @@ namespace KviUserInput
if(!c)return true; // empty if(!c)return true; // empty
while(c->isSpace())c++; while(c->isSpace())c++;
if(!c->tqunicode())return true; // empty if(!c->unicode())return true; // empty
if(c->tqunicode() == '\\') if(c->unicode() == '\\')
{ {
c++; c++;
if(c->tqunicode() != '/')c--; if(c->unicode() != '/')c--;
} else { } else {
if(c->tqunicode() == '/') if(c->unicode() == '/')
{ {
c++; c++;
if(c->tqunicode() != '/') if(c->unicode() != '/')
{ {
szData.remove(0,c-b); szData.remove(0,c-b);
return parseCommand(szData,pWindow,szContext,bUserFriendlyCommandline); return parseCommand(szData,pWindow,szContext,bUserFriendlyCommandline);
@ -103,11 +103,11 @@ namespace KviUserInput
const TQChar * beg = aux; const TQChar * beg = aux;
if(!beg)return; // empty if(!beg)return; // empty
while(aux->tqunicode()) while(aux->unicode())
{ {
while(aux->tqunicode() && (aux->tqunicode() != '\n'))aux++; while(aux->unicode() && (aux->unicode() != '\n'))aux++;
TQString buf(beg,aux-beg); TQString buf(beg,aux-beg);
if(aux->tqunicode() == '\n')aux++; if(aux->unicode() == '\n')aux++;
beg = aux; beg = aux;
if(buf.isEmpty())buf = " "; // avoid "No text to send" (d3vah) if(buf.isEmpty())buf = " "; // avoid "No text to send" (d3vah)

@ -47,7 +47,7 @@ namespace KviKvsCoreFunctions
// a_f // a_f
_REGFNC("active",active) _REGFNC("active",active)
_REGFNC("array",array) _REGFNC("array",array)
_REGFNC("ascii",tqunicode) _REGFNC("ascii",unicode)
_REGFNC("asciiToHex",asciiToHex) _REGFNC("asciiToHex",asciiToHex)
_REGFNC("asciiToBase64",asciiToBase64) _REGFNC("asciiToBase64",asciiToBase64)
_REGFNC("away",away) _REGFNC("away",away)
@ -121,7 +121,7 @@ namespace KviKvsCoreFunctions
_REGFNC("true",trueCKEYWORDWORKAROUND) _REGFNC("true",trueCKEYWORDWORKAROUND)
_REGFNC("typeof",typeofCKEYWORDWORKAROUND) _REGFNC("typeof",typeofCKEYWORDWORKAROUND)
_REGFNC("u",u) _REGFNC("u",u)
_REGFNC("tqunicode",tqunicode) _REGFNC("unicode",unicode)
_REGFNC("unixtime",unixtime) _REGFNC("unixtime",unixtime)
_REGFNC("unserialize",unserialize) _REGFNC("unserialize",unserialize)
_REGFNC("username",username) _REGFNC("username",username)

@ -131,7 +131,7 @@ namespace KviKvsCoreFunctions
KVSCF(trueCKEYWORDWORKAROUND); KVSCF(trueCKEYWORDWORKAROUND);
KVSCF(typeofCKEYWORDWORKAROUND); KVSCF(typeofCKEYWORDWORKAROUND);
KVSCF(u); KVSCF(u);
KVSCF(tqunicode); KVSCF(unicode);
KVSCF(unixtime); KVSCF(unixtime);
KVSCF(unserialize); KVSCF(unserialize);
KVSCF(username); KVSCF(username);

@ -108,7 +108,7 @@ namespace KviKvsCoreFunctions
@syntax: @syntax:
<variant> $ascii(<char:string>) <variant> $ascii(<char:string>)
@description: @description:
This function has been renamed to $tqunicode and is present This function has been renamed to $unicode and is present
only for backward compatibility. only for backward compatibility.
@seealso: @seealso:
[fnc]$cr[/fnc], [fnc]$lf[/fnc], [fnc]$char[/fnc] [fnc]$cr[/fnc], [fnc]$lf[/fnc], [fnc]$char[/fnc]
@ -489,24 +489,24 @@ namespace KviKvsCoreFunctions
@title: @title:
$char $char
@short: @short:
Returns a character specified by tqunicode Returns a character specified by unicode
@syntax: @syntax:
<string> $char(<tqunicode_value:integer>) <string> $char(<unicode_value:integer>)
@description: @description:
Returns a character corresponding to the UNICODE code <tqunicode_value>.[br] Returns a character corresponding to the UNICODE code <unicode_value>.[br]
This function can not return NUL character (UNICODE 0). Basically This function can not return NUL character (UNICODE 0). Basically
you should never need it: if you do, drop me a mail.[br] you should never need it: if you do, drop me a mail.[br]
If the <tqunicode_code> is not a valid UNICODE code (or is 0), this function returns If the <unicode_code> is not a valid UNICODE code (or is 0), this function returns
an empty string.[br] an empty string.[br]
@seealso: @seealso:
[fnc]$cr[/fnc], [fnc]$lf[/fnc], [fnc]$tqunicode[/fnc] [fnc]$cr[/fnc], [fnc]$lf[/fnc], [fnc]$unicode[/fnc]
*/ */
KVSCF(charCKEYWORDWORKAROUND) KVSCF(charCKEYWORDWORKAROUND)
{ {
kvs_uint_t ac; kvs_uint_t ac;
KVSCF_PARAMETERS_BEGIN KVSCF_PARAMETERS_BEGIN
KVSCF_PARAMETER("tqunicode_value",KVS_PT_UINT,0,ac) KVSCF_PARAMETER("unicode_value",KVS_PT_UINT,0,ac)
KVSCF_PARAMETERS_END KVSCF_PARAMETERS_END
if(ac != 0 && ac < 65536) if(ac != 0 && ac < 65536)
@ -780,15 +780,15 @@ namespace KviKvsCoreFunctions
const TQChar * c = KviTQString::nullTerminatedArray(szFormat); const TQChar * c = KviTQString::nullTerminatedArray(szFormat);
if(c) if(c)
{ {
while(c->tqunicode()) while(c->unicode())
{ {
//Check for right Characters //Check for right Characters
#ifdef COMPILE_ON_WINDOWS #ifdef COMPILE_ON_WINDOWS
if (szAllowedCharacters.find((char)(c->tqunicode()),0,true) >= 0) tmpFormat += '%'; if (szAllowedCharacters.find((char)(c->unicode()),0,true) >= 0) tmpFormat += '%';
#else #else
if (c->isLetter()) tmpFormat += '%'; if (c->isLetter()) tmpFormat += '%';
#endif #endif
tmpFormat += (char)(c->tqunicode()); tmpFormat += (char)(c->unicode());
c++; c++;
} }
} }

@ -401,12 +401,12 @@ namespace KviKvsCoreFunctions
if(szLongSwitch.isEmpty()) if(szLongSwitch.isEmpty())
v = sl->find(szSwitch); v = sl->find(szSwitch);
else else
v = sl->find(szSwitch[0].tqunicode(),szLongSwitch); v = sl->find(szSwitch[0].unicode(),szLongSwitch);
}else { }else {
if(szLongSwitch.isEmpty()) if(szLongSwitch.isEmpty())
v = sl->find(szSwitch[0]); v = sl->find(szSwitch[0]);
else else
v = sl->find(szSwitch[0].tqunicode(),szLongSwitch); v = sl->find(szSwitch[0].unicode(),szLongSwitch);
} }
if(v)KVSCF_pRetBuffer->copyFrom(*v); if(v)KVSCF_pRetBuffer->copyFrom(*v);
@ -842,15 +842,15 @@ namespace KviKvsCoreFunctions
///////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////
/* /*
@doc: tqunicode @doc: unicode
@type: @type:
function function
@title: @title:
$tqunicode $unicode
@short: @short:
Returns the UNICODE code of a sets of characters Returns the UNICODE code of a sets of characters
@syntax: @syntax:
<variant> $tqunicode(<char:string>) <variant> $unicode(<char:string>)
@description: @description:
If <char> is composed only of a single character If <char> is composed only of a single character
then returns its UNICODE code point as an integer. then returns its UNICODE code point as an integer.
@ -860,7 +860,7 @@ namespace KviKvsCoreFunctions
[fnc]$cr[/fnc], [fnc]$lf[/fnc], [fnc]$char[/fnc] [fnc]$cr[/fnc], [fnc]$lf[/fnc], [fnc]$char[/fnc]
*/ */
KVSCF(tqunicode) KVSCF(unicode)
{ {
TQString sz; TQString sz;
KVSCF_PARAMETERS_BEGIN KVSCF_PARAMETERS_BEGIN
@ -871,10 +871,10 @@ namespace KviKvsCoreFunctions
{ {
KviKvsArray * a = new KviKvsArray(); KviKvsArray * a = new KviKvsArray();
for(kvs_int_t i=0;i<sz.length();i++) for(kvs_int_t i=0;i<sz.length();i++)
a->set(i,new KviKvsVariant((kvs_int_t)(sz[(int)i].tqunicode()))); a->set(i,new KviKvsVariant((kvs_int_t)(sz[(int)i].unicode())));
KVSCF_pRetBuffer->setArray(a); KVSCF_pRetBuffer->setArray(a);
} else { } else {
KVSCF_pRetBuffer->setInteger((kvs_int_t)(sz[0].tqunicode())); KVSCF_pRetBuffer->setInteger((kvs_int_t)(sz[0].unicode()));
} }
return true; return true;
} }

@ -427,7 +427,7 @@ namespace KviKvsCoreSimpleCommands
// TQChar o = tbOp.length() > 0 ? tbOp[0] : TQChar('x'); // TQChar o = tbOp.length() > 0 ? tbOp[0] : TQChar('x');
switch(o.tqunicode()) switch(o.unicode())
{ {
case 't': case 't':
KviTalToolTip::remove(pButton); KviTalToolTip::remove(pButton);
@ -853,7 +853,7 @@ namespace KviKvsCoreSimpleCommands
{ {
TQString szWnd; TQString szWnd;
v->asString(szWnd); v->asString(szWnd);
//#warning "FIXME: the window database is not tqunicode! (we even could keep integer window id's at this point!)" //#warning "FIXME: the window database is not unicode! (we even could keep integer window id's at this point!)"
pWnd = g_pApp->findWindow(szWnd.utf8().data()); pWnd = g_pApp->findWindow(szWnd.utf8().data());
if(!pWnd) if(!pWnd)
{ {

@ -673,7 +673,7 @@ namespace KviKvsCoreSimpleCommands
to load catalogues that reside in different directories.[br] to load catalogues that reside in different directories.[br]
[b]NOTE[/b][br] [b]NOTE[/b][br]
This feature is currently work in progress: the scripting engine This feature is currently work in progress: the scripting engine
is not yet fully tqunicode and thus some more exotic translations may still suffer... is not yet fully unicode and thus some more exotic translations may still suffer...
@seealso: @seealso:
[fnc]$tr[/fnc], [cmd]trunload[/cmd] [fnc]$tr[/fnc], [cmd]trunload[/cmd]
*/ */

@ -117,9 +117,9 @@ void KviKvsParser::report(bool bError,const TQChar * pLocation,const TQString &s
void KviKvsParser::errorBadChar(const TQChar * pLocation,char cExpected,const char * szCommandName) void KviKvsParser::errorBadChar(const TQChar * pLocation,char cExpected,const char * szCommandName)
{ {
if(pLocation->tqunicode()) if(pLocation->unicode())
error(pLocation,__tr2qs("Found character '%q' (tqunicode 0x%x) where '%c' was expected: see \"/help %s\" for the command syntax"), error(pLocation,__tr2qs("Found character '%q' (unicode 0x%x) where '%c' was expected: see \"/help %s\" for the command syntax"),
pLocation,pLocation->tqunicode(),cExpected,szCommandName); pLocation,pLocation->unicode(),cExpected,szCommandName);
else else
error(pLocation,__tr2qs("Found end of input where character '%c' was expected: see \"/help %s\" for the command syntax"), error(pLocation,__tr2qs("Found end of input where character '%c' was expected: see \"/help %s\" for the command syntax"),
cExpected,szCommandName); cExpected,szCommandName);
@ -1349,7 +1349,7 @@ KviKvsTreeNodeInstruction * KviKvsParser::parseAsParameter(const TQChar * pBuffe
so the callback code is empty, but if you continue reading we will soon fill it. so the callback code is empty, but if you continue reading we will soon fill it.
[/p] [/p]
[big]A typical addon tqlayout[/big] [big]A typical addon layout[/big]
[p] [p]
As stated above, the addons are usually shipped in a compressed archive. As stated above, the addons are usually shipped in a compressed archive.
Once uncompressed, the archive will expand into a small directory tree Once uncompressed, the archive will expand into a small directory tree
@ -1400,7 +1400,7 @@ KviKvsTreeNodeInstruction * KviKvsParser::parseAsParameter(const TQChar * pBuffe
[/p] [/p]
[p] [p]
The entries in [b]bold[/b] are directories while the other are files. The entries in [b]bold[/b] are directories while the other are files.
Please note that this is a general tqlayout for a huge and rather complex Please note that this is a general layout for a huge and rather complex
addon: you might not need all of these directories. Remember: the minimal addon: you might not need all of these directories. Remember: the minimal
addon has only an install.kvs file. Anyway, a really cool addon addon has only an install.kvs file. Anyway, a really cool addon
will probably have all of them and maybe some more. will probably have all of them and maybe some more.
@ -1496,7 +1496,7 @@ KviKvsTreeNodeInstruction * KviKvsParser::parseAsParameter(const TQChar * pBuffe
[p] [p]
It is a good idea to start on the KVIrc web site. There are surely It is a good idea to start on the KVIrc web site. There are surely
several addons to look at. Pick one that seems simple and analyze its several addons to look at. Pick one that seems simple and analyze its
tqlayout and code (wow... the free software!). It will be easier to do than it was to explain it :D layout and code (wow... the free software!). It will be easier to do than it was to explain it :D
[/p] [/p]
[p] [p]
Have fun! :) Have fun! :)
@ -2724,7 +2724,7 @@ KviKvsTreeNodeInstruction * KviKvsParser::parseInstruction()
return parseCommand(); return parseCommand();
} else { } else {
// what the heck is this ? // what the heck is this ?
error(KVSP_curCharPointer,__tr2qs("Found character '%q' (tqunicode %x) where an instruction was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character '%q' (unicode %x) where an instruction was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
break; break;
@ -2839,7 +2839,7 @@ KviKvsTreeNodeSwitchList * KviKvsParser::parseCommandSwitchList()
if(KVSP_curCharUnicode == 0) if(KVSP_curCharUnicode == 0)
{ {
error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (tqunicode %x) after a switch dash"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (unicode %x) after a switch dash"),KVSP_curCharPointer,KVSP_curCharUnicode);
} else { } else {
error(KVSP_curCharPointer,__tr2qs("Unexpected end of script after a switch dash")); error(KVSP_curCharPointer,__tr2qs("Unexpected end of script after a switch dash"));
} }
@ -2880,12 +2880,12 @@ KviKvsTreeNodeSwitchList * KviKvsParser::parseCommandSwitchList()
if(bLong) if(bLong)
sw->addLong(TQString(pSw,pSwEnd - pSw),p); sw->addLong(TQString(pSw,pSwEnd - pSw),p);
else else
sw->addShort(pSw->lower().tqunicode(),p); sw->addShort(pSw->lower().unicode(),p);
} else { } else {
if(bLong) if(bLong)
sw->addLong(TQString(pSw,pSwEnd - pSw),new KviKvsTreeNodeConstantData(KVSP_curCharPointer,new KviKvsVariant(true))); // empty param sw->addLong(TQString(pSw,pSwEnd - pSw),new KviKvsTreeNodeConstantData(KVSP_curCharPointer,new KviKvsVariant(true))); // empty param
else else
sw->addShort(pSw->lower().tqunicode(),new KviKvsTreeNodeConstantData(KVSP_curCharPointer,new KviKvsVariant(true))); // empty param sw->addShort(pSw->lower().unicode(),new KviKvsTreeNodeConstantData(KVSP_curCharPointer,new KviKvsVariant(true))); // empty param
} }
} }
@ -3300,7 +3300,7 @@ KviKvsTreeNodeData * KviKvsParser::parseArrayIndex()
error(KVSP_curCharPointer,__tr2qs("Unexpected end of line in array index (missing ']' character or unescaped newline)")); error(KVSP_curCharPointer,__tr2qs("Unexpected end of line in array index (missing ']' character or unescaped newline)"));
break; break;
default: default:
error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (tqunicode %x) in array index: it should be already terminated"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (unicode %x) in array index: it should be already terminated"),KVSP_curCharPointer,KVSP_curCharUnicode);
break; break;
} }
return 0; return 0;

@ -139,7 +139,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseCommand()
// perl.begin has a *really* half special parsing routine // perl.begin has a *really* half special parsing routine
if(iIdentifierLen == 4) if(iIdentifierLen == 4)
{ {
if(pIdentifier->lower().tqunicode() == 'p') if(pIdentifier->lower().unicode() == 'p')
{ {
if(KviTQString::equalCI(szIdentifier,"perl")) if(KviTQString::equalCI(szIdentifier,"perl"))
{ {

@ -85,7 +85,7 @@ KviKvsTreeNode * KviKvsParser::parseComment()
} }
break; break;
default: default:
error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (tqunicode %x) after a slash (it is a typo or a malformed comment begin ?)"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (unicode %x) after a slash (it is a typo or a malformed comment begin ?)"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
break; break;
} }

@ -50,7 +50,7 @@ KviKvsTreeNodeData * KviKvsParser::parseDollar(bool bInObjScope)
if(!KVSP_curCharIsFunctionStart) if(!KVSP_curCharIsFunctionStart)
{ {
if(KVSP_curCharUnicode == 0)warning(KVSP_curCharPointer,__tr2qs("Unexpected end of script after '$' function call prefix")); if(KVSP_curCharUnicode == 0)warning(KVSP_curCharPointer,__tr2qs("Unexpected end of script after '$' function call prefix"));
else warning(KVSP_curCharPointer,__tr2qs("Unexpected character %q (tqunicode %x) after '$' function call prefix"),KVSP_curCharPointer,KVSP_curCharUnicode); else warning(KVSP_curCharPointer,__tr2qs("Unexpected character %q (unicode %x) after '$' function call prefix"),KVSP_curCharPointer,KVSP_curCharUnicode);
error(KVSP_curCharPointer,__tr2qs("Syntax error after '$' function call prefix. If you want to use a plain '$' in the code you need to escape it")); error(KVSP_curCharPointer,__tr2qs("Syntax error after '$' function call prefix. If you want to use a plain '$' in the code you need to escape it"));
return 0; return 0;
} }

@ -420,7 +420,7 @@ KviKvsTreeNodeExpression * KviKvsParser::parseExpressionOperandCore(char termina
pDataList->append(new KviKvsTreeNodeConstantData(pBegin,new KviKvsVariant(iVal))); pDataList->append(new KviKvsTreeNodeConstantData(pBegin,new KviKvsVariant(iVal)));
} else { } else {
// bOk is false // bOk is false
if(pBegin->tqunicode() == '0') if(pBegin->unicode() == '0')
{ {
if(tmp.length() > 2) if(tmp.length() > 2)
{ {
@ -448,7 +448,7 @@ KviKvsTreeNodeExpression * KviKvsParser::parseExpressionOperandCore(char termina
} }
} }
} else { } else {
error(KVSP_curCharPointer,__tr2qs("Unexpected character %q (tqunicode %h) in expression. If it meant to be a string use the quotes."),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Unexpected character %q (unicode %h) in expression. If it meant to be a string use the quotes."),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pDataList; delete pDataList;
return 0; return 0;
} }

@ -828,7 +828,7 @@ KviKvsTreeNodeOperation * KviKvsParser::parseBindingOperation()
if(KVSP_curCharUnicode != '/') if(KVSP_curCharUnicode != '/')
{ {
error(KVSP_curCharPointer,__tr2qs("Found character '%q' (tqunicode %x) where a slash '/' was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character '%q' (unicode %x) where a slash '/' was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
@ -846,7 +846,7 @@ KviKvsTreeNodeOperation * KviKvsParser::parseBindingOperation()
if(KVSP_curCharUnicode != '/') if(KVSP_curCharUnicode != '/')
{ {
error(KVSP_curCharPointer,__tr2qs("Found character '%q' (tqunicode %x) where a slash '/' was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character '%q' (unicode %x) where a slash '/' was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pFirst; delete pFirst;
return 0; return 0;
} }
@ -869,7 +869,7 @@ KviKvsTreeNodeOperation * KviKvsParser::parseBindingOperation()
if(KVSP_curCharUnicode != '/') if(KVSP_curCharUnicode != '/')
{ {
error(KVSP_curCharPointer,__tr2qs("Found character '%q' (tqunicode %x) where a slash '/' was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character '%q' (unicode %x) where a slash '/' was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pFirst; delete pFirst;
return 0; return 0;
} }
@ -1173,10 +1173,10 @@ KviKvsTreeNodeInstruction * KviKvsParser::parseVoidFunctionCallOrOperation()
// must be followed by the end of a command // must be followed by the end of a command
if(r->isFunctionCall()) if(r->isFunctionCall())
{ {
error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (tqunicode %x) after a void function call: end of instruction expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Unexpected character '%q' (unicode %x) after a void function call: end of instruction expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
} else { } else {
warning(pBegin,__tr2qs("Unexpected (and senseless) read-only data evaluation")); warning(pBegin,__tr2qs("Unexpected (and senseless) read-only data evaluation"));
warning(pBegin,__tr2qs("Unexpected character '%q' (tqunicode %x)"),KVSP_curCharPointer,KVSP_curCharUnicode); warning(pBegin,__tr2qs("Unexpected character '%q' (unicode %x)"),KVSP_curCharPointer,KVSP_curCharUnicode);
error(KVSP_curCharPointer,__tr2qs("Syntax error: confused by earlier errors: bailing out")); error(KVSP_curCharPointer,__tr2qs("Syntax error: confused by earlier errors: bailing out"));
} }
delete r; delete r;

@ -29,15 +29,15 @@
#define KVSP_backChar m_ptr-- #define KVSP_backChar m_ptr--
#define KVSP_backNChars(n) m_ptr -= n #define KVSP_backNChars(n) m_ptr -= n
#define KVSP_curCharUnicode (m_ptr->tqunicode()) #define KVSP_curCharUnicode (m_ptr->unicode())
#define KVSP_curCharPointer m_ptr #define KVSP_curCharPointer m_ptr
#define KVSP_curCharIsLetter (m_ptr->isLetter()) #define KVSP_curCharIsLetter (m_ptr->isLetter())
#define KVSP_curCharIsNumber (m_ptr->isNumber()) #define KVSP_curCharIsNumber (m_ptr->isNumber())
#define KVSP_curCharIsLetterOrNumber (m_ptr->isLetterOrNumber()) #define KVSP_curCharIsLetterOrNumber (m_ptr->isLetterOrNumber())
#define KVSP_curCharIsFunctionStart (m_ptr->isLetterOrNumber() || (m_ptr->tqunicode() == '(') || (m_ptr->tqunicode() == '{') || (m_ptr->tqunicode() == '$')) #define KVSP_curCharIsFunctionStart (m_ptr->isLetterOrNumber() || (m_ptr->unicode() == '(') || (m_ptr->unicode() == '{') || (m_ptr->unicode() == '$'))
#define KVSP_curCharIsEndOfCommand ((m_ptr->tqunicode() == ';') || (m_ptr->tqunicode() == 0) || (m_ptr->tqunicode() == '\n') || (m_ptr->tqunicode() == '\r')) #define KVSP_curCharIsEndOfCommand ((m_ptr->unicode() == ';') || (m_ptr->unicode() == 0) || (m_ptr->unicode() == '\n') || (m_ptr->unicode() == '\r'))
#define KVSP_curCharIsEndOfBuffer (m_ptr->tqunicode() == 0) #define KVSP_curCharIsEndOfBuffer (m_ptr->unicode() == 0)
#define KVSP_setCurCharPointer(_ptr) m_ptr = _ptr #define KVSP_setCurCharPointer(_ptr) m_ptr = _ptr

@ -207,7 +207,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandUnset()
if(!KVSP_curCharIsEndOfCommand) if(!KVSP_curCharIsEndOfCommand)
{ {
warning(KVSP_curCharPointer,__tr2qs("The 'unset' command needs a variable list")); warning(KVSP_curCharPointer,__tr2qs("The 'unset' command needs a variable list"));
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a variable was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a variable was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
@ -277,7 +277,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandGlobal()
if(!KVSP_curCharIsEndOfCommand) if(!KVSP_curCharIsEndOfCommand)
{ {
warning(KVSP_curCharPointer,__tr2qs("The 'global' command needs a variable list")); warning(KVSP_curCharPointer,__tr2qs("The 'global' command needs a variable list"));
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a variable was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a variable was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
@ -376,7 +376,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandClass()
if(KVSP_curCharUnicode != '(') if(KVSP_curCharUnicode != '(')
{ {
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where an open parenthesis was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where an open parenthesis was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
@ -443,7 +443,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandClass()
if(KVSP_curCharPointer == pLabelBegin) if(KVSP_curCharPointer == pLabelBegin)
{ {
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a function name was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a function name was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pClass; delete pClass;
return 0; return 0;
} }
@ -471,7 +471,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandClass()
if(KVSP_curCharPointer == pLabelBegin) if(KVSP_curCharPointer == pLabelBegin)
{ {
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a function name was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a function name was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pClass; delete pClass;
return 0; return 0;
} }
@ -498,7 +498,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandClass()
if(KVSP_curCharPointer == pLabelBegin) if(KVSP_curCharPointer == pLabelBegin)
{ {
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a function name was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a function name was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pClass; delete pClass;
return 0; return 0;
} }
@ -628,7 +628,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandWhile()
if(KVSP_curCharUnicode != '(') if(KVSP_curCharUnicode != '(')
{ {
warning(KVSP_curCharPointer,__tr2qs("The while command needs an expression enclosed in parenthesis")); warning(KVSP_curCharPointer,__tr2qs("The while command needs an expression enclosed in parenthesis"));
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where an open parenthesis was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where an open parenthesis was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
@ -740,7 +740,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandDo()
if(KVSP_curCharIsEndOfBuffer) if(KVSP_curCharIsEndOfBuffer)
error(KVSP_curCharPointer,__tr2qs("Unexpected end of command after the 'do' command block: expected 'while' keyword")); error(KVSP_curCharPointer,__tr2qs("Unexpected end of command after the 'do' command block: expected 'while' keyword"));
else else
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a 'while' keyword was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a 'while' keyword was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
if(i)delete i; if(i)delete i;
return 0; return 0;
} }
@ -1089,7 +1089,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandFor()
if(KVSP_curCharUnicode != ')') if(KVSP_curCharUnicode != ')')
{ {
error(KVSP_curCharPointer,__tr2qs("Found char %q (tqunicode %x) while looking for the terminating ')' in 'for' command"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found char %q (unicode %x) while looking for the terminating ')' in 'for' command"),KVSP_curCharPointer,KVSP_curCharUnicode);
if(i1)delete i1; if(i1)delete i1;
if(e)delete e; if(e)delete e;
if(i2)delete i2; if(i2)delete i2;
@ -1193,7 +1193,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandForeach()
if((KVSP_curCharUnicode != '%') && (KVSP_curCharUnicode != '$') && (KVSP_curCharUnicode != '@')) if((KVSP_curCharUnicode != '%') && (KVSP_curCharUnicode != '$') && (KVSP_curCharUnicode != '@'))
{ {
warning(KVSP_curCharPointer,__tr2qs("The 'foreach' command expects a writeable iteration variable as first parameter")); warning(KVSP_curCharPointer,__tr2qs("The 'foreach' command expects a writeable iteration variable as first parameter"));
error(KVSP_curCharPointer,__tr2qs("Found character '%q' (tqunicode %x) where '%' or '$' was expected: see /help foreach for the command syntax"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character '%q' (unicode %x) where '%' or '$' was expected: see /help foreach for the command syntax"),KVSP_curCharPointer,KVSP_curCharUnicode);
return 0; return 0;
} }
@ -1419,7 +1419,7 @@ KviKvsTreeNodeCommand * KviKvsParser::parseSpecialCommandSwitch()
if(KVSP_curCharPointer == pLabelBegin) if(KVSP_curCharPointer == pLabelBegin)
{ {
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a 'case','match','regexp','default' or 'break' label was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a 'case','match','regexp','default' or 'break' label was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pSwitch; delete pSwitch;
return 0; return 0;
} }
@ -1566,7 +1566,7 @@ KviKvsTreeNodeSpecialCommandDefpopupLabelPopup * KviKvsParser::parseSpecialComma
if(KVSP_curCharPointer == pLabelBegin) if(KVSP_curCharPointer == pLabelBegin)
{ {
error(KVSP_curCharPointer,__tr2qs("Found character %q (tqunicode %x) where a 'prologue','separator','label','popup','item','extpopup' or 'epilogue' label was expected"),KVSP_curCharPointer,KVSP_curCharUnicode); error(KVSP_curCharPointer,__tr2qs("Found character %q (unicode %x) where a 'prologue','separator','label','popup','item','extpopup' or 'epilogue' label was expected"),KVSP_curCharPointer,KVSP_curCharUnicode);
delete pPopup; delete pPopup;
return 0; return 0;
} }

@ -73,7 +73,7 @@ bool KviKvsProcessAsyncOperation::start()
if(szShell.isEmpty()) if(szShell.isEmpty())
{ {
#ifdef COMPILE_ON_WINDOWS #ifdef COMPILE_ON_WINDOWS
// [01:26:00] <PragmaOff> btw, what is qt_wintqunicode ? // [01:26:00] <PragmaOff> btw, what is qt_winunicode ?
// [01:26:12] <kode54> TQt export specific to win32 // [01:26:12] <kode54> TQt export specific to win32
// [01:26:27] <kode54> bool which indicates whether system is Unicode (NT) or not // [01:26:27] <kode54> bool which indicates whether system is Unicode (NT) or not
// [01:26:58] <kode54> not sure if that's documented, but it is a public export // [01:26:58] <kode54> not sure if that's documented, but it is a public export

@ -60,7 +60,7 @@ void KviKvsReport::findLineAndCol(const TQChar * pBegin,const TQChar * pPoint,in
const TQChar * pPrevLine = 0; const TQChar * pPrevLine = 0;
const TQChar * pLineBegin = pBegin; const TQChar * pLineBegin = pBegin;
unsigned short us = pBegin->tqunicode(); unsigned short us = pBegin->unicode();
while(us && (pBegin < pPoint)) while(us && (pBegin < pPoint))
{ {
@ -73,7 +73,7 @@ void KviKvsReport::findLineAndCol(const TQChar * pBegin,const TQChar * pPoint,in
} else { } else {
pBegin++; pBegin++;
} }
us = pBegin->tqunicode(); us = pBegin->unicode();
} }
iCol = (pBegin - pLineBegin) + 1; iCol = (pBegin - pLineBegin) + 1;
@ -92,7 +92,7 @@ void KviKvsReport::findLineColAndListing(const TQChar * pBegin,const TQChar * pP
const TQChar * pPrevLine = 0; const TQChar * pPrevLine = 0;
const TQChar * pLineBegin = pBegin; const TQChar * pLineBegin = pBegin;
unsigned short us = pBegin->tqunicode(); unsigned short us = pBegin->unicode();
while(us && (pBegin < pPoint)) while(us && (pBegin < pPoint))
{ {
@ -105,7 +105,7 @@ void KviKvsReport::findLineColAndListing(const TQChar * pBegin,const TQChar * pP
} else { } else {
pBegin++; pBegin++;
} }
us = pBegin->tqunicode(); us = pBegin->unicode();
} }
iCol = (pBegin - pLineBegin) + 1; iCol = (pBegin - pLineBegin) + 1;
@ -131,11 +131,11 @@ void KviKvsReport::findLineColAndListing(const TQChar * pBegin,const TQChar * pP
// current line // current line
pBegin = pLineBegin; pBegin = pLineBegin;
us = pBegin->tqunicode(); us = pBegin->unicode();
while(us && (us != '\n')) while(us && (us != '\n'))
{ {
pBegin++; pBegin++;
us = pBegin->tqunicode(); us = pBegin->unicode();
} }
if(us)pBegin++; if(us)pBegin++;
@ -152,11 +152,11 @@ void KviKvsReport::findLineColAndListing(const TQChar * pBegin,const TQChar * pP
// next line // next line
pLineBegin = pBegin; pLineBegin = pBegin;
us = pBegin->tqunicode(); us = pBegin->unicode();
while(us && (us != '\n')) while(us && (us != '\n'))
{ {
pBegin++; pBegin++;
us = pBegin->tqunicode(); us = pBegin->unicode();
} }
if(us)pBegin++; if(us)pBegin++;

@ -48,7 +48,7 @@ public:
KviKvsVariant * find(const TQChar &c) KviKvsVariant * find(const TQChar &c)
{ {
return m_pShortSwitchDict ? m_pShortSwitchDict->find(c.tqunicode()) : 0; return m_pShortSwitchDict ? m_pShortSwitchDict->find(c.unicode()) : 0;
}; };
KviKvsVariant * find(unsigned short uShortKey) KviKvsVariant * find(unsigned short uShortKey)

@ -1467,18 +1467,18 @@ bool KviKvsTreeNodeOperationStringSubstitution::execute(KviKvsRunTimeContext * c
TQString szReplaced; TQString szReplaced;
const TQChar * p2 = KviTQString::nullTerminatedArray(szR); const TQChar * p2 = KviTQString::nullTerminatedArray(szR);
const TQChar * begin = p2; const TQChar * begin = p2;
while(p2->tqunicode()) while(p2->unicode())
{ {
if(p2->tqunicode() == '\\') if(p2->unicode() == '\\')
{ {
p2++; p2++;
if(p2->tqunicode() >= '0' && p2->tqunicode() <= '9') if(p2->unicode() >= '0' && p2->unicode() <= '9')
{ {
szReplaced.append(TQString(begin,(p2 - begin) - 1)); szReplaced.append(TQString(begin,(p2 - begin) - 1));
szReplaced.append(re.cap(p2->tqunicode() - '0')); szReplaced.append(re.cap(p2->unicode() - '0'));
p2++; p2++;
begin = p2; begin = p2;
} else if(p2->tqunicode())p2++; } else if(p2->unicode())p2++;
} else p2++; } else p2++;
} }
if(begin != p2)szReplaced.append(TQString(begin,p2 - begin)); if(begin != p2)szReplaced.append(TQString(begin,p2 - begin));

@ -1010,7 +1010,7 @@ KviKvsVariant* KviKvsVariant::unserializeNull(const TQChar** aux)
KviKvsVariant* KviKvsVariant::unserializeRealOrInteger(const TQChar** aux) KviKvsVariant* KviKvsVariant::unserializeRealOrInteger(const TQChar** aux)
{ {
TQString data; TQString data;
if((*aux)->tqunicode() == '-') if((*aux)->unicode() == '-')
{ {
data.append('-'); data.append('-');
(*aux)++; (*aux)++;
@ -1024,7 +1024,7 @@ KviKvsVariant* KviKvsVariant::unserializeRealOrInteger(const TQChar** aux)
data.append(**aux); data.append(**aux);
(*aux)++; (*aux)++;
} }
if((*aux)->tqunicode()=='.') if((*aux)->unicode()=='.')
{ {
return unserializeReal(aux,data); return unserializeReal(aux,data);
} }
@ -1042,15 +1042,15 @@ KviKvsVariant* KviKvsVariant::unserializeReal(const TQChar** aux,TQString& data)
(*aux)++; (*aux)++;
} }
if((*aux)->tqunicode() == 'e' || (*aux)->tqunicode() == 'E') if((*aux)->unicode() == 'e' || (*aux)->unicode() == 'E')
{ {
(*aux)++; (*aux)++;
if((*aux)->tqunicode() == '-') if((*aux)->unicode() == '-')
{ {
exponent.append('-'); exponent.append('-');
(*aux)++; (*aux)++;
} else { } else {
if((*aux)->tqunicode() == '+') if((*aux)->unicode() == '+')
{ {
exponent.append('+'); exponent.append('+');
(*aux)++; (*aux)++;
@ -1079,15 +1079,15 @@ KviKvsVariant* KviKvsVariant::unserializeInteger(const TQChar** aux,TQString& da
TQString exponent; TQString exponent;
if((*aux)->tqunicode() == 'e' || (*aux)->tqunicode() == 'E') if((*aux)->unicode() == 'e' || (*aux)->unicode() == 'E')
{ {
(*aux)++; (*aux)++;
if((*aux)->tqunicode() == '-') if((*aux)->unicode() == '-')
{ {
exponent.append('-'); exponent.append('-');
(*aux)++; (*aux)++;
} else { } else {
if((*aux)->tqunicode() == '+') if((*aux)->unicode() == '+')
{ {
exponent.append('+'); exponent.append('+');
(*aux)++; (*aux)++;
@ -1122,9 +1122,9 @@ void KviKvsVariant::unserializeString(const TQChar** aux,TQString& data)
TQString hex; //temp var TQString hex; //temp var
//skip leading " //skip leading "
(*aux)++; (*aux)++;
while((*aux)->tqunicode()) while((*aux)->unicode())
{ {
switch((*aux)->tqunicode()) switch((*aux)->unicode())
{ {
case '"': case '"':
//EOF //EOF
@ -1134,7 +1134,7 @@ void KviKvsVariant::unserializeString(const TQChar** aux,TQString& data)
case '\\': case '\\':
//Special //Special
(*aux)++; (*aux)++;
switch((*aux)->tqunicode()) switch((*aux)->unicode())
{ {
case 't': case 't':
data.append('\t'); data.append('\t');
@ -1159,11 +1159,11 @@ void KviKvsVariant::unserializeString(const TQChar** aux,TQString& data)
//4 hexadecmical digits pending... //4 hexadecmical digits pending...
hex=""; hex="";
(*aux)++; (*aux)++;
for(int k=0;k<4 && (*aux)->tqunicode(); k++) for(int k=0;k<4 && (*aux)->unicode(); k++)
{ {
if((*aux)->isDigit() || if((*aux)->isDigit() ||
((*aux)->tqunicode() >='A' && (*aux)->tqunicode() <='F')|| //ABCDEF ((*aux)->unicode() >='A' && (*aux)->unicode() <='F')|| //ABCDEF
((*aux)->tqunicode() >='a' && (*aux)->tqunicode() <='f')) //abcdef ((*aux)->unicode() >='a' && (*aux)->unicode() <='f')) //abcdef
{ {
hex.append(**aux); hex.append(**aux);
(*aux)++; (*aux)++;
@ -1203,7 +1203,7 @@ KviKvsVariant* KviKvsVariant::unserializeHash(const TQChar** aux)
while((*aux)->isSpace()) while((*aux)->isSpace())
(*aux)++; (*aux)++;
//waiting for starting of string //waiting for starting of string
if((*aux)->tqunicode()!='\"') if((*aux)->unicode()!='\"')
{ {
//strange characters //strange characters
delete pHash; delete pHash;
@ -1221,7 +1221,7 @@ KviKvsVariant* KviKvsVariant::unserializeHash(const TQChar** aux)
while((*aux)->isSpace()) while((*aux)->isSpace())
(*aux)++; (*aux)++;
//waiting for name-value delimeter //waiting for name-value delimeter
if((*aux)->tqunicode()!=':') if((*aux)->unicode()!=':')
{ {
//strange characters //strange characters
delete pHash; delete pHash;
@ -1238,7 +1238,7 @@ KviKvsVariant* KviKvsVariant::unserializeHash(const TQChar** aux)
i++; i++;
while((*aux)->isSpace()) while((*aux)->isSpace())
(*aux)++; (*aux)++;
switch((*aux)->tqunicode()) switch((*aux)->unicode())
{ {
case ',': case ',':
//goto next //goto next
@ -1278,7 +1278,7 @@ KviKvsVariant* KviKvsVariant::unserializeArray(const TQChar** aux)
i++; i++;
while((*aux)->isSpace()) while((*aux)->isSpace())
(*aux)++; (*aux)++;
switch((*aux)->tqunicode()) switch((*aux)->unicode())
{ {
case ',': case ',':
//goto next //goto next
@ -1310,7 +1310,7 @@ KviKvsVariant* KviKvsVariant::unserialize(const TQChar** aux)
while((*aux)->isSpace()) while((*aux)->isSpace())
(*aux)++; (*aux)++;
switch((*aux)->tqunicode()) switch((*aux)->unicode())
{ {
case 't': case 't':
//true //true
@ -1373,7 +1373,7 @@ KviKvsVariant* KviKvsVariant::unserialize(const TQString& data)
pResult = unserialize(&aux); pResult = unserialize(&aux);
if(aux->tqunicode()) if(aux->unicode())
{ {
//strange extra characters? //strange extra characters?
if(pResult) delete pResult; if(pResult) delete pResult;

@ -1808,7 +1808,7 @@ void KviServerParser::parseCtcpReplyUserinfo(KviCtcpMessage *msg)
if(pos>=0) if(pos>=0)
{ {
TQChar c = decoded[pos+7]; TQChar c = decoded[pos+7];
switch(c.tqunicode()) switch(c.unicode())
{ {
case 'F': case 'F':
case 'f': case 'f':

@ -186,13 +186,13 @@ void KviServerParser::parseLiteralJoin(KviIrcMessage *msg)
// nick!user@host JOIN :#channel\x07[o|v] // nick!user@host JOIN :#channel\x07[o|v]
const TQChar * pExt = KviTQString::nullTerminatedArray(channel); const TQChar * pExt = KviTQString::nullTerminatedArray(channel);
char chExtMode = 0; char chExtMode = 0;
while(pExt->tqunicode() && (pExt->tqunicode() != 0x07))pExt++; while(pExt->unicode() && (pExt->unicode() != 0x07))pExt++;
if(pExt->tqunicode()) if(pExt->unicode())
{ {
++pExt; ++pExt;
if(pExt->tqunicode()) if(pExt->unicode())
{ {
chExtMode = (char)pExt->tqunicode(); chExtMode = (char)pExt->unicode();
channel.remove(channel.length() - 2,2); // assuming that we're at the end (we should be) channel.remove(channel.length() - 2,2); // assuming that we're at the end (we should be)
} // else { senseless 0x07 in channel name ? } // else { senseless 0x07 in channel name ?
} }
@ -993,7 +993,7 @@ void KviServerParser::parseLiteralPrivmsg(KviIrcMessage *msg)
if(!chan) if(!chan)
{ {
// check if the channel has some leading mode prefixes // check if the channel has some leading mode prefixes
while((szTarget.length() > 0) && console->connection()->serverInfo()->isSupportedModePrefix(szTarget[0].tqunicode())) while((szTarget.length() > 0) && console->connection()->serverInfo()->isSupportedModePrefix(szTarget[0].unicode()))
{ {
szPrefixes += szTarget[0]; szPrefixes += szTarget[0];
szTarget.remove(0,1); szTarget.remove(0,1);
@ -1328,7 +1328,7 @@ void KviServerParser::parseLiteralNotice(KviIrcMessage *msg)
if(!chan) if(!chan)
{ {
// check if the channel has some leading mode prefixes // check if the channel has some leading mode prefixes
while((szTarget.length() > 0) && console->connection()->serverInfo()->isSupportedModePrefix(szTarget[0].tqunicode())) while((szTarget.length() > 0) && console->connection()->serverInfo()->isSupportedModePrefix(szTarget[0].unicode()))
{ {
szPrefixes += szTarget[0]; szPrefixes += szTarget[0];
szTarget.remove(0,1); szTarget.remove(0,1);

@ -112,7 +112,7 @@ KviChannel::KviChannel(KviFrame * lpFrm,KviConsole * lpConsole,const char * name
// Register ourselves // Register ourselves
connection()->registerChannel(this); connection()->registerChannel(this);
// And create the widgets tqlayout // And create the widgets layout
// Button box // Button box
m_pButtonBox = new KviTalHBox(this); m_pButtonBox = new KviTalHBox(this);
@ -287,7 +287,7 @@ void KviChannel::applyOptions()
m_pModeWidget->applyOptions(); m_pModeWidget->applyOptions();
// this applies options for IrcView and Input and forces the window to retqlayout // this applies options for IrcView and Input and forces the window to relayout
KviWindow::applyOptions(); KviWindow::applyOptions();
} }

@ -634,7 +634,7 @@ int KviConsole::applyHighlighting(KviWindow *wnd,int type,const TQString &nick,c
TQChar* aux=(TQChar*)(szStripMsg.ucs2()); TQChar* aux=(TQChar*)(szStripMsg.ucs2());
if(aux) if(aux)
{ {
while(aux->tqunicode()) while(aux->unicode())
{ {
if( KVI_OPTION_STRING(KviOption_stringWordSplitters).find(*aux) > -1 ) if( KVI_OPTION_STRING(KviOption_stringWordSplitters).find(*aux) > -1 )
szSource.append(' '); szSource.append(' ');
@ -794,11 +794,11 @@ void KviConsole::outputPrivmsg(KviWindow *wnd,
{ {
int sum = 0; int sum = 0;
int i = nick.length(); int i = nick.length();
const TQChar * aux = nick.tqunicode(); const TQChar * aux = nick.unicode();
// FIXME: Shouldn't this be case insensitive ? // FIXME: Shouldn't this be case insensitive ?
while(i > 0) while(i > 0)
{ {
sum += aux->tqunicode(); sum += aux->unicode();
aux++; aux++;
i--; i--;
} }
@ -815,11 +815,11 @@ void KviConsole::outputPrivmsg(KviWindow *wnd,
{ {
int sum = 0; int sum = 0;
int i = nick.length(); int i = nick.length();
const TQChar * aux = nick.tqunicode(); const TQChar * aux = nick.unicode();
// FIXME: Shouldn't this be case insensitive ? // FIXME: Shouldn't this be case insensitive ?
while(i > 0) while(i > 0)
{ {
sum += aux->tqunicode(); sum += aux->unicode();
aux++; aux++;
i--; i--;
} }

@ -70,9 +70,9 @@ TQSize KviCustomToolBarSeparator::sizeHint() const
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
TQStyleOption opt; TQStyleOption opt;
opt.initFrom(this); opt.initFrom(this);
int extent = tqstyle()->pixelMetric(TQStyle::PM_ToolBarSeparatorExtent,&opt,this); int extent = style()->pixelMetric(TQStyle::PM_ToolBarSeparatorExtent,&opt,this);
#else #else
int extent = tqstyle().pixelMetric(TQStyle::PM_DockWindowSeparatorExtent,this); int extent = style().pixelMetric(TQStyle::PM_DockWindowSeparatorExtent,this);
#endif #endif
if(m_pToolBar->orientation() == Qt::Horizontal)return TQSize(extent,0); if(m_pToolBar->orientation() == Qt::Horizontal)return TQSize(extent,0);
else return TQSize(0,extent); else return TQSize(0,extent);
@ -84,11 +84,11 @@ void KviCustomToolBarSeparator::paintEvent(TQPaintEvent *)
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
TQStyleOption opt; TQStyleOption opt;
opt.initFrom(this); opt.initFrom(this);
tqstyle()->drawPrimitive(TQStyle::PE_Q3DockWindowSeparator,&opt,&p,this); style()->drawPrimitive(TQStyle::PE_Q3DockWindowSeparator,&opt,&p,this);
#else #else
TQStyle::SFlags flags = TQStyle::Style_Default; TQStyle::SFlags flags = TQStyle::Style_Default;
if(m_pToolBar->orientation() == Qt::Horizontal)flags |= TQStyle::Style_Horizontal; if(m_pToolBar->orientation() == Qt::Horizontal)flags |= TQStyle::Style_Horizontal;
tqstyle().tqdrawPrimitive(TQStyle::PE_DockWindowSeparator,&p,rect(),colorGroup(),flags); style().tqdrawPrimitive(TQStyle::PE_DockWindowSeparator,&p,rect(),colorGroup(),flags);
#endif #endif
} }
@ -334,7 +334,7 @@ int KviCustomToolBar::dropIndexAt(const TQPoint &pnt,TQWidget * exclude,int * ex
// treating exclude as if it was going to be removed // treating exclude as if it was going to be removed
// find also the exclude index if needed // find also the exclude index if needed
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
TQLayout * l = tqlayout(); TQLayout * l = layout();
#else #else
TQBoxLayout * l = boxLayout(); TQBoxLayout * l = boxLayout();
#endif #endif
@ -453,7 +453,7 @@ int KviCustomToolBar::dropIndexAt(const TQPoint &pnt,TQWidget * exclude,int * ex
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
TQWidget * KviCustomToolBar::widgetAt(int index) TQWidget * KviCustomToolBar::widgetAt(int index)
{ {
TQLayout * l = tqlayout(); TQLayout * l = layout();
if(!l) if(!l)
return NULL; return NULL;
TQLayoutItem * it = l->itemAt(index); TQLayoutItem * it = l->itemAt(index);

@ -173,7 +173,7 @@ KviFrame::KviFrame()
installAccelerators(this); installAccelerators(this);
tqlayout()->setResizeMode(TQLayout::FreeResize); layout()->setResizeMode(TQLayout::FreeResize);
} }
KviFrame::~KviFrame() KviFrame::~KviFrame()

@ -317,7 +317,7 @@ TQSize KviInputEditor::sizeHint() const
TQSize( w + m, h + m ). TQSize( w + m, h + m ).
expandedTo(TQApplication::globalStrut()),this)); expandedTo(TQApplication::globalStrut()),this));
#else #else
return (tqstyle().tqsizeFromContents(TQStyle::CT_LineEdit, this, return (style().tqsizeFromContents(TQStyle::CT_LineEdit, this,
TQSize( w + m, h + m ). TQSize( w + m, h + m ).
expandedTo(TQApplication::globalStrut()))); expandedTo(TQApplication::globalStrut())));
#endif #endif
@ -454,7 +454,7 @@ void KviInputEditor::drawContents(TQPainter *p)
{ {
pa.setPen(KVI_OPTION_COLOR(KviOption_colorInputControl)); pa.setPen(KVI_OPTION_COLOR(KviOption_colorInputControl));
TQString s = getSubstituteChar(m_szTextBuffer[charIdx].tqunicode()); TQString s = getSubstituteChar(m_szTextBuffer[charIdx].unicode());
// the block width is 4 pixels more than the actual character // the block width is 4 pixels more than the actual character
@ -523,9 +523,9 @@ void KviInputEditor::drawContents(TQPainter *p)
{ {
TQChar c = m_szTextBuffer.at(m_iBlockLen); TQChar c = m_szTextBuffer.at(m_iBlockLen);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
m_iLastCursorXPosition+= c.tqunicode() < 32 ? fm.width(getSubstituteChar(c.tqunicode())) + 3 : fm.width(c); m_iLastCursorXPosition+= c.unicode() < 32 ? fm.width(getSubstituteChar(c.unicode())) + 3 : fm.width(c);
#else #else
m_iLastCursorXPosition+= (c.tqunicode() < 256) ? g_iInputFontCharWidth[c.tqunicode()] : fm.width(c); m_iLastCursorXPosition+= (c.unicode() < 256) ? g_iInputFontCharWidth[c.unicode()] : fm.width(c);
#endif #endif
m_iBlockLen++; m_iBlockLen++;
} }
@ -626,7 +626,7 @@ void KviInputEditor::extractNextBlock(int idx,TQFontMetrics & fm,int curXPos,int
TQChar c = m_szTextBuffer[idx]; TQChar c = m_szTextBuffer[idx];
if((c.tqunicode() > 32) || if((c.unicode() > 32) ||
((c != TQChar(KVI_TEXT_COLOR)) && ((c != TQChar(KVI_TEXT_COLOR)) &&
(c != TQChar(KVI_TEXT_BOLD)) && (c != TQChar(KVI_TEXT_UNDERLINE)) && (c != TQChar(KVI_TEXT_BOLD)) && (c != TQChar(KVI_TEXT_UNDERLINE)) &&
(c != TQChar(KVI_TEXT_RESET)) && (c != TQChar(KVI_TEXT_REVERSE)) && (c != TQChar(KVI_TEXT_RESET)) && (c != TQChar(KVI_TEXT_REVERSE)) &&
@ -637,7 +637,7 @@ void KviInputEditor::extractNextBlock(int idx,TQFontMetrics & fm,int curXPos,int
while((idx < ((int)(m_szTextBuffer.length()))) && (curXPos < maxXPos)) while((idx < ((int)(m_szTextBuffer.length()))) && (curXPos < maxXPos))
{ {
c = m_szTextBuffer[idx]; c = m_szTextBuffer[idx];
if((c.tqunicode() > 32) || if((c.unicode() > 32) ||
((c != TQChar(KVI_TEXT_COLOR)) && (c != TQChar(KVI_TEXT_BOLD)) && ((c != TQChar(KVI_TEXT_COLOR)) && (c != TQChar(KVI_TEXT_BOLD)) &&
(c != TQChar(KVI_TEXT_UNDERLINE)) && (c != TQChar(KVI_TEXT_RESET)) && (c != TQChar(KVI_TEXT_UNDERLINE)) && (c != TQChar(KVI_TEXT_RESET)) &&
(c != TQChar(KVI_TEXT_REVERSE)) && (c != TQChar(KVI_TEXT_CRYPTESCAPE)) && (c != TQChar(KVI_TEXT_REVERSE)) && (c != TQChar(KVI_TEXT_CRYPTESCAPE)) &&
@ -645,9 +645,9 @@ void KviInputEditor::extractNextBlock(int idx,TQFontMetrics & fm,int curXPos,int
{ {
m_iBlockLen++; m_iBlockLen++;
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
int xxx = c.tqunicode() < 32 ? fm.width(getSubstituteChar(c.tqunicode())) + 3 : fm.width(c);; int xxx = c.unicode() < 32 ? fm.width(getSubstituteChar(c.unicode())) + 3 : fm.width(c);;
#else #else
int xxx = (c.tqunicode() < 256 ? g_iInputFontCharWidth[c.tqunicode()] : fm.width(c)); int xxx = (c.unicode() < 256 ? g_iInputFontCharWidth[c.unicode()] : fm.width(c));
#endif #endif
m_iBlockWidth +=xxx; m_iBlockWidth +=xxx;
curXPos +=xxx; curXPos +=xxx;
@ -658,9 +658,9 @@ void KviInputEditor::extractNextBlock(int idx,TQFontMetrics & fm,int curXPos,int
} else { } else {
m_bControlBlock = true; m_bControlBlock = true;
m_iBlockLen = 1; m_iBlockLen = 1;
m_iBlockWidth = g_iInputFontCharWidth[c.tqunicode()]; m_iBlockWidth = g_iInputFontCharWidth[c.unicode()];
//Control code //Control code
switch(c.tqunicode()) switch(c.unicode())
{ {
case KVI_TEXT_BOLD: case KVI_TEXT_BOLD:
m_bCurBold = ! m_bCurBold; m_bCurBold = ! m_bCurBold;
@ -716,7 +716,7 @@ void KviInputEditor::runUpToTheFirstVisibleChar()
register int idx = 0; register int idx = 0;
while(idx < m_iFirstVisibleChar) while(idx < m_iFirstVisibleChar)
{ {
unsigned short c = m_szTextBuffer[idx].tqunicode(); unsigned short c = m_szTextBuffer[idx].unicode();
if(c < 32) if(c < 32)
{ {
switch(c) switch(c)
@ -789,7 +789,7 @@ void KviInputEditor::mousePressEvent(TQMouseEvent *e)
TQString szClip; TQString szClip;
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(c) if(c)
{ {
szClip = c->text(TQClipboard::Clipboard); szClip = c->text(TQClipboard::Clipboard);
@ -918,7 +918,7 @@ bool KviInputEditor::hasSelection()
void KviInputEditor::copyToClipboard() void KviInputEditor::copyToClipboard()
{ {
if(!hasSelection())return; if(!hasSelection())return;
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(!c)return; if(!c)return;
TQString szTxt = m_szTextBuffer.mid(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1); TQString szTxt = m_szTextBuffer.mid(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1);
c->setText(szTxt,TQClipboard::Clipboard); c->setText(szTxt,TQClipboard::Clipboard);
@ -928,7 +928,7 @@ void KviInputEditor::copyToClipboard()
void KviInputEditor::copyToSelection(bool bDonNotCopyToClipboard) void KviInputEditor::copyToSelection(bool bDonNotCopyToClipboard)
{ {
if(!hasSelection())return; if(!hasSelection())return;
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(!c)return; if(!c)return;
TQString szTxt = m_szTextBuffer.mid(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1); TQString szTxt = m_szTextBuffer.mid(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1);
if(c->supportsSelection()) if(c->supportsSelection())
@ -969,7 +969,7 @@ void KviInputEditor::removeSelected()
void KviInputEditor::cut() void KviInputEditor::cut()
{ {
if(!hasSelection())return; if(!hasSelection())return;
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(!c)return; if(!c)return;
c->setText(m_szTextBuffer.mid(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1),TQClipboard::Clipboard); c->setText(m_szTextBuffer.mid(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1),TQClipboard::Clipboard);
m_szTextBuffer.remove(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1); m_szTextBuffer.remove(m_iSelectionBegin,(m_iSelectionEnd-m_iSelectionBegin)+1);
@ -1042,7 +1042,7 @@ int KviInputEditor::replaceSegment(int start, int length, const TQString &text)
void KviInputEditor::pasteClipboardWithConfirmation() void KviInputEditor::pasteClipboardWithConfirmation()
{ {
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(!c)return; if(!c)return;
TQString szText = c->text(TQClipboard::Clipboard); TQString szText = c->text(TQClipboard::Clipboard);
@ -1057,7 +1057,7 @@ void KviInputEditor::pasteClipboardWithConfirmation()
void KviInputEditor::pasteSelectionWithConfirmation() void KviInputEditor::pasteSelectionWithConfirmation()
{ {
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(!c)return; if(!c)return;
TQString szText = c->text(c->supportsSelection() ? TQClipboard::Selection : TQClipboard::Clipboard); TQString szText = c->text(c->supportsSelection() ? TQClipboard::Selection : TQClipboard::Clipboard);
@ -1819,7 +1819,7 @@ void KviInputEditor::completion(bool bShift)
bool bIsDir = false; bool bIsDir = false;
bool bIsNick = false; bool bIsNick = false;
unsigned short uc = word[0].tqunicode(); unsigned short uc = word[0].unicode();
if(uc == '/') if(uc == '/')
{ {
@ -1845,7 +1845,7 @@ void KviInputEditor::completion(bool bShift)
{ {
if(m_pKviWindow) if(m_pKviWindow)
{ {
if( (word.length()==1) && (m_pKviWindow->windowName()[0].tqunicode()==uc)) if( (word.length()==1) && (m_pKviWindow->windowName()[0].unicode()==uc))
{ {
match=m_pKviWindow->windowName(); match=m_pKviWindow->windowName();
match.append(" "); match.append(" ");
@ -1911,8 +1911,8 @@ void KviInputEditor::completion(bool bShift)
const TQChar * b2 = KviTQString::nullTerminatedArray(match) + wLen; const TQChar * b2 = KviTQString::nullTerminatedArray(match) + wLen;
const TQChar * c1 = b1; const TQChar * c1 = b1;
const TQChar * c2 = b2; const TQChar * c2 = b2;
if(bIsDir)while(c1->tqunicode() && (c1->tqunicode() == c2->tqunicode()))c1++,c2++; if(bIsDir)while(c1->unicode() && (c1->unicode() == c2->unicode()))c1++,c2++;
else while(c1->tqunicode() && (c1->lower().tqunicode() == c2->lower().tqunicode()))c1++,c2++; else while(c1->unicode() && (c1->lower().unicode() == c2->lower().unicode()))c1++,c2++;
int len = wLen + (c1 - b1); int len = wLen + (c1 - b1);
if(len < ((int)(match.length())))match.remove(len,match.length() - len); if(len < ((int)(match.length())))match.remove(len,match.length() - len);
if(!all.isEmpty())all.append(", "); if(!all.isEmpty())all.append(", ");
@ -2084,17 +2084,17 @@ void KviInputEditor::moveRightFirstVisibleCharToShowCursor()
TQChar c = m_szTextBuffer.at(m_iCursorPosition); TQChar c = m_szTextBuffer.at(m_iCursorPosition);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
m_iLastCursorXPosition += c.tqunicode() < 32 ? fm.width(getSubstituteChar(c.tqunicode())) + 3 : fm.width(c);; m_iLastCursorXPosition += c.unicode() < 32 ? fm.width(getSubstituteChar(c.unicode())) + 3 : fm.width(c);;
#else #else
m_iLastCursorXPosition += (c.tqunicode() < 256) ? g_iInputFontCharWidth[c.tqunicode()] : fm.width(c); m_iLastCursorXPosition += (c.unicode() < 256) ? g_iInputFontCharWidth[c.unicode()] : fm.width(c);
#endif #endif
while(m_iLastCursorXPosition >= contentsRect().width()-2*KVI_INPUT_MARGIN) while(m_iLastCursorXPosition >= contentsRect().width()-2*KVI_INPUT_MARGIN)
{ {
c = m_szTextBuffer.at(m_iFirstVisibleChar); c = m_szTextBuffer.at(m_iFirstVisibleChar);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
m_iLastCursorXPosition -= c.tqunicode() < 32 ? fm.width(getSubstituteChar(c.tqunicode())) + 3 : fm.width(c);; m_iLastCursorXPosition -= c.unicode() < 32 ? fm.width(getSubstituteChar(c.unicode())) + 3 : fm.width(c);;
#else #else
m_iLastCursorXPosition -= (c.tqunicode() < 256) ? g_iInputFontCharWidth[c.tqunicode()] : fm.width(c); m_iLastCursorXPosition -= (c.unicode() < 256) ? g_iInputFontCharWidth[c.unicode()] : fm.width(c);
#endif #endif
m_iFirstVisibleChar++; m_iFirstVisibleChar++;
} }
@ -2127,9 +2127,9 @@ int KviInputEditor::charIndexFromXPosition(int xPos)
{ {
TQChar c = m_szTextBuffer.at(curChar); TQChar c = m_szTextBuffer.at(curChar);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
int widthCh = c.tqunicode() < 32 ? fm.width(getSubstituteChar(c.tqunicode())) + 3 : fm.width(c);; int widthCh = c.unicode() < 32 ? fm.width(getSubstituteChar(c.unicode())) + 3 : fm.width(c);;
#else #else
int widthCh = (c.tqunicode() < 256) ? g_iInputFontCharWidth[c.tqunicode()] : fm.width(c); int widthCh = (c.unicode() < 256) ? g_iInputFontCharWidth[c.unicode()] : fm.width(c);
#endif #endif
if(xPos < (curXPos+(widthCh/2)))return curChar; if(xPos < (curXPos+(widthCh/2)))return curChar;
else if(xPos < (curXPos+widthCh))return (curChar+1); else if(xPos < (curXPos+widthCh))return (curChar+1);
@ -2150,9 +2150,9 @@ int KviInputEditor::xPositionFromCharIndex(TQFontMetrics& fm,int chIdx,bool bCo
{ {
TQChar c = m_szTextBuffer.at(curChar); TQChar c = m_szTextBuffer.at(curChar);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
curXPos += c.tqunicode() < 32 ? fm.width(getSubstituteChar(c.tqunicode())) + 3 : fm.width(c);; curXPos += c.unicode() < 32 ? fm.width(getSubstituteChar(c.unicode())) + 3 : fm.width(c);;
#else #else
curXPos += (c.tqunicode() < 256) ? g_iInputFontCharWidth[c.tqunicode()] : fm.width(c); curXPos += (c.unicode() < 256) ? g_iInputFontCharWidth[c.unicode()] : fm.width(c);
#endif #endif
curChar++; curChar++;
} }
@ -2170,9 +2170,9 @@ int KviInputEditor::xPositionFromCharIndex(int chIdx,bool bContentsCoords)
{ {
TQChar c = m_szTextBuffer.at(curChar); TQChar c = m_szTextBuffer.at(curChar);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
curXPos += c.tqunicode() < 32 ? g_pLastFontMetrics->width(getSubstituteChar(c.tqunicode())) + 3 : g_pLastFontMetrics->width(c); curXPos += c.unicode() < 32 ? g_pLastFontMetrics->width(getSubstituteChar(c.unicode())) + 3 : g_pLastFontMetrics->width(c);
#else #else
curXPos += (c.tqunicode() < 256) ? g_iInputFontCharWidth[c.tqunicode()] : g_pLastFontMetrics->width(c); curXPos += (c.unicode() < 256) ? g_iInputFontCharWidth[c.unicode()] : g_pLastFontMetrics->width(c);
#endif #endif
curChar++; curChar++;
} }
@ -2336,8 +2336,8 @@ KviInput::KviInput(KviWindow *par,KviUserListView * view)
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
m_pButtonContainer->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum,TQSizePolicy::Preferred)); m_pButtonContainer->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum,TQSizePolicy::Preferred));
// if(m_pButtonContainer->tqlayout()) // if(m_pButtonContainer->layout())
// m_pButtonContainer->tqlayout()->setSizeConstraint(TQLayout::SetMinimumSize); // m_pButtonContainer->layout()->setSizeConstraint(TQLayout::SetMinimumSize);
#endif #endif
m_pHistoryButton = new KviStyledToolButton(m_pButtonContainer,"historybutton"); m_pHistoryButton = new KviStyledToolButton(m_pButtonContainer,"historybutton");

@ -243,12 +243,12 @@ void kvi_appendWCharToTQStringWithLength(TQString * qstrptr,const kvi_wchar_t *
kvi_wslen_t oldLen = qstrptr->length(); kvi_wslen_t oldLen = qstrptr->length();
qstrptr->setLength(oldLen + len); qstrptr->setLength(oldLen + len);
#ifdef WSTRINGCONFIG_SAFE_TO_MEMCPY_TQCHAR #ifdef WSTRINGCONFIG_SAFE_TO_MEMCPY_TQCHAR
_WSTRING_WMEMCPY(qstrptr->tqunicode() + oldLen,ptr,len); _WSTRING_WMEMCPY(qstrptr->unicode() + oldLen,ptr,len);
#else // !WSTRINGCONFIG_SAFE_TO_MEMCPY_TQCHAR #else // !WSTRINGCONFIG_SAFE_TO_MEMCPY_TQCHAR
TQChar * c = (qstrptr->tqunicode() + oldLen); TQChar * c = (qstrptr->unicode() + oldLen);
while(*ptr) while(*ptr)
{ {
c->tqunicode() = *ptr; c->unicode() = *ptr;
ptr++; ptr++;
c++; c++;
} }
@ -1964,8 +1964,8 @@ const kvi_wchar_t * KviIrcView::getTextLine(int iMsgType,
iTextIdx = iTimeStampLength; // the rest of the string will begin 11 chars later iTextIdx = iTimeStampLength; // the rest of the string will begin 11 chars later
// throw away const: we WANT to set the chars :D // throw away const: we WANT to set the chars :D
register TQChar * data_ptr_aux = (TQChar *)line_ptr->szText.tqunicode(); register TQChar * data_ptr_aux = (TQChar *)line_ptr->szText.unicode();
register TQChar * stamp_ptr_aux = (TQChar *)szTimestamp.tqunicode(); register TQChar * stamp_ptr_aux = (TQChar *)szTimestamp.unicode();
for(int i=0;i<iTimeStampLength;i++) for(int i=0;i<iTimeStampLength;i++)
*data_ptr_aux++ = *stamp_ptr_aux++; *data_ptr_aux++ = *stamp_ptr_aux++;
@ -3449,7 +3449,7 @@ no_selection_paint:
// //
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
#define IRCVIEW_WCHARWIDTH(__c) (((__c).tqunicode() < 0xff) ? m_iFontCharacterWidth[(__c).tqunicode()] : m_pFm->width(__c)) #define IRCVIEW_WCHARWIDTH(__c) (((__c).unicode() < 0xff) ? m_iFontCharacterWidth[(__c).unicode()] : m_pFm->width(__c))
void KviIrcView::calculateLineWraps(KviIrcViewLine *ptr,int maxWidth) void KviIrcView::calculateLineWraps(KviIrcViewLine *ptr,int maxWidth)
{ {
@ -3476,12 +3476,12 @@ void KviIrcView::calculateLineWraps(KviIrcViewLine *ptr,int maxWidth)
int maxBlockLen = ptr->pChunks->iTextLen; // ptr->pChunks[0].iTextLen int maxBlockLen = ptr->pChunks->iTextLen; // ptr->pChunks[0].iTextLen
const TQChar * tqunicode = ptr->szText.tqunicode(); const TQChar * unicode = ptr->szText.unicode();
for(;;) for(;;)
{ {
//Calculate the block_width //Calculate the block_width
register const TQChar * p = tqunicode + ptr->pBlocks[ptr->iBlockCount].block_start; register const TQChar * p = unicode + ptr->pBlocks[ptr->iBlockCount].block_start;
int curBlockLen = 0; int curBlockLen = 0;
int curBlockWidth = 0; int curBlockWidth = 0;
@ -3546,7 +3546,7 @@ void KviIrcView::calculateLineWraps(KviIrcViewLine *ptr,int maxWidth)
ptr->pBlocks[ptr->iBlockCount].block_width = 0; ptr->pBlocks[ptr->iBlockCount].block_width = 0;
ptr->iBlockCount++; ptr->iBlockCount++;
ptr->pBlocks = (KviIrcViewWrappedBlock *)kvi_realloc(ptr->pBlocks,(ptr->iBlockCount + 1) * sizeof(KviIrcViewWrappedBlock)); ptr->pBlocks = (KviIrcViewWrappedBlock *)kvi_realloc(ptr->pBlocks,(ptr->iBlockCount + 1) * sizeof(KviIrcViewWrappedBlock));
ptr->pBlocks[ptr->iBlockCount].block_start = p - tqunicode; ptr->pBlocks[ptr->iBlockCount].block_start = p - unicode;
ptr->pBlocks[ptr->iBlockCount].block_len = 0; ptr->pBlocks[ptr->iBlockCount].block_len = 0;
ptr->pBlocks[ptr->iBlockCount].block_width = 0; ptr->pBlocks[ptr->iBlockCount].block_width = 0;
ptr->pBlocks[ptr->iBlockCount].pChunk = &(ptr->pChunks[curAttrBlock]); ptr->pBlocks[ptr->iBlockCount].pChunk = &(ptr->pChunks[curAttrBlock]);
@ -3579,7 +3579,7 @@ void KviIrcView::calculateLineWraps(KviIrcViewLine *ptr,int maxWidth)
maxBlockLen-=curBlockLen; maxBlockLen-=curBlockLen;
ptr->iBlockCount++; ptr->iBlockCount++;
ptr->pBlocks = (KviIrcViewWrappedBlock *)kvi_realloc(ptr->pBlocks,(ptr->iBlockCount + 1) * sizeof(KviIrcViewWrappedBlock)); ptr->pBlocks = (KviIrcViewWrappedBlock *)kvi_realloc(ptr->pBlocks,(ptr->iBlockCount + 1) * sizeof(KviIrcViewWrappedBlock));
ptr->pBlocks[ptr->iBlockCount].block_start = p - tqunicode; ptr->pBlocks[ptr->iBlockCount].block_start = p - unicode;
ptr->pBlocks[ptr->iBlockCount].block_len = 0; ptr->pBlocks[ptr->iBlockCount].block_len = 0;
ptr->pBlocks[ptr->iBlockCount].block_width = 0; ptr->pBlocks[ptr->iBlockCount].block_width = 0;
ptr->pBlocks[ptr->iBlockCount].pChunk = 0; ptr->pBlocks[ptr->iBlockCount].pChunk = 0;
@ -3632,8 +3632,8 @@ bool KviIrcView::checkSelectionBlock(KviIrcViewLine * line,int left,int bottom,i
// //
// Yahoo!!!! // Yahoo!!!!
// //
const TQChar * tqunicode = line->szText.tqunicode(); const TQChar * unicode = line->szText.unicode();
register const TQChar * p = tqunicode + line->pBlocks[bufIndex].block_start; register const TQChar * p = unicode + line->pBlocks[bufIndex].block_start;
int top = bottom-m_iFontLineSpacing; int top = bottom-m_iFontLineSpacing;
int right = ((line->pBlocks[bufIndex].block_width >= 0) ? \ int right = ((line->pBlocks[bufIndex].block_width >= 0) ? \
@ -4479,7 +4479,7 @@ void KviIrcView::mouseDoubleClickEvent(TQMouseEvent *e)
pParams->append(szCmd); pParams->append(szCmd);
switch(linkCmd[0].tqunicode()) switch(linkCmd[0].unicode())
{ {
case 'n': case 'n':
{ {
@ -4517,7 +4517,7 @@ void KviIrcView::mouseDoubleClickEvent(TQMouseEvent *e)
if(((KviChannel *)m_pKviWindow)->isMeOp()) if(((KviChannel *)m_pKviWindow)->isMeOp())
{ {
TQChar plmn = linkCmd[1]; TQChar plmn = linkCmd[1];
if((plmn.tqunicode() == '+') || (plmn.tqunicode() == '-')) if((plmn.unicode() == '+') || (plmn.unicode() == '-'))
{ {
TQString target(m_pKviWindow->windowName()); TQString target(m_pKviWindow->windowName());
target.replace("\\","\\\\"); target.replace("\\","\\\\");
@ -4526,7 +4526,7 @@ void KviIrcView::mouseDoubleClickEvent(TQMouseEvent *e)
target.replace("$","\\$"); target.replace("$","\\$");
target.replace("%","\\%"); target.replace("%","\\%");
TQChar flag = linkCmd[2]; TQChar flag = linkCmd[2];
switch(flag.tqunicode()) switch(flag.unicode())
{ {
case 'o': case 'o':
case 'v': case 'v':
@ -4669,7 +4669,7 @@ void KviIrcView::mouseRealPressEvent(TQMouseEvent *e)
{ {
if(!linkCmd.isEmpty()) if(!linkCmd.isEmpty())
{ {
switch(linkCmd[0].tqunicode()) switch(linkCmd[0].unicode())
{ {
case 'n': case 'n':
{ {
@ -4782,7 +4782,7 @@ void KviIrcView::mouseReleaseEvent(TQMouseEvent *)
{ {
killTimer(m_iSelectTimer); killTimer(m_iSelectTimer);
m_iSelectTimer = 0; m_iSelectTimer = 0;
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(c) if(c)
{ {
// copy to both! // copy to both!
@ -4896,7 +4896,7 @@ void KviIrcView::doLinkToolTip(const TQRect &rct,TQString &linkCmd,TQString &lin
TQString tip; TQString tip;
switch(linkCmd[0].tqunicode()) switch(linkCmd[0].unicode())
{ {
case 'u': // url link case 'u': // url link
{ {
@ -4972,11 +4972,11 @@ void KviIrcView::doLinkToolTip(const TQRect &rct,TQString &linkCmd,TQString &lin
if(((KviChannel *)m_pKviWindow)->isMeOp()) if(((KviChannel *)m_pKviWindow)->isMeOp())
{ {
TQChar plmn = linkCmd[1]; TQChar plmn = linkCmd[1];
if((plmn.tqunicode() == '+') || (plmn.tqunicode() == '-')) if((plmn.unicode() == '+') || (plmn.unicode() == '-'))
{ {
tip = __tr2qs("Double-click to set<br>"); tip = __tr2qs("Double-click to set<br>");
TQChar flag = linkCmd[2]; TQChar flag = linkCmd[2];
switch(flag.tqunicode()) switch(flag.unicode())
{ {
case 'o': case 'o':
case 'v': case 'v':

@ -148,7 +148,7 @@ typedef struct _KviIrcViewWrappedBlockSelectionInfoTag
#endif //!COMPILE_ON_WINDOWS #endif //!COMPILE_ON_WINDOWS
//========================================================================================================= //=========================================================================================================
// Screen tqlayout // Screen layout
//========================================================================================================= //=========================================================================================================
//FIRST LINE (prev_line = 0) <---m_pFirstLine //FIRST LINE (prev_line = 0) <---m_pFirstLine

@ -591,7 +591,7 @@ void KviMdiManager::enterSDIMode(KviMdiChild *lpC)
// This is an obscure, undocumented and internal function in QT4 TQMenuBar // This is an obscure, undocumented and internal function in QT4 TQMenuBar
// I won't be surprised if this disappears.... // I won't be surprised if this disappears....
b->setCornerWidget(m_pSdiControls,TQt::TopRightCorner); b->setCornerWidget(m_pSdiControls,TQt::TopRightCorner);
// The show below SHOULD force a re-tqlayout of the menubar.. // The show below SHOULD force a re-layout of the menubar..
// but it doesn't work when the KviFrame is still hidden (at startup) // but it doesn't work when the KviFrame is still hidden (at startup)
// We handle this BUG in showEvent() // We handle this BUG in showEvent()
m_pSdiControls->show(); m_pSdiControls->show();
@ -611,7 +611,7 @@ void KviMdiManager::enterSDIMode(KviMdiChild *lpC)
void KviMdiManager::relayoutMenuButtons() void KviMdiManager::relayoutMenuButtons()
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
// force a re-tqlayout of the menubar in TQt4 (see the note in enterSDIMode()) // force a re-layout of the menubar in TQt4 (see the note in enterSDIMode())
// by resetting the corner widget // by resetting the corner widget
if(m_pSdiControls) if(m_pSdiControls)
{ {
@ -662,7 +662,7 @@ void KviMdiManager::leaveSDIMode()
} }
if(m_pSdiIconButton) if(m_pSdiIconButton)
{ {
m_pSdiIconButton->hide(); // this will force a TQMenuBar retqlayout m_pSdiIconButton->hide(); // this will force a TQMenuBar relayout
delete m_pSdiIconButton; delete m_pSdiIconButton;
m_pSdiIconButton = 0; m_pSdiIconButton = 0;
} }
@ -1073,7 +1073,7 @@ void KviMdiManager::tileAnodine()
int numVisible=getVisibleChildCount(); // count visible windows int numVisible=getVisibleChildCount(); // count visible windows
if(numVisible<1)return; if(numVisible<1)return;
int numCols=int(sqrt((double)numVisible)); // set columns to square root of visible count int numCols=int(sqrt((double)numVisible)); // set columns to square root of visible count
// create an array to form grid tqlayout // create an array to form grid layout
int *numRows=new int[numCols]; int *numRows=new int[numCols];
int numCurCol=0; int numCurCol=0;
while(numCurCol<numCols) while(numCurCol<numCols)

@ -97,7 +97,7 @@ void KviMenuBar::showEvent(TQShowEvent *e)
{ {
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
debug("menubar show"); debug("menubar show");
// force a re-tqlayout of the menubar in TQt4 (see the note in enterSDIMode()) // force a re-layout of the menubar in TQt4 (see the note in enterSDIMode())
// by resetting the corner widget // by resetting the corner widget
m_pFrm->mdiManager()->relayoutMenuButtons(); m_pFrm->mdiManager()->relayoutMenuButtons();
#endif #endif

@ -121,11 +121,11 @@ KviModeEditor::KviModeEditor(TQWidget * par,KviWindowToolPageButton* button,cons
TQChar ccc = szModes[0]; TQChar ccc = szModes[0];
szModes.remove(0,1); szModes.remove(0,1);
KviTQString::sprintf(tmp,"%c: %Q",ccc.tqunicode(),&(c->connection()->serverInfo()->getChannelModeDescription(ccc))); KviTQString::sprintf(tmp,"%c: %Q",ccc.unicode(),&(c->connection()->serverInfo()->getChannelModeDescription(ccc)));
KviStyledCheckBox * cb = new KviStyledCheckBox(tmp,pBackground); KviStyledCheckBox * cb = new KviStyledCheckBox(tmp,pBackground);
cb->setEnabled(isEnabled); cb->setEnabled(isEnabled);
m_pCheckBoxes->append(cb); m_pCheckBoxes->append(cb);
cb->setChecked(m_szMode.contains((char)ccc.tqunicode())); cb->setChecked(m_szMode.contains((char)ccc.unicode()));
i++; i++;
g->addMultiCellWidget(cb,i,i,0,2); g->addMultiCellWidget(cb,i,i,0,2);
} }
@ -193,11 +193,11 @@ KviModeEditor::KviModeEditor(TQWidget * par,KviWindowToolPageButton* button,cons
TQChar ccc = szModes[0]; TQChar ccc = szModes[0];
szModes.remove(0,1); szModes.remove(0,1);
KviTQString::sprintf(tmp,"%c: %Q",(char)ccc.tqunicode(),&(c->connection()->serverInfo()->getChannelModeDescription(ccc))); KviTQString::sprintf(tmp,"%c: %Q",(char)ccc.unicode(),&(c->connection()->serverInfo()->getChannelModeDescription(ccc)));
KviStyledCheckBox * cb = new KviStyledCheckBox(tmp,pBackground); KviStyledCheckBox * cb = new KviStyledCheckBox(tmp,pBackground);
cb->setEnabled(isEnabled); cb->setEnabled(isEnabled);
m_pCheckBoxes->append(cb); m_pCheckBoxes->append(cb);
cb->setChecked(m_szMode.contains((char)ccc.tqunicode())); cb->setChecked(m_szMode.contains((char)ccc.unicode()));
i++; i++;
g->addMultiCellWidget(cb,i,i,0,2); g->addMultiCellWidget(cb,i,i,0,2);
} }
@ -317,9 +317,9 @@ void KviModeEditor::commit()
TQChar ccc = sz[0]; TQChar ccc = sz[0];
if(cb->isChecked()) if(cb->isChecked())
{ {
if(!m_szMode.contains((char)ccc.tqunicode()))szPlusModes.append((char)ccc.tqunicode()); if(!m_szMode.contains((char)ccc.unicode()))szPlusModes.append((char)ccc.unicode());
} else { } else {
if(m_szMode.contains((char)ccc.tqunicode()))szMinusModes.append((char)ccc.tqunicode()); if(m_szMode.contains((char)ccc.unicode()))szMinusModes.append((char)ccc.unicode());
} }
} }
} }

@ -98,16 +98,16 @@ void KviOptionsWidget::createLayout(int rows,int cols)
void KviOptionsWidget::createTabbedPage() void KviOptionsWidget::createTabbedPage()
{ {
createLayout(1,1); createLayout(1,1);
tqlayout()->setMargin(0); layout()->setMargin(0);
tqlayout()->setSpacing(0); layout()->setSpacing(0);
m_pTabWidget = new TQTabWidget(this); m_pTabWidget = new TQTabWidget(this);
addWidgetToLayout(m_pTabWidget,0,0,0,0); addWidgetToLayout(m_pTabWidget,0,0,0,0);
} }
void KviOptionsWidget::addOptionsWidget(const TQString &szText,const TQIconSet &iconSet,KviOptionsWidget * pWidget) void KviOptionsWidget::addOptionsWidget(const TQString &szText,const TQIconSet &iconSet,KviOptionsWidget * pWidget)
{ {
if(pWidget->tqlayout()) if(pWidget->layout())
pWidget->tqlayout()->setMargin(10); pWidget->layout()->setMargin(10);
m_pTabWidget->addTab(pWidget,iconSet,szText); m_pTabWidget->addTab(pWidget,iconSet,szText);
m_pSelectorInterfaceList->append(pWidget); m_pSelectorInterfaceList->append(pWidget);
} }
@ -115,8 +115,8 @@ void KviOptionsWidget::addOptionsWidget(const TQString &szText,const TQIconSet &
void KviOptionsWidget::addWidgetToLayout(TQWidget * w,int x1,int y1,int x2,int y2) void KviOptionsWidget::addWidgetToLayout(TQWidget * w,int x1,int y1,int x2,int y2)
{ {
if((x1 == x2) && (y1 == y2))tqlayout()->addWidget(w,y1,x1); if((x1 == x2) && (y1 == y2))layout()->addWidget(w,y1,x1);
else tqlayout()->addMultiCellWidget(w,y1,y2,x1,x2); else layout()->addMultiCellWidget(w,y1,y2,x1,x2);
} }
/////////////////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////
@ -622,7 +622,7 @@ void KviOptionsWidget::addRowSpacer(int x1,int y1,int x2,int y2)
{ {
TQWidget * w = new TQWidget(this); TQWidget * w = new TQWidget(this);
addWidgetToLayout(w,x1,y1,x2,y2); addWidgetToLayout(w,x1,y1,x2,y2);
tqlayout()->setRowStretch(y1,1); layout()->setRowStretch(y1,1);
} }
TQLabel * KviOptionsWidget::addLabel(int x1,int y1,int x2,int y2,const TQString & text,bool bEnabled) TQLabel * KviOptionsWidget::addLabel(int x1,int y1,int x2,int y2,const TQString & text,bool bEnabled)

@ -54,7 +54,7 @@ private:
public: public:
void mergeResetFlag(int flag){ m_iResetFlags |= flag; }; void mergeResetFlag(int flag){ m_iResetFlags |= flag; };
void createLayout(int rows,int columns); void createLayout(int rows,int columns);
TQGridLayout * tqlayout(){ return m_pLayout; }; TQGridLayout * layout(){ return m_pLayout; };
protected: protected:
void commitSelectors(); void commitSelectors();
void commitOptionsReset(); void commitOptionsReset();

@ -547,7 +547,7 @@ void KviQuery::applyOptions()
{ {
m_pUserListView->applyOptions(); m_pUserListView->applyOptions();
updateLabelText(); updateLabelText();
// this applies options for IrcView and Input and forces the window to retqlayout // this applies options for IrcView and Input and forces the window to relayout
KviWindow::applyOptions(); KviWindow::applyOptions();
} }

@ -249,7 +249,7 @@ void KviStatusBar::recalcMinimumHeight()
{ {
m_iLastMinimumHeight = s; m_iLastMinimumHeight = s;
setMinimumHeight(s); setMinimumHeight(s);
TQLayout * l = tqlayout(); TQLayout * l = layout();
if(l) if(l)
if(l->inherits(TQBOXLAYOUT_OBJECT_NAME_STRING)) if(l->inherits(TQBOXLAYOUT_OBJECT_NAME_STRING))
((TQBoxLayout *)l)->addStrut(s); ((TQBoxLayout *)l)->addStrut(s);

@ -153,7 +153,7 @@ TQString convertToHtml(const TQString &text)
while(idx < text.length()) while(idx < text.length())
{ {
unsigned short c = text[(int)idx].tqunicode(); unsigned short c = text[(int)idx].unicode();
unsigned int start = idx; unsigned int start = idx;
@ -168,7 +168,7 @@ TQString convertToHtml(const TQString &text)
{ {
idx++; idx++;
if(idx >= text.length())break; if(idx >= text.length())break;
else c = text[(int)idx].tqunicode(); else c = text[(int)idx].unicode();
} }
int len = idx - start; int len = idx - start;
@ -251,7 +251,7 @@ TQString convertToHtml(const TQString &text)
++idx; ++idx;
unsigned int icoStart = idx; unsigned int icoStart = idx;
while((idx < text.length()) && (text[(int)idx].tqunicode() > 32))idx++; while((idx < text.length()) && (text[(int)idx].unicode() > 32))idx++;
KviStr lookupString = text.mid(icoStart,idx - icoStart); KviStr lookupString = text.mid(icoStart,idx - icoStart);
@ -291,7 +291,7 @@ void KviTopicWidget::paintColoredText(TQPainter *p, TQString text,const TQColorG
while((idx < text.length()) && (curX < width)) while((idx < text.length()) && (curX < width))
{ {
unsigned short c = text[(int)idx].tqunicode(); unsigned short c = text[(int)idx].unicode();
unsigned int start = idx; unsigned int start = idx;
@ -305,7 +305,7 @@ void KviTopicWidget::paintColoredText(TQPainter *p, TQString text,const TQColorG
) )
{ {
idx++; idx++;
c = text[(int)idx].tqunicode(); c = text[(int)idx].unicode();
} }
int len = idx - start; int len = idx - start;
@ -392,7 +392,7 @@ void KviTopicWidget::paintColoredText(TQPainter *p, TQString text,const TQColorG
++idx; ++idx;
unsigned int icoStart = idx; unsigned int icoStart = idx;
while((idx < text.length()) && (text[(int)idx].tqunicode() > 32))idx++; while((idx < text.length()) && (text[(int)idx].unicode() > 32))idx++;
KviStr lookupString = text.mid(icoStart,idx - icoStart); KviStr lookupString = text.mid(icoStart,idx - icoStart);
@ -629,7 +629,7 @@ void KviTopicWidget::contextPopupAboutToShow()
void KviTopicWidget::copy() void KviTopicWidget::copy()
{ {
TQClipboard * c = TQApplication::tqclipboard(); TQClipboard * c = TQApplication::clipboard();
if(!c)return; if(!c)return;
if(c->supportsSelection())c->setText(m_szTopic,TQClipboard::Selection); if(c->supportsSelection())c->setText(m_szTopic,TQClipboard::Selection);
c->setText(m_szTopic,TQClipboard::Clipboard); c->setText(m_szTopic,TQClipboard::Clipboard);

@ -838,7 +838,7 @@ int KviUserListView::getUserModeLevel(const TQString &szNick)
char KviUserListView::getUserFlag(KviUserListEntry * e) char KviUserListView::getUserFlag(KviUserListEntry * e)
{ {
if(!e)return 0; if(!e)return 0;
return (char)m_pKviWindow->connection()->serverInfo()->modePrefixChar(e->m_iFlags).tqunicode(); return (char)m_pKviWindow->connection()->serverInfo()->modePrefixChar(e->m_iFlags).unicode();
} }
void KviUserListView::prependUserFlag(const TQString &nick,TQString &buffer) void KviUserListView::prependUserFlag(const TQString &nick,TQString &buffer)

@ -1327,7 +1327,7 @@ void KviWindow::applyOptions()
if(m_pIrcView)m_pIrcView->applyOptions(); if(m_pIrcView)m_pIrcView->applyOptions();
if(m_pInput)m_pInput->applyOptions(); if(m_pInput)m_pInput->applyOptions();
// trick: retqlayout // trick: relayout
resize(width() - 1,height() - 1); resize(width() - 1,height() - 1);
resize(width() + 1,height() + 1); resize(width() + 1,height() + 1);
} }

@ -107,11 +107,11 @@ void KviCompletionBox::updateContents(TQString buffer)
if(pos>0) if(pos>0)
{ {
szModule=buffer.left(pos); szModule=buffer.left(pos);
if(szModule[0].tqunicode()=='$') if(szModule[0].unicode()=='$')
szModule.remove(0,1); szModule.remove(0,1);
} }
if(pCur->tqunicode() == '$') if(pCur->unicode() == '$')
{ {
buffer.remove(0,1); buffer.remove(0,1);
if(!buffer.isEmpty()) if(!buffer.isEmpty())
@ -369,13 +369,13 @@ void KviScriptEditorWidget::keyPressEvent(TQKeyEvent * e)
TQString szPrev=text(para-1); TQString szPrev=text(para-1);
if(!szPrev.isEmpty()) if(!szPrev.isEmpty())
{ {
if(szPrev.at(szPrev.length() - 1).tqunicode() == ' ') if(szPrev.at(szPrev.length() - 1).unicode() == ' ')
szPrev.remove(szPrev.length() - 1,1); szPrev.remove(szPrev.length() - 1,1);
TQString szCur; TQString szCur;
const TQChar * pCur = (const TQChar *)szPrev.ucs2(); const TQChar * pCur = (const TQChar *)szPrev.ucs2();
if(pCur) if(pCur)
{ {
while(pCur->tqunicode() && pCur->isSpace()) while(pCur->unicode() && pCur->isSpace())
{ {
szCur.append(*pCur); szCur.append(*pCur);
pCur++; pCur++;
@ -557,9 +557,9 @@ void KviScriptEditorWidget::slotComplete(const TQString &str)
bool bIsFirstWordInLine; bool bIsFirstWordInLine;
getWordBeforeCursor(buffer,index,&bIsFirstWordInLine); getWordBeforeCursor(buffer,index,&bIsFirstWordInLine);
int len=buffer.length(); int len=buffer.length();
// if (buffer[1].tqunicode() == '$') len --; // if (buffer[1].unicode() == '$') len --;
complete.remove(0,len-1); complete.remove(0,len-1);
if (buffer[1].tqunicode() == '$') complete.append("("); if (buffer[1].unicode() == '$') complete.append("(");
else complete.append(" "); else complete.append(" ");
insert (complete); insert (complete);
completelistbox->hide(); completelistbox->hide();
@ -595,19 +595,19 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
const TQChar * pBegin; const TQChar * pBegin;
while(c->tqunicode()) while(c->unicode())
{ {
if(bInComment) if(bInComment)
{ {
pBegin = c; pBegin = c;
while(c->tqunicode() && (c->tqunicode() != '*'))c++; while(c->unicode() && (c->unicode() != '*'))c++;
if(!c->tqunicode()) if(!c->unicode())
{ {
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment);
return IN_COMMENT; return IN_COMMENT;
} }
c++; c++;
if(c->tqunicode() == '/') if(c->unicode() == '/')
{ {
// end of the comment! // end of the comment!
c++; c++;
@ -620,14 +620,14 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
if(c->isSpace()) if(c->isSpace())
{ {
while(c->tqunicode() && c->isSpace())c++; while(c->unicode() && c->isSpace())c++;
if(!c->tqunicode())continue; if(!c->unicode())continue;
} }
pBegin = c; pBegin = c;
// this does not break the bNewCommand flag // this does not break the bNewCommand flag
if((c->tqunicode() == '{') || (c->tqunicode() == '}')) if((c->unicode() == '{') || (c->unicode() == '}'))
{ {
c++; c++;
setFormat(pBegin - pBuf,1,g_fntNormal,g_clrBracket); setFormat(pBegin - pBuf,1,g_fntNormal,g_clrBracket);
@ -639,12 +639,12 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
{ {
bNewCommand = false; bNewCommand = false;
if(c->tqunicode() == '#') if(c->unicode() == '#')
{ {
if(c > pBuf) if(c > pBuf)
{ {
const TQChar * prev = c - 1; const TQChar * prev = c - 1;
if((prev->tqunicode() == ']') || (prev->tqunicode() == '}')) if((prev->unicode() == ']') || (prev->unicode() == '}'))
{ {
// array or hash count // array or hash count
c++; c++;
@ -653,19 +653,19 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
} }
} }
// comment until the end of the line // comment until the end of the line
while(c->tqunicode())c++; while(c->unicode())c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment);
continue; continue;
} }
if(c->tqunicode() == '/') if(c->unicode() == '/')
{ {
c++; c++;
if(c->tqunicode() == '/') if(c->unicode() == '/')
{ {
while(c->tqunicode())c++; while(c->unicode())c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment);
continue; continue;
} else if(c->tqunicode() == '*') } else if(c->unicode() == '*')
{ {
c++; c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrComment);
@ -674,13 +674,13 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
} }
c--; c--;
} }
if(c->tqunicode() && (c->isLetterOrNumber() || (c->tqunicode() == '_'))) if(c->unicode() && (c->isLetterOrNumber() || (c->unicode() == '_')))
{ {
c++; c++;
while(c->tqunicode() && (c->isLetterOrNumber() || (c->tqunicode() == '.') || (c->tqunicode() == '_') || (c->tqunicode() == ':')))c++; while(c->unicode() && (c->isLetterOrNumber() || (c->unicode() == '.') || (c->unicode() == '_') || (c->unicode() == ':')))c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrKeyword); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrKeyword);
// special processing for callbacks and magic commands // special processing for callbacks and magic commands
if(pBegin->tqunicode() == 'e') if(pBegin->unicode() == 'e')
{ {
if(c - pBegin == 4) if(c - pBegin == 4)
{ {
@ -691,7 +691,7 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
} }
} }
else else
if(pBegin->tqunicode() == 'f') if(pBegin->unicode() == 'f')
{ {
if(c - pBegin == 8) if(c - pBegin == 8)
{ {
@ -702,7 +702,7 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
} }
} }
if(pBegin->tqunicode() == 'i') if(pBegin->unicode() == 'i')
{ {
if(c - pBegin == 8) if(c - pBegin == 8)
{ {
@ -717,28 +717,28 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
continue; continue;
} }
} }
if(c->tqunicode() == '$') if(c->unicode() == '$')
{ {
c++; c++;
if(c->tqunicode() == '$') if(c->unicode() == '$')
{ {
c++; c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrKeyword); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrKeyword);
} else { } else {
while(c->tqunicode() && (c->isLetterOrNumber() || (c->tqunicode() == '.') || (c->tqunicode() == '_') || (c->tqunicode() == ':')))c++; while(c->unicode() && (c->isLetterOrNumber() || (c->unicode() == '.') || (c->unicode() == '_') || (c->unicode() == ':')))c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrFunction); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrFunction);
} }
continue; continue;
} }
if(c->tqunicode() == '-') if(c->unicode() == '-')
{ {
TQChar * pTmp =(TQChar *) c; TQChar * pTmp =(TQChar *) c;
c++; c++;
if(c->tqunicode() == '-') c++; if(c->unicode() == '-') c++;
if(c->isLetter()) if(c->isLetter())
{ {
while(c->tqunicode() && (c->isLetterOrNumber() || (c->tqunicode() == '_')))c++; while(c->unicode() && (c->isLetterOrNumber() || (c->unicode() == '_')))c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrKeyword); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrKeyword);
continue; continue;
} else { } else {
@ -746,35 +746,35 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
} }
} }
if(c->tqunicode() == '%') if(c->unicode() == '%')
{ {
c++; c++;
if(c->tqunicode() && (c->isLetterOrNumber() || (c->tqunicode() == ':') || (c->tqunicode() == '_'))) if(c->unicode() && (c->isLetterOrNumber() || (c->unicode() == ':') || (c->unicode() == '_')))
{ {
while(c->tqunicode() && (c->isLetterOrNumber() || (c->tqunicode() == ':') || (c->tqunicode() == '_')))c++; while(c->unicode() && (c->isLetterOrNumber() || (c->unicode() == ':') || (c->unicode() == '_')))c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrVariable); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrVariable);
continue; continue;
} }
c--; c--;
} }
if(!c->tqunicode())continue; if(!c->unicode())continue;
if(c->isLetterOrNumber() || c->tqunicode() == '_') if(c->isLetterOrNumber() || c->unicode() == '_')
{ {
c++; c++;
while(c->tqunicode() && c->isLetterOrNumber() || (c->tqunicode() == '_'))c++; while(c->unicode() && c->isLetterOrNumber() || (c->unicode() == '_'))c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrNormalText); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrNormalText);
continue; continue;
} }
if(c->tqunicode() == '\\') if(c->unicode() == '\\')
{ {
c++; c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrPunctuation); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrPunctuation);
// the next char is to be interpreted as normal text // the next char is to be interpreted as normal text
pBegin = c; pBegin = c;
if(c->tqunicode() && (c->tqunicode() != '\n')) if(c->unicode() && (c->unicode() != '\n'))
{ {
c++; c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrNormalText); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrNormalText);
@ -785,13 +785,13 @@ int KviScriptSyntaxHighlighter::highlightParagraph(const TQString &text,int endS
return IN_LINE; return IN_LINE;
} }
if(c->tqunicode() == '"') if(c->unicode() == '"')
{ {
bInString = !bInString; bInString = !bInString;
c++; c++;
setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrPunctuation); setFormat(pBegin - pBuf,c - pBegin,g_fntNormal,g_clrPunctuation);
continue; continue;
} else if(c->tqunicode() == ';') } else if(c->unicode() == ';')
{ {
if(!bInString) bNewCommand = true; // the next will be a new command if(!bInString) bNewCommand = true; // the next will be a new command
} }
@ -1124,7 +1124,7 @@ KviScriptEditorReplaceDialog::KviScriptEditorReplaceDialog( TQWidget* parent, co
emit initFind(); emit initFind();
setPaletteForegroundColor( TQColor( 0, 0, 0 ) ); setPaletteForegroundColor( TQColor( 0, 0, 0 ) );
setPaletteBackgroundColor( TQColor( 236, 233, 216 ) ); setPaletteBackgroundColor( TQColor( 236, 233, 216 ) );
TQGridLayout *tqlayout = new TQGridLayout( this, 1, 1, 11, 6, "replace tqlayout"); TQGridLayout *layout = new TQGridLayout( this, 1, 1, 11, 6, "replace layout");
m_pFindlineedit = new TQLineEdit( this, "findlineedit" ); m_pFindlineedit = new TQLineEdit( this, "findlineedit" );
#ifndef COMPILE_USE_QT4 #ifndef COMPILE_USE_QT4
@ -1133,14 +1133,14 @@ KviScriptEditorReplaceDialog::KviScriptEditorReplaceDialog( TQWidget* parent, co
m_pFindlineedit->setFrameShadow( TQLineEdit::Sunken ); m_pFindlineedit->setFrameShadow( TQLineEdit::Sunken );
#endif #endif
tqlayout->addMultiCellWidget( m_pFindlineedit, 2, 2, 1, 2 ); layout->addMultiCellWidget( m_pFindlineedit, 2, 2, 1, 2 );
m_pReplacelineedit = new TQLineEdit( this, "replacelineedit" ); m_pReplacelineedit = new TQLineEdit( this, "replacelineedit" );
#ifndef COMPILE_USE_QT4 #ifndef COMPILE_USE_QT4
m_pReplacelineedit->setFrameShape( TQLineEdit::LineEditPanel ); m_pReplacelineedit->setFrameShape( TQLineEdit::LineEditPanel );
m_pReplacelineedit->setFrameShadow( TQLineEdit::Sunken ); m_pReplacelineedit->setFrameShadow( TQLineEdit::Sunken );
#endif #endif
tqlayout->addMultiCellWidget( m_pReplacelineedit, 3, 3, 1, 2 ); layout->addMultiCellWidget( m_pReplacelineedit, 3, 3, 1, 2 );
m_pFindlineedit->setFocus(); m_pFindlineedit->setFocus();
@ -1150,36 +1150,36 @@ KviScriptEditorReplaceDialog::KviScriptEditorReplaceDialog( TQWidget* parent, co
findlabel->setAutoResize(true); findlabel->setAutoResize(true);
#endif #endif
tqlayout->addWidget( findlabel, 2, 0 ); layout->addWidget( findlabel, 2, 0 );
TQLabel *replacelabel = new TQLabel( this, "replacelabel" ); TQLabel *replacelabel = new TQLabel( this, "replacelabel" );
replacelabel->setText(tr("Replace with")); replacelabel->setText(tr("Replace with"));
#ifndef COMPILE_USE_QT4 #ifndef COMPILE_USE_QT4
replacelabel->setAutoResize(true); replacelabel->setAutoResize(true);
#endif #endif
tqlayout->addWidget( replacelabel, 3, 0 ); layout->addWidget( replacelabel, 3, 0 );
TQPushButton *cancelbutton = new TQPushButton( this, "cancelButton" ); TQPushButton *cancelbutton = new TQPushButton( this, "cancelButton" );
cancelbutton->setText(tr("&Cancel")); cancelbutton->setText(tr("&Cancel"));
tqlayout->addWidget( cancelbutton, 5, 2 ); layout->addWidget( cancelbutton, 5, 2 );
replacebutton = new TQPushButton( this, "replacebutton" ); replacebutton = new TQPushButton( this, "replacebutton" );
replacebutton->setText(tr("&Replace")); replacebutton->setText(tr("&Replace"));
replacebutton->setEnabled( FALSE ); replacebutton->setEnabled( FALSE );
tqlayout->addWidget( replacebutton, 5, 0 ); layout->addWidget( replacebutton, 5, 0 );
checkReplaceAll = new KviStyledCheckBox( this, "replaceAll" ); checkReplaceAll = new KviStyledCheckBox( this, "replaceAll" );
checkReplaceAll->setText(tr("&Replace in all Aliases")); checkReplaceAll->setText(tr("&Replace in all Aliases"));
tqlayout->addWidget( checkReplaceAll, 4, 0 ); layout->addWidget( checkReplaceAll, 4, 0 );
findNext = new TQPushButton(this, "findNext(WIP)" ); findNext = new TQPushButton(this, "findNext(WIP)" );
findNext->setText(tr("&Findnext")); findNext->setText(tr("&Findnext"));
tqlayout->addWidget( findNext, 2, 3 ); layout->addWidget( findNext, 2, 3 );
findNext->setEnabled(false); findNext->setEnabled(false);
replace = new TQPushButton(this, "replace" ); replace = new TQPushButton(this, "replace" );
replace->setText(tr("&Replace(WIP)")); replace->setText(tr("&Replace(WIP)"));
tqlayout->addWidget( replace, 3, 3 ); layout->addWidget( replace, 3, 3 );
replace->setEnabled(false); replace->setEnabled(false);
#ifndef COMPILE_USE_QT4 #ifndef COMPILE_USE_QT4

@ -873,7 +873,7 @@ static bool file_kvs_fnc_readLines(KviKvsModuleFunctionCall * c)
@switches: @switches:
!sw: -l | --local-8-bit !sw: -l | --local-8-bit
Causes the lines to be saved in local 8 bit character set instead Causes the lines to be saved in local 8 bit character set instead
of the default tqunicode encoding. of the default unicode encoding.
!sw: -a | --append !sw: -a | --append
If the file already exists, then the lines are appended to the end If the file already exists, then the lines are appended to the end
instead of overwriting the file. instead of overwriting the file.

@ -580,12 +580,12 @@ void KviFileTransferWindow::copyLocalFileToClipboard()
TQString tmp = t->localFileName(); TQString tmp = t->localFileName();
if(tmp.isEmpty())return; if(tmp.isEmpty())return;
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4
TQApplication::tqclipboard()->setText(tmp); TQApplication::clipboard()->setText(tmp);
#else #else
TQApplication::tqclipboard()->setSelectionMode(false); TQApplication::clipboard()->setSelectionMode(false);
TQApplication::tqclipboard()->setText(tmp); TQApplication::clipboard()->setText(tmp);
TQApplication::tqclipboard()->setSelectionMode(true); TQApplication::clipboard()->setSelectionMode(true);
TQApplication::tqclipboard()->setText(tmp); TQApplication::clipboard()->setText(tmp);
#endif #endif
} }

@ -138,7 +138,7 @@ TQSize KviHelpWidget::sizeHint() const
bool KviHelpWidget::eventFilter(TQObject * o, TQEvent *e) bool KviHelpWidget::eventFilter(TQObject * o, TQEvent *e)
{ {
TQClipboard *cb = TQApplication::tqclipboard(); TQClipboard *cb = TQApplication::clipboard();
if(e->type() == TQEvent::MouseButtonRelease) { if(e->type() == TQEvent::MouseButtonRelease) {
if(m_pTextBrowser->hasSelectedText()) { if(m_pTextBrowser->hasSelectedText()) {

@ -164,7 +164,7 @@ void Index::parseDocument( const TQString &filename, int docNum )
if (text.isNull()) if (text.isNull())
return; return;
bool valid = TRUE; bool valid = TRUE;
const TQChar *buf = text.tqunicode(); const TQChar *buf = text.unicode();
TQChar str[64]; TQChar str[64];
TQChar c = buf[0]; TQChar c = buf[0];
int j = 0; int j = 0;
@ -727,7 +727,7 @@ bool Index::searchForPattern( const TQStringList &patterns, const TQStringList &
bool valid = TRUE; bool valid = TRUE;
const TQChar *buf = text.tqunicode(); const TQChar *buf = text.unicode();
TQChar str[64]; TQChar str[64];

@ -145,7 +145,7 @@ void KviChannelListViewItem::paintCell(TQPainter * p,const TQColorGroup &cg,int
if ( isEnabled() || !lv ) if ( isEnabled() || !lv )
p->setPen( cg.text() ); p->setPen( cg.text() );
else if ( !isEnabled() && lv) else if ( !isEnabled() && lv)
p->setPen( lv->tqpalette().disabled().text() ); p->setPen( lv->palette().disabled().text() );
} }
KviTopicWidget::paintColoredText(p,szText,cg,height(),width); KviTopicWidget::paintColoredText(p,szText,cg,height(),width);

@ -90,67 +90,67 @@ KviLogViewMDIWindow::KviLogViewMDIWindow(KviModuleExtensionDescriptor * d,KviFra
m_pSearchTab = new TQWidget(m_pTabWidget); m_pSearchTab = new TQWidget(m_pTabWidget);
m_pTabWidget->insertTab(m_pSearchTab,__tr2qs_ctx("Filter","logview")); m_pTabWidget->insertTab(m_pSearchTab,__tr2qs_ctx("Filter","logview"));
TQGridLayout *tqlayout = new TQGridLayout(m_pSearchTab,10,2,3,5); TQGridLayout *layout = new TQGridLayout(m_pSearchTab,10,2,3,5);
m_pShowChannelsCheck = new KviStyledCheckBox(__tr2qs_ctx("Show channel logs","logview"),m_pSearchTab); m_pShowChannelsCheck = new KviStyledCheckBox(__tr2qs_ctx("Show channel logs","logview"),m_pSearchTab);
m_pShowChannelsCheck->setChecked(true); m_pShowChannelsCheck->setChecked(true);
tqlayout->addMultiCellWidget(m_pShowChannelsCheck,0,0,0,1); layout->addMultiCellWidget(m_pShowChannelsCheck,0,0,0,1);
m_pShowQueryesCheck = new KviStyledCheckBox(__tr2qs_ctx("Show query logs","logview"),m_pSearchTab); m_pShowQueryesCheck = new KviStyledCheckBox(__tr2qs_ctx("Show query logs","logview"),m_pSearchTab);
m_pShowQueryesCheck->setChecked(true); m_pShowQueryesCheck->setChecked(true);
tqlayout->addMultiCellWidget(m_pShowQueryesCheck,1,1,0,1); layout->addMultiCellWidget(m_pShowQueryesCheck,1,1,0,1);
m_pShowConsolesCheck = new KviStyledCheckBox(__tr2qs_ctx("Show console logs","logview"),m_pSearchTab); m_pShowConsolesCheck = new KviStyledCheckBox(__tr2qs_ctx("Show console logs","logview"),m_pSearchTab);
m_pShowConsolesCheck->setChecked(true); m_pShowConsolesCheck->setChecked(true);
tqlayout->addMultiCellWidget(m_pShowConsolesCheck,2,2,0,1); layout->addMultiCellWidget(m_pShowConsolesCheck,2,2,0,1);
m_pShowDccChatCheck = new KviStyledCheckBox(__tr2qs_ctx("Show DCC chat logs","logview"),m_pSearchTab); m_pShowDccChatCheck = new KviStyledCheckBox(__tr2qs_ctx("Show DCC chat logs","logview"),m_pSearchTab);
m_pShowDccChatCheck->setChecked(true); m_pShowDccChatCheck->setChecked(true);
tqlayout->addMultiCellWidget(m_pShowDccChatCheck,3,3,0,1); layout->addMultiCellWidget(m_pShowDccChatCheck,3,3,0,1);
m_pShowOtherCheck = new KviStyledCheckBox(__tr2qs_ctx("Show other logs","logview"),m_pSearchTab); m_pShowOtherCheck = new KviStyledCheckBox(__tr2qs_ctx("Show other logs","logview"),m_pSearchTab);
m_pShowOtherCheck->setChecked(true); m_pShowOtherCheck->setChecked(true);
tqlayout->addMultiCellWidget(m_pShowOtherCheck,4,4,0,1); layout->addMultiCellWidget(m_pShowOtherCheck,4,4,0,1);
TQLabel *l; TQLabel *l;
l = new TQLabel(__tr2qs_ctx("Contents filter","logview"),m_pSearchTab); l = new TQLabel(__tr2qs_ctx("Contents filter","logview"),m_pSearchTab);
tqlayout->addMultiCellWidget(l,5,5,0,1); layout->addMultiCellWidget(l,5,5,0,1);
l = new TQLabel(__tr2qs_ctx("Log name mask:","logview"),m_pSearchTab); l = new TQLabel(__tr2qs_ctx("Log name mask:","logview"),m_pSearchTab);
m_pFileNameMask = new TQLineEdit(m_pSearchTab); m_pFileNameMask = new TQLineEdit(m_pSearchTab);
connect(m_pFileNameMask,TQT_SIGNAL(returnPressed()),this,TQT_SLOT(applyFilter())); connect(m_pFileNameMask,TQT_SIGNAL(returnPressed()),this,TQT_SLOT(applyFilter()));
tqlayout->addWidget(l,6,0); layout->addWidget(l,6,0);
tqlayout->addWidget(m_pFileNameMask,6,1); layout->addWidget(m_pFileNameMask,6,1);
l = new TQLabel(__tr2qs_ctx("Log contents mask:","logview"),m_pSearchTab); l = new TQLabel(__tr2qs_ctx("Log contents mask:","logview"),m_pSearchTab);
m_pContentsMask = new TQLineEdit(m_pSearchTab); m_pContentsMask = new TQLineEdit(m_pSearchTab);
connect(m_pContentsMask,TQT_SIGNAL(returnPressed()),this,TQT_SLOT(applyFilter())); connect(m_pContentsMask,TQT_SIGNAL(returnPressed()),this,TQT_SLOT(applyFilter()));
tqlayout->addWidget(l,7,0); layout->addWidget(l,7,0);
tqlayout->addWidget(m_pContentsMask,7,1); layout->addWidget(m_pContentsMask,7,1);
m_pEnableFromFilter = new KviStyledCheckBox(__tr2qs_ctx("Only older than","logview"),m_pSearchTab); m_pEnableFromFilter = new KviStyledCheckBox(__tr2qs_ctx("Only older than","logview"),m_pSearchTab);
m_pFromDateEdit = new TQDateEdit(m_pSearchTab); m_pFromDateEdit = new TQDateEdit(m_pSearchTab);
m_pFromDateEdit->setDate(TQDate::currentDate()); m_pFromDateEdit->setDate(TQDate::currentDate());
tqlayout->addWidget(m_pEnableFromFilter,8,0); layout->addWidget(m_pEnableFromFilter,8,0);
tqlayout->addWidget(m_pFromDateEdit,8,1); layout->addWidget(m_pFromDateEdit,8,1);
connect(m_pEnableFromFilter,TQT_SIGNAL(toggled(bool)),m_pFromDateEdit,TQT_SLOT(setEnabled(bool))); connect(m_pEnableFromFilter,TQT_SIGNAL(toggled(bool)),m_pFromDateEdit,TQT_SLOT(setEnabled(bool)));
m_pFromDateEdit->setEnabled(false); m_pFromDateEdit->setEnabled(false);
m_pEnableToFilter = new KviStyledCheckBox(__tr2qs_ctx("Only newier than","logview"),m_pSearchTab); m_pEnableToFilter = new KviStyledCheckBox(__tr2qs_ctx("Only newier than","logview"),m_pSearchTab);
m_pToDateEdit = new TQDateEdit(m_pSearchTab); m_pToDateEdit = new TQDateEdit(m_pSearchTab);
m_pToDateEdit->setDate(TQDate::currentDate()); m_pToDateEdit->setDate(TQDate::currentDate());
tqlayout->addWidget(m_pEnableToFilter,9,0); layout->addWidget(m_pEnableToFilter,9,0);
tqlayout->addWidget(m_pToDateEdit,9,1); layout->addWidget(m_pToDateEdit,9,1);
connect(m_pEnableToFilter,TQT_SIGNAL(toggled(bool)),m_pToDateEdit,TQT_SLOT(setEnabled(bool))); connect(m_pEnableToFilter,TQT_SIGNAL(toggled(bool)),m_pToDateEdit,TQT_SLOT(setEnabled(bool)));
m_pToDateEdit->setEnabled(false); m_pToDateEdit->setEnabled(false);
TQPushButton *pb = new TQPushButton(__tr2qs_ctx("Apply filter","logview"),m_pSearchTab); TQPushButton *pb = new TQPushButton(__tr2qs_ctx("Apply filter","logview"),m_pSearchTab);
connect(pb,TQT_SIGNAL(clicked()),this,TQT_SLOT(applyFilter())); connect(pb,TQT_SIGNAL(clicked()),this,TQT_SLOT(applyFilter()));
tqlayout->addWidget(pb,10,1); layout->addWidget(pb,10,1);
TQWidget *w = new TQWidget(m_pSearchTab); TQWidget *w = new TQWidget(m_pSearchTab);
w->setSizePolicy(TQSizePolicy::Ignored,TQSizePolicy::Ignored); w->setSizePolicy(TQSizePolicy::Ignored,TQSizePolicy::Ignored);
tqlayout->addWidget(w,11,1); layout->addWidget(w,11,1);
m_pIrcView = new KviIrcView(m_pSplitter,g_pFrame,this); m_pIrcView = new KviIrcView(m_pSplitter,g_pFrame,this);
#ifdef COMPILE_USE_QT4 #ifdef COMPILE_USE_QT4

@ -77,7 +77,7 @@ protected:
TQPixmap m_pixBackgroundHighlighted; TQPixmap m_pixBackgroundHighlighted;
TQPixmap m_pixForeground; // we paint the stuff HERE TQPixmap m_pixForeground; // we paint the stuff HERE
// Notifier graphic tqlayout // Notifier graphic layout
TQPixmap m_pixBckgrnd; TQPixmap m_pixBckgrnd;
TQImage m_imgBuffer; // here we merge the two images TQImage m_imgBuffer; // here we merge the two images

@ -48,8 +48,8 @@
@description: @description:
This widget organizes buttons in a group. This widget organizes buttons in a group.
It will be usually a parent for other child controls. It will be usually a parent for other child controls.
You can either use a child tqlayout to manage the children geometries You can either use a child layout to manage the children geometries
or use $setColumnLayout function to manage the tqlayout automatically. or use $setColumnLayout function to manage the layout automatically.
The class ineriths groupbox. The class ineriths groupbox.
@functions: @functions:

@ -49,11 +49,11 @@
[class]widget[/class] [class]widget[/class]
@description: @description:
A window dockable to the KVIrc main frame borders (like a toolbar). A window dockable to the KVIrc main frame borders (like a toolbar).
The window has an implicit tqlayout that will automatically manage The window has an implicit layout that will automatically manage
the children depending on the dock window's orientation. the children depending on the dock window's orientation.
@functions: @functions:
!fn: $addWidget(<widget:hobject>) !fn: $addWidget(<widget:hobject>)
Adds <widget> to the internal tqlayout of this dock window.[br] Adds <widget> to the internal layout of this dock window.[br]
The widget must be a child of this dock window (otherwise strange things may happen). The widget must be a child of this dock window (otherwise strange things may happen).
!fn: <string> $orientation() !fn: <string> $orientation()
Returns the string "vertical" or "horizontal" depending on the orientation of this dock window. Returns the string "vertical" or "horizontal" depending on the orientation of this dock window.

@ -60,8 +60,8 @@ const int align_cod[] = {
@description: @description:
This widget can be used to display a groupbox. This widget can be used to display a groupbox.
It will be usually a parent for other child controls. It will be usually a parent for other child controls.
You can either use a child tqlayout to manage the children geometries You can either use a child layout to manage the children geometries
or use $setColumnLayout to manage the tqlayout automatically. or use $setColumnLayout to manage the layout automatically.
@functions: @functions:
!fn: $setTitle(<text:String>) !fn: $setTitle(<text:String>)
Sets the group box title to <text>. Sets the group box title to <text>.
@ -96,7 +96,7 @@ const int align_cod[] = {
!fn: $setOrientation<orientation:string> !fn: $setOrientation<orientation:string>
Sets the group box's orientation. Valid values are:Qt::Horizontal,Qt::Vertical. Sets the group box's orientation. Valid values are:Qt::Horizontal,Qt::Vertical.
!fn: $setColumnLayout(<columns:integer>,<orientation:string>) !fn: $setColumnLayout(<columns:integer>,<orientation:string>)
Enables the automatic tqlayout management. The children are arranged in n columns with the specified orientation.[br] Enables the automatic layout management. The children are arranged in n columns with the specified orientation.[br]
Valid values for <orientation> are:Qt::Horizontal,Qt::Vertical. Valid values for <orientation> are:Qt::Horizontal,Qt::Vertical.
@examples: @examples:
[example] [example]
@ -120,16 +120,16 @@ const int align_cod[] = {
%inputpass->$setechomode("password")[br] %inputpass->$setechomode("password")[br]
[br] [br]
#now lets' layouting the groupbox's element's.[br] #now lets' layouting the groupbox's element's.[br]
%layoutgb=$new(tqlayout,%gb)[br] %layoutgb=$new(layout,%gb)[br]
%layoutgb->$setmargin(20)[br] %layoutgb->$setmargin(20)[br]
%layoutgb->$addwidget(%labeluser,0,0)[br] %layoutgb->$addwidget(%labeluser,0,0)[br]
%layoutgb->$addwidget(%labelpass,1,0)[br] %layoutgb->$addwidget(%labelpass,1,0)[br]
%layoutgb->$addwidget(%inputuser,0,1)[br] %layoutgb->$addwidget(%inputuser,0,1)[br]
%layoutgb->$addwidget(%inputpass,1,1)[br] %layoutgb->$addwidget(%inputpass,1,1)[br]
[br] [br]
# now we create a fake widget and managing the two buttons tqlayout.[br] # now we create a fake widget and managing the two buttons layout.[br]
%fakewidget=$new(widget,%widget)[br] %fakewidget=$new(widget,%widget)[br]
%layoutbtn=$new(tqlayout,%fakewidget)[br] %layoutbtn=$new(layout,%fakewidget)[br]
%btnok=$new(button,%fakewidget)[br] %btnok=$new(button,%fakewidget)[br]
%btnok->$settext("OK")[br] %btnok->$settext("OK")[br]
%btncancel=$new(button,%fakewidget)[br] %btncancel=$new(button,%fakewidget)[br]
@ -137,13 +137,13 @@ const int align_cod[] = {
%layoutbtn->$addwidget(%btnok,0,0)[br] %layoutbtn->$addwidget(%btnok,0,0)[br]
%layoutbtn->$addwidget(%btncancel,0,1)[br] %layoutbtn->$addwidget(%btncancel,0,1)[br]
[br] [br]
#And finally we create a main tqlayout with the groupbox (and its "children")[br] #And finally we create a main layout with the groupbox (and its "children")[br]
#and fakewiget (with its buttons children). #and fakewiget (with its buttons children).
%maintqlayout=$new(tqlayout,%widget)[br] %mainlayout=$new(layout,%widget)[br]
%maintqlayout->$setspacing(10)[br] %mainlayout->$setspacing(10)[br]
%maintqlayout->$setmargin(10)[br] %mainlayout->$setmargin(10)[br]
%maintqlayout->$addwidget(%gb,0,0)[br] %mainlayout->$addwidget(%gb,0,0)[br]
%maintqlayout->$addwidget(%fakewidget,1,0)[br] %mainlayout->$addwidget(%fakewidget,1,0)[br]
[br] [br]
#Let's show our nice login request =D ! [br] #Let's show our nice login request =D ! [br]
%widget->$show()[br] %widget->$show()[br]

@ -44,7 +44,7 @@
!fn: $setSpacing(<spacing:uint>) !fn: $setSpacing(<spacing:uint>)
Sets the default spacing of the widgets in pixels Sets the default spacing of the widgets in pixels
!fn: $setMargin(<margin:uint>) !fn: $setMargin(<margin:uint>)
Sets the dimension of the tqlayout margin : the distance from the border to the outermost child widget edges. Sets the dimension of the layout margin : the distance from the border to the outermost child widget edges.
!fn: $setStretchFactor(<widget:hobject>,<stretch:uint>) !fn: $setStretchFactor(<widget:hobject>,<stretch:uint>)
Sets the stretch factor of widget to stretch. Sets the stretch factor of widget to stretch.
*/ */

@ -40,11 +40,11 @@
/* /*
@doc: tqlayout @doc: layout
@keyterms: @keyterms:
tqlayout object class, child widgets layout object class, child widgets
@title: @title:
tqlayout class layout class
@type: @type:
class class
@short: @short:
@ -52,25 +52,25 @@
@inherits: @inherits:
[class]object[/class] [class]object[/class]
@description: @description:
The tqlayout is a geometry management tool for child widgets. The layout is a geometry management tool for child widgets.
You create a tqlayout , give it some widgets to manage and it will tqlayout them You create a layout , give it some widgets to manage and it will layout them
automatically.[br] automatically.[br]
The parent of the tqlayout must be the widget for which child widget geometries have to be managed. The parent of the layout must be the widget for which child widget geometries have to be managed.
A tqlayout is a grid of NxM cells in which you insert child widgets with [classfnc:tqlayout]$addWidget[/classfnc]().[br] A layout is a grid of NxM cells in which you insert child widgets with [classfnc:layout]$addWidget[/classfnc]().[br]
Widgets that must span multiple cells can be added to the tqlayout with [classfnc:tqlayout]$addMultiCellWidget[/classfnc]().[br] Widgets that must span multiple cells can be added to the layout with [classfnc:layout]$addMultiCellWidget[/classfnc]().[br]
@functions: @functions:
!fn: $addWidget(<widget:object widget>,<row:uint>,<column:uint>) !fn: $addWidget(<widget:object widget>,<row:uint>,<column:uint>)
Adds a widget to this tqlayout placing it at position <row>,<column> in the grid Adds a widget to this layout placing it at position <row>,<column> in the grid
!fn: $addMultiCellWidget(<widget:object widget>,<start_row:uint>,<end_row:uint>,<start_col:uint>,<end_col:uint>) !fn: $addMultiCellWidget(<widget:object widget>,<start_row:uint>,<end_row:uint>,<start_col:uint>,<end_col:uint>)
Adds a widget to this tqlayout spanning multiple grid cells Adds a widget to this layout spanning multiple grid cells
!fn: $setRowStretch(<row:uint>,<stretch:uint>) !fn: $setRowStretch(<row:uint>,<stretch:uint>)
Sets the stretch value for a particular row of this tqlayout. The <stretch_value> Sets the stretch value for a particular row of this layout. The <stretch_value>
must be a positive integer. The rows with bigger stretch values will take more space must be a positive integer. The rows with bigger stretch values will take more space
in the tqlayout. in the layout.
!fn: $setColStretch(<column:uint>,<stretch:uint>) !fn: $setColStretch(<column:uint>,<stretch:uint>)
Sets the stretch value for a particular column in this tqlayout. The <stretch_value> Sets the stretch value for a particular column in this layout. The <stretch_value>
must be a positive integer. The rows with bigger stretch values will take more space must be a positive integer. The rows with bigger stretch values will take more space
in the tqlayout. in the layout.
!fn: $addRowSpacing(<row:uint>,<spacing:uint>) !fn: $addRowSpacing(<row:uint>,<spacing:uint>)
Sets the minimum height of the specified <row> to <spacing> which must be a positive integer Sets the minimum height of the specified <row> to <spacing> which must be a positive integer
!fn: $addColSpacing(<column:uint>,<spacing:uint>) !fn: $addColSpacing(<column:uint>,<spacing:uint>)
@ -78,18 +78,18 @@
!fn: $setSpacing(<spacing:uint>) !fn: $setSpacing(<spacing:uint>)
Sets the default spacing of the widgets in pixels Sets the default spacing of the widgets in pixels
!fn: $setMargin(<margin:uint>) !fn: $setMargin(<margin:uint>)
Sets the dimension of the tqlayout margin : the distance from the border to the outermost child widget edges. Sets the dimension of the layout margin : the distance from the border to the outermost child widget edges.
!fn: $setResizeMode(<resize_mode:string>) !fn: $setResizeMode(<resize_mode:string>)
Sets the resize mode of the parent widget in relation to this tqlayout. Sets the resize mode of the parent widget in relation to this layout.
<mode> can be one of:[br] <mode> can be one of:[br]
-Auto: this is the default[br] -Auto: this is the default[br]
-Fixed: the parent widget of this tqlayout is resized to the "sizeHint" value and it cannot be resized by the user.[br] -Fixed: the parent widget of this layout is resized to the "sizeHint" value and it cannot be resized by the user.[br]
-Minimum: the minimum size of the parent widget of this tqlayout is set to minimumSize() and it cannot be smaller[br] -Minimum: the minimum size of the parent widget of this layout is set to minimumSize() and it cannot be smaller[br]
-FreeResize: the parent widget of this tqlayout is not constrained at all[br] -FreeResize: the parent widget of this layout is not constrained at all[br]
*/ */
KVSO_BEGIN_REGISTERCLASS(KviKvsObject_layout,"tqlayout","object") KVSO_BEGIN_REGISTERCLASS(KviKvsObject_layout,"layout","object")
KVSO_REGISTER_HANDLER(KviKvsObject_layout,"addWidget", functionAddWidget) KVSO_REGISTER_HANDLER(KviKvsObject_layout,"addWidget", functionAddWidget)
KVSO_REGISTER_HANDLER(KviKvsObject_layout,"addMultiCellWidget", functionAddMultiCellWidget) KVSO_REGISTER_HANDLER(KviKvsObject_layout,"addMultiCellWidget", functionAddMultiCellWidget)
KVSO_REGISTER_HANDLER(KviKvsObject_layout,"setRowStretch", functionSetRowStretch) KVSO_REGISTER_HANDLER(KviKvsObject_layout,"setRowStretch", functionSetRowStretch)
@ -116,7 +116,7 @@ bool KviKvsObject_layout::init(KviKvsRunTimeContext * pContext,KviKvsVariantList
if(!w) if(!w)
{ {
pContext->warning(__tr2qs("The parent of a tqlayout must be a widget!")); pContext->warning(__tr2qs("The parent of a layout must be a widget!"));
return false; return false;
} }
setObject(TQT_TQOBJECT(new TQGridLayout(w))); setObject(TQT_TQOBJECT(new TQGridLayout(w)));

@ -323,7 +323,7 @@
}[br] }[br]
}[br] }[br]
[br] [br]
%lay=$new(tqlayout,%Hello)[br] %lay=$new(layout,%Hello)[br]
%lay->$addwidget(%Btn,4,0)[br] %lay->$addwidget(%Btn,4,0)[br]
%Hello->$setBackgroundColor("000000");[br] %Hello->$setBackgroundColor("000000");[br]
%Hello->$setmaximumwidth(800)[br] %Hello->$setmaximumwidth(800)[br]

@ -89,7 +89,7 @@
{[br] {[br]
#Geometry of the widget and setting-up of popupmenu [br] #Geometry of the widget and setting-up of popupmenu [br]
$$->$setGeometry(%X,%Y,100,100)[br] $$->$setGeometry(%X,%Y,100,100)[br]
$$->%lay=$new(tqlayout,$$)[br] $$->%lay=$new(layout,$$)[br]
#Here we generate a cicle to create our labels inside the widget.[br] #Here we generate a cicle to create our labels inside the widget.[br]
%i=0[br] %i=0[br]
while (%i<10)[br] while (%i<10)[br]

@ -82,7 +82,7 @@
%tt=$new(test)[br] %tt=$new(test)[br]
%A=$new(widget)[br] %A=$new(widget)[br]
%A->$setGeometry(100,100,400,300)[br] %A->$setGeometry(100,100,400,300)[br]
%layoutA=$new(tqlayout,%A)[br] %layoutA=$new(layout,%A)[br]
%Ainput=$new(lineedit,%A)[br] %Ainput=$new(lineedit,%A)[br]
#%Aoutput=$new(textedit,%A)// coming soon in the new texteditor class[br] #%Aoutput=$new(textedit,%A)// coming soon in the new texteditor class[br]
%Aoutput=$new(label,%A)[br] %Aoutput=$new(label,%A)[br]

@ -94,7 +94,7 @@
%secondtab=$new(widget,%Tabwidget) %secondtab=$new(widget,%Tabwidget)
# Now we'll create the item to put in to tab's pages. # Now we'll create the item to put in to tab's pages.
%layoutfirsttab=$new(tqlayout,%firsttab) %layoutfirsttab=$new(layout,%firsttab)
%labelbt=$new(label,%firsttab) %labelbt=$new(label,%firsttab)
%labelbt->$settext(Botton Tab) %labelbt->$settext(Botton Tab)
%labeltt=$new(label,%firsttab) %labeltt=$new(label,%firsttab)
@ -104,7 +104,7 @@
%buttontt=$new(button,%firsttab) %buttontt=$new(button,%firsttab)
%buttontt->$settext("To &Top") %buttontt->$settext("To &Top")
# Now we'll give a tqlayout to all items. # Now we'll give a layout to all items.
# This also allows to use privateimpl without making buttons global variables # This also allows to use privateimpl without making buttons global variables
%layoutfirsttab->$addwidget(%labelbt,0,0) %layoutfirsttab->$addwidget(%labelbt,0,0)
%layoutfirsttab->$addwidget(%labeltt,0,1) %layoutfirsttab->$addwidget(%labeltt,0,1)
@ -125,7 +125,7 @@
} }
# We do the same work with the second tab's page. # We do the same work with the second tab's page.
%layoutsecondtab=$new(tqlayout,%secondtab) %layoutsecondtab=$new(layout,%secondtab)
%labelwp=$new(label,%secondtab) %labelwp=$new(label,%secondtab)
%labelwp->$settext("Enjoy the new Class provided by") %labelwp->$settext("Enjoy the new Class provided by")
%layoutsecondtab->$addwidget(%labelwp,0,0) %layoutsecondtab->$addwidget(%labelwp,0,0)

@ -44,7 +44,7 @@
!fn: $setSpacing(<spacing:int>) !fn: $setSpacing(<spacing:int>)
Sets the default spacing of the widgets in pixels Sets the default spacing of the widgets in pixels
!fn: $setMargin(<margin:int>) !fn: $setMargin(<margin:int>)
Sets the dimension of the tqlayout margin : the distance from the border to the outermost child widget edges. Sets the dimension of the layout margin : the distance from the border to the outermost child widget edges.
!fn: $setStretchFactor(<widget:hobject>,<stretch:uint>) !fn: $setStretchFactor(<widget:hobject>,<stretch:uint>)
Sets the stretch factor of widget to stretch. Sets the stretch factor of widget to stretch.
*/ */

@ -167,19 +167,19 @@ const int widgettypes_cod[] = {
!fn: $setMinimumWidth(<value>) !fn: $setMinimumWidth(<value>)
Sets the minimum width of this widget to <value>. Sets the minimum width of this widget to <value>.
The user will not be able to resize the widget to a smaller The user will not be able to resize the widget to a smaller
value. This value is also used by the [class:tqlayout]tqlayout class[/class]. value. This value is also used by the [class:layout]layout class[/class].
!fn: $setMinimumHeight(<value>) !fn: $setMinimumHeight(<value>)
Sets the minimum height of this widget to <value>. Sets the minimum height of this widget to <value>.
The user will not be able to resize the widget to a smaller The user will not be able to resize the widget to a smaller
value. This value is also used by the [class:tqlayout]tqlayout class[/class]. value. This value is also used by the [class:layout]layout class[/class].
!fn: $setMaximumWidth(<value>) !fn: $setMaximumWidth(<value>)
Sets the maximum width of this widget to <value>. Sets the maximum width of this widget to <value>.
The user will not be able to resize the widget to a bigger The user will not be able to resize the widget to a bigger
value. This value is also used by the [class:tqlayout]tqlayout class[/class]. value. This value is also used by the [class:layout]layout class[/class].
!fn: $setMaximumHeight(<value>) !fn: $setMaximumHeight(<value>)
Sets the maximum height of this widget to <value>. Sets the maximum height of this widget to <value>.
The user will not be able to resize the widget to a bigger The user will not be able to resize the widget to a bigger
value. This value is also used by the [class:tqlayout]tqlayout class[/class]. value. This value is also used by the [class:layout]layout class[/class].
!fn: $move(<x_or_array>[,<y>]) !fn: $move(<x_or_array>[,<y>])
Moves this widget to the coordinate <x> and <y> relative to its Moves this widget to the coordinate <x> and <y> relative to its
parent widget (or the desktop if this widget is a toplevel one). parent widget (or the desktop if this widget is a toplevel one).
@ -1616,7 +1616,7 @@ bool KviKvsObject_widget::function_addWidgetToWrappedLayout(KviKvsObjectFunction
c->warning(__tr2qs("Widget parameter is not a valid object")); c->warning(__tr2qs("Widget parameter is not a valid object"));
return true; return true;
} }
TQLayout *lay=widget()->tqlayout(); TQLayout *lay=widget()->layout();
if (!lay) if (!lay)
{ {
c->warning(__tr2qs("No Layout associated to the widget ")); c->warning(__tr2qs("No Layout associated to the widget "));

@ -110,7 +110,7 @@
constructor[br] constructor[br]
{[br] {[br]
$$->$setGeometry(%X,%Y,100,100)[br] $$->$setGeometry(%X,%Y,100,100)[br]
$$->%lay=$new(tqlayout,$$)[br] $$->%lay=$new(layout,$$)[br]
%i=0[br] %i=0[br]
while (%i<10)[br] while (%i<10)[br]
{[br] {[br]

@ -70,7 +70,7 @@ KviGeneralOptionsFrontWidget::KviGeneralOptionsFrontWidget(TQWidget *parent,cons
l->setWordWrap(true); l->setWordWrap(true);
#endif #endif
l->setAlignment(TQt::AlignTop); l->setAlignment(TQt::AlignTop);
tqlayout()->addWidget(l,0,0); layout()->addWidget(l,0,0);
} }
KviGeneralOptionsFrontWidget::~KviGeneralOptionsFrontWidget() KviGeneralOptionsFrontWidget::~KviGeneralOptionsFrontWidget()

@ -47,7 +47,7 @@ KviAntispamOptionsWidget::KviAntispamOptionsWidget(TQWidget * parent)
reenableStuff(true); reenableStuff(true);
tqlayout()->setRowStretch(2,1); layout()->setRowStretch(2,1);
} }
KviAntispamOptionsWidget::~KviAntispamOptionsWidget() KviAntispamOptionsWidget::~KviAntispamOptionsWidget()

@ -311,7 +311,7 @@ KviIdentityGeneralOptionsWidget::KviIdentityGeneralOptionsWidget(TQWidget * pare
createLayout(3,1); createLayout(3,1);
tqlayout()->setMargin(10); layout()->setMargin(10);
KviTalGroupBox * gbox = addGroupBox(0,0,0,0,1,Qt::Horizontal,__tr2qs_ctx("Basic Properties","options")); KviTalGroupBox * gbox = addGroupBox(0,0,0,0,1,Qt::Horizontal,__tr2qs_ctx("Basic Properties","options"));
KviTalHBox * hb = new KviTalHBox(gbox); KviTalHBox * hb = new KviTalHBox(gbox);
@ -492,7 +492,7 @@ KviIdentityAvatarOptionsWidget::KviIdentityAvatarOptionsWidget(TQWidget * parent
: KviOptionsWidget(parent) : KviOptionsWidget(parent)
{ {
createLayout(4,1); createLayout(4,1);
tqlayout()->setMargin(10); layout()->setMargin(10);
m_pLocalAvatar = new KviPixmap(KVI_OPTION_PIXMAP(KviOption_pixmapMyAvatar)); m_pLocalAvatar = new KviPixmap(KVI_OPTION_PIXMAP(KviOption_pixmapMyAvatar));
@ -540,7 +540,7 @@ KviIdentityAvatarOptionsWidget::KviIdentityAvatarOptionsWidget(TQWidget * parent
connect(m_pChooseAvatarButton,TQT_SIGNAL(clicked()),this,TQT_SLOT(chooseAvatar())); connect(m_pChooseAvatarButton,TQT_SIGNAL(clicked()),this,TQT_SLOT(chooseAvatar()));
tqlayout()->setRowStretch(1,2); layout()->setRowStretch(1,2);
} }
KviIdentityAvatarOptionsWidget::~KviIdentityAvatarOptionsWidget() KviIdentityAvatarOptionsWidget::~KviIdentityAvatarOptionsWidget()
@ -678,7 +678,7 @@ KviIdentityAdvancedOptionsWidget::KviIdentityAdvancedOptionsWidget(TQWidget * pa
createLayout(2,1); createLayout(2,1);
tqlayout()->setMargin(10); layout()->setMargin(10);
KviTalGroupBox * gbox = addGroupBox(0,0,0,0,1,Qt::Horizontal,__tr2qs_ctx("User Mode","options")); KviTalGroupBox * gbox = addGroupBox(0,0,0,0,1,Qt::Horizontal,__tr2qs_ctx("User Mode","options"));
m_pISelector = addBoolSelector(gbox,__tr2qs_ctx("Invisible (+i)","options"),&m_bI); m_pISelector = addBoolSelector(gbox,__tr2qs_ctx("Invisible (+i)","options"),&m_bI);

@ -92,7 +92,7 @@ KviInputLookOptionsWidget::KviInputLookOptionsWidget(TQWidget * parent)
} }
tqlayout()->setRowStretch(7,1); layout()->setRowStretch(7,1);
} }
KviInputLookOptionsWidget::~KviInputLookOptionsWidget() KviInputLookOptionsWidget::~KviInputLookOptionsWidget()

@ -104,13 +104,13 @@ KviThemeTransparencyOptionsWidget::KviThemeTransparencyOptionsWidget(TQWidget *
m_pGlobalBackgroundPixmapSelector = addPixmapSelector(0,6,1,6,__tr2qs_ctx("Transparency blend image:","options"),KviOption_pixmapGlobalTransparencyBackground, m_pGlobalBackgroundPixmapSelector = addPixmapSelector(0,6,1,6,__tr2qs_ctx("Transparency blend image:","options"),KviOption_pixmapGlobalTransparencyBackground,
KVI_OPTION_BOOL(KviOption_boolUseGlobalPseudoTransparency) && !KVI_OPTION_BOOL(KviOption_boolObtainGlobalBackgroundFromKde)); KVI_OPTION_BOOL(KviOption_boolUseGlobalPseudoTransparency) && !KVI_OPTION_BOOL(KviOption_boolObtainGlobalBackgroundFromKde));
tqlayout()->setRowStretch(6,1); layout()->setRowStretch(6,1);
connect(m_pObtainBackgroundFromKdeBoolSelector,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(enableGlobalBackgroundPixmapSelector(bool))); connect(m_pObtainBackgroundFromKdeBoolSelector,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(enableGlobalBackgroundPixmapSelector(bool)));
#else //!COMPILE_KDE_SUPPORT #else //!COMPILE_KDE_SUPPORT
m_pGlobalBackgroundPixmapSelector = addPixmapSelector(0,4,1,4,__tr2qs_ctx("Transparency blend image:","options"),KviOption_pixmapGlobalTransparencyBackground, m_pGlobalBackgroundPixmapSelector = addPixmapSelector(0,4,1,4,__tr2qs_ctx("Transparency blend image:","options"),KviOption_pixmapGlobalTransparencyBackground,
KVI_OPTION_BOOL(KviOption_boolUseGlobalPseudoTransparency)); KVI_OPTION_BOOL(KviOption_boolUseGlobalPseudoTransparency));
tqlayout()->setRowStretch(4,1); layout()->setRowStretch(4,1);
#endif //!COMPILE_KDE_SUPPORT #endif //!COMPILE_KDE_SUPPORT
connect(m_pUseTransparencyBoolSelector,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(enableGlobalBackgroundPixmapSelector(bool))); connect(m_pUseTransparencyBoolSelector,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(enableGlobalBackgroundPixmapSelector(bool)));
connect(m_pUseTransparencyBoolSelector,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(enableUpdateKdeBackgroundBoolSelector(bool))); connect(m_pUseTransparencyBoolSelector,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(enableUpdateKdeBackgroundBoolSelector(bool)));
@ -177,7 +177,7 @@ KviThemeMdiAreaOptionsWidget::KviThemeMdiAreaOptionsWidget(TQWidget * parent)
addColorSelector(0,0,0,0,__tr2qs_ctx("Background","options"),KviOption_colorMdiBackground); addColorSelector(0,0,0,0,__tr2qs_ctx("Background","options"),KviOption_colorMdiBackground);
addPixmapSelector(0,1,0,1,__tr2qs_ctx("Background Image","options"),KviOption_pixmapMdiBackground); addPixmapSelector(0,1,0,1,__tr2qs_ctx("Background Image","options"),KviOption_pixmapMdiBackground);
tqlayout()->setRowStretch(1,1); layout()->setRowStretch(1,1);
} }
KviThemeMdiAreaOptionsWidget::~KviThemeMdiAreaOptionsWidget() KviThemeMdiAreaOptionsWidget::~KviThemeMdiAreaOptionsWidget()
@ -204,7 +204,7 @@ KviThemeToolBarAppletsOptionsWidget::KviThemeToolBarAppletsOptionsWidget(TQWidge
addPixmapSelector(0,8,0,8,__tr2qs_ctx("Background Image","options"),KviOption_pixmapIrcToolBarAppletBackground); addPixmapSelector(0,8,0,8,__tr2qs_ctx("Background Image","options"),KviOption_pixmapIrcToolBarAppletBackground);
tqlayout()->setRowStretch(8,1); layout()->setRowStretch(8,1);
} }
KviThemeToolBarAppletsOptionsWidget::~KviThemeToolBarAppletsOptionsWidget() KviThemeToolBarAppletsOptionsWidget::~KviThemeToolBarAppletsOptionsWidget()

@ -98,7 +98,7 @@ KviIrcViewLookOptionsWidget::KviIrcViewLookOptionsWidget(TQWidget * parent)
m_pVerticalAlign->setCurrentItem(0); m_pVerticalAlign->setCurrentItem(0);
} }
tqlayout()->setRowStretch(2,1); layout()->setRowStretch(2,1);
} }
KviIrcViewLookOptionsWidget::~KviIrcViewLookOptionsWidget() KviIrcViewLookOptionsWidget::~KviIrcViewLookOptionsWidget()

@ -77,72 +77,72 @@ KviMediaTypesOptionsWidget::KviMediaTypesOptionsWidget(TQWidget * parent)
connect(m_pListView,TQT_SIGNAL(currentChanged(KviTalListViewItem *)),this,TQT_SLOT(currentItemChanged(KviTalListViewItem *))); connect(m_pListView,TQT_SIGNAL(currentChanged(KviTalListViewItem *)),this,TQT_SLOT(currentItemChanged(KviTalListViewItem *)));
tqlayout()->addMultiCellWidget(m_pListView,0,0,0,2); layout()->addMultiCellWidget(m_pListView,0,0,0,2);
TQLabel * l = new TQLabel(__tr2qs_ctx("Description:","options"),this); TQLabel * l = new TQLabel(__tr2qs_ctx("Description:","options"),this);
tqlayout()->addWidget(l,1,0); layout()->addWidget(l,1,0);
m_pDescription = new TQLineEdit(this); m_pDescription = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pDescription,1,1,1,2); layout()->addMultiCellWidget(m_pDescription,1,1,1,2);
l = new TQLabel(__tr2qs_ctx("MIME type:","options"),this); l = new TQLabel(__tr2qs_ctx("MIME type:","options"),this);
tqlayout()->addWidget(l,2,0); layout()->addWidget(l,2,0);
m_pIanaType = new TQLineEdit(this); m_pIanaType = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pIanaType,2,2,1,2); layout()->addMultiCellWidget(m_pIanaType,2,2,1,2);
l = new TQLabel(__tr2qs_ctx("File pattern:","options"),this); l = new TQLabel(__tr2qs_ctx("File pattern:","options"),this);
tqlayout()->addWidget(l,3,0); layout()->addWidget(l,3,0);
m_pFileMask = new TQLineEdit(this); m_pFileMask = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pFileMask,3,3,1,2); layout()->addMultiCellWidget(m_pFileMask,3,3,1,2);
l = new TQLabel(__tr2qs_ctx("Magic bytes:","options"),this); l = new TQLabel(__tr2qs_ctx("Magic bytes:","options"),this);
tqlayout()->addWidget(l,4,0); layout()->addWidget(l,4,0);
m_pMagicBytes = new TQLineEdit(this); m_pMagicBytes = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pMagicBytes,4,4,1,2); layout()->addMultiCellWidget(m_pMagicBytes,4,4,1,2);
l = new TQLabel(__tr2qs_ctx("Save path:","options"),this); l = new TQLabel(__tr2qs_ctx("Save path:","options"),this);
tqlayout()->addWidget(l,5,0); layout()->addWidget(l,5,0);
m_pSavePath = new TQLineEdit(this); m_pSavePath = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pSavePath,5,5,1,2); layout()->addMultiCellWidget(m_pSavePath,5,5,1,2);
l = new TQLabel(__tr2qs_ctx("Local open command:","options"),this); l = new TQLabel(__tr2qs_ctx("Local open command:","options"),this);
tqlayout()->addWidget(l,6,0); layout()->addWidget(l,6,0);
m_pCommandline = new TQLineEdit(this); m_pCommandline = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pCommandline,6,6,1,2); layout()->addMultiCellWidget(m_pCommandline,6,6,1,2);
#ifdef COMPILE_INFO_TIPS #ifdef COMPILE_INFO_TIPS
mergeTip(m_pCommandline,__tr2qs_ctx("<center>This field contains the command to execute to open a local file.<br>" \ mergeTip(m_pCommandline,__tr2qs_ctx("<center>This field contains the command to execute to open a local file.<br>" \
"<tt>$0</tt> is used in place of the filename</center>","options")); "<tt>$0</tt> is used in place of the filename</center>","options"));
#endif #endif
l = new TQLabel(__tr2qs_ctx("Remote open command:","options"),this); l = new TQLabel(__tr2qs_ctx("Remote open command:","options"),this);
tqlayout()->addWidget(l,7,0); layout()->addWidget(l,7,0);
m_pRemoteExecCommandline = new TQLineEdit(this); m_pRemoteExecCommandline = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pRemoteExecCommandline,7,7,1,2); layout()->addMultiCellWidget(m_pRemoteExecCommandline,7,7,1,2);
#ifdef COMPILE_INFO_TIPS #ifdef COMPILE_INFO_TIPS
mergeTip(m_pRemoteExecCommandline,__tr2qs_ctx("<center>This field contains the command to execute when automatically opening a received file.<br>" \ mergeTip(m_pRemoteExecCommandline,__tr2qs_ctx("<center>This field contains the command to execute when automatically opening a received file.<br>" \
"<tt>$0</tt> is used in place of the filename</center>","options")); "<tt>$0</tt> is used in place of the filename</center>","options"));
#endif #endif
l = new TQLabel(__tr2qs_ctx("Icon","options"),this); l = new TQLabel(__tr2qs_ctx("Icon","options"),this);
tqlayout()->addWidget(l,8,0); layout()->addWidget(l,8,0);
m_pIcon = new TQLineEdit(this); m_pIcon = new TQLineEdit(this);
tqlayout()->addMultiCellWidget(m_pIcon,8,8,1,2); layout()->addMultiCellWidget(m_pIcon,8,8,1,2);
TQFrame * f = new TQFrame(this); TQFrame * f = new TQFrame(this);
f->setFrameStyle(TQFrame::Sunken | TQFrame::HLine); f->setFrameStyle(TQFrame::Sunken | TQFrame::HLine);
tqlayout()->addMultiCellWidget(f,9,9,0,2); layout()->addMultiCellWidget(f,9,9,0,2);
TQPushButton * b = new TQPushButton(__tr2qs_ctx("&New","options"),this); TQPushButton * b = new TQPushButton(__tr2qs_ctx("&New","options"),this);
connect(b,TQT_SIGNAL(clicked()),this,TQT_SLOT(newMediaType())); connect(b,TQT_SIGNAL(clicked()),this,TQT_SLOT(newMediaType()));
tqlayout()->addWidget(b,10,1); layout()->addWidget(b,10,1);
m_pDelete = new TQPushButton(__tr2qs_ctx("Re&move","options"),this); m_pDelete = new TQPushButton(__tr2qs_ctx("Re&move","options"),this);
connect(m_pDelete,TQT_SIGNAL(clicked()),this,TQT_SLOT(delMediaType())); connect(m_pDelete,TQT_SIGNAL(clicked()),this,TQT_SLOT(delMediaType()));
tqlayout()->addWidget(m_pDelete,10,2); layout()->addWidget(m_pDelete,10,2);
tqlayout()->setColStretch(1,1); layout()->setColStretch(1,1);
tqlayout()->setColStretch(2,1); layout()->setColStretch(2,1);
tqlayout()->setRowStretch(0,1); layout()->setRowStretch(0,1);
m_pLastItem = 0; m_pLastItem = 0;

@ -186,7 +186,7 @@ KviStandardColorsOptionsWidget::KviStandardColorsOptionsWidget(TQWidget * parent
addRowSpacer(0,4,3,4); addRowSpacer(0,4,3,4);
tqlayout()->setRowStretch(4,1); layout()->setRowStretch(4,1);
} }
KviStandardColorsOptionsWidget::~KviStandardColorsOptionsWidget() KviStandardColorsOptionsWidget::~KviStandardColorsOptionsWidget()
@ -464,8 +464,8 @@ KviMessageColorsOptionsWidget::KviMessageColorsOptionsWidget(TQWidget * parent)
it = new KviMessageListViewItem(m_pListView,i); it = new KviMessageListViewItem(m_pListView,i);
} }
tqlayout()->setRowStretch(0,1); layout()->setRowStretch(0,1);
tqlayout()->setColStretch(0,1); layout()->setColStretch(0,1);
connect(m_pListView,TQT_SIGNAL(selectionChanged(KviTalListViewItem *)),this,TQT_SLOT(itemChanged(KviTalListViewItem *))); connect(m_pListView,TQT_SIGNAL(selectionChanged(KviTalListViewItem *)),this,TQT_SLOT(itemChanged(KviTalListViewItem *)));
connect(m_pForeListBox,TQT_SIGNAL(selectionChanged(KviTalListBoxItem *)),this,TQT_SLOT(colorChanged(KviTalListBoxItem *))); connect(m_pForeListBox,TQT_SIGNAL(selectionChanged(KviTalListBoxItem *)),this,TQT_SLOT(colorChanged(KviTalListBoxItem *)));

@ -236,7 +236,7 @@ KviNickServOptionsWidget::KviNickServOptionsWidget(TQWidget * parent)
{ {
createLayout(3,3); createLayout(3,3);
TQGridLayout * gl = tqlayout(); TQGridLayout * gl = layout();
KviNickServRuleSet * rs = g_pNickServRuleSet; KviNickServRuleSet * rs = g_pNickServRuleSet;
bool bNickServEnabled = rs ? (rs->isEnabled() && !rs->isEmpty()) : false; bool bNickServEnabled = rs ? (rs->isEnabled() && !rs->isEmpty()) : false;

@ -104,7 +104,7 @@ KviProxyOptionsWidget::KviProxyOptionsWidget(TQWidget * parent)
KviTalGroupBox * gbox = addGroupBox(0,2,1,2,2,Qt::Horizontal,__tr2qs_ctx("Configuration","options"),this); KviTalGroupBox * gbox = addGroupBox(0,2,1,2,2,Qt::Horizontal,__tr2qs_ctx("Configuration","options"),this);
//TQGridLayout * gl = new TQGridLayout(gbox->tqlayout()); //TQGridLayout * gl = new TQGridLayout(gbox->layout());
//gl->setMargin(2); //gl->setMargin(2);
//gl->setSpacing(4); //gl->setSpacing(4);
@ -147,8 +147,8 @@ KviProxyOptionsWidget::KviProxyOptionsWidget(TQWidget * parent)
fillProxyList(); fillProxyList();
tqlayout()->setRowStretch(0,1); layout()->setRowStretch(0,1);
tqlayout()->setColStretch(0,1); layout()->setColStretch(0,1);
m_pContextPopup = new KviTalPopupMenu(this); m_pContextPopup = new KviTalPopupMenu(this);

@ -1192,10 +1192,10 @@ KviServerOptionsWidget::KviServerOptionsWidget(TQWidget * parent)
fillServerList(); fillServerList();
tqlayout()->setRowStretch(0,1); layout()->setRowStretch(0,1);
//tqlayout()->setColStretch(1,5); //layout()->setColStretch(1,5);
//tqlayout()->setColStretch(2,2); //layout()->setColStretch(2,2);
tqlayout()->setColStretch(0,1); layout()->setColStretch(0,1);
setMinimumWidth(320); setMinimumWidth(320);
} }

@ -161,7 +161,7 @@ KviTreeTaskBarBackgroundOptionsWidget::KviTreeTaskBarBackgroundOptionsWidget(TQW
m_pVerticalAlign->setCurrentItem(0); m_pVerticalAlign->setCurrentItem(0);
} }
tqlayout()->setRowStretch(1,1); layout()->setRowStretch(1,1);
} }

@ -160,14 +160,14 @@ KviTextIconsOptionsWidget::KviTextIconsOptionsWidget(TQWidget * parent)
++it; ++it;
} }
tqlayout()->addMultiCellWidget(m_pTable,0,0,0,1); layout()->addMultiCellWidget(m_pTable,0,0,0,1);
m_pAdd = new TQPushButton(__tr2qs_ctx("Add","options"),this); m_pAdd = new TQPushButton(__tr2qs_ctx("Add","options"),this);
tqlayout()->addWidget(m_pAdd,1,0); layout()->addWidget(m_pAdd,1,0);
connect(m_pAdd,TQT_SIGNAL(clicked()),this,TQT_SLOT(addClicked())); connect(m_pAdd,TQT_SIGNAL(clicked()),this,TQT_SLOT(addClicked()));
m_pDel = new TQPushButton(__tr2qs_ctx("Delete","options"),this); m_pDel = new TQPushButton(__tr2qs_ctx("Delete","options"),this);
tqlayout()->addWidget(m_pDel,1,1); layout()->addWidget(m_pDel,1,1);
connect(m_pDel,TQT_SIGNAL(clicked()),this,TQT_SLOT(delClicked())); connect(m_pDel,TQT_SIGNAL(clicked()),this,TQT_SLOT(delClicked()));
m_pDel->setEnabled(false); m_pDel->setEnabled(false);

@ -33,7 +33,7 @@ KviTopicLabelLookOptionsWidget::KviTopicLabelLookOptionsWidget(TQWidget *p):KviO
addColorSelector(0, 2, 0, 2, __tr2qs_ctx("Background color","options"), KviOption_colorLabelBackground); addColorSelector(0, 2, 0, 2, __tr2qs_ctx("Background color","options"), KviOption_colorLabelBackground);
addPixmapSelector(0, 3, 0, 3, __tr2qs_ctx("Background image","options"), KviOption_pixmapLabelBackground); addPixmapSelector(0, 3, 0, 3, __tr2qs_ctx("Background image","options"), KviOption_pixmapLabelBackground);
tqlayout()->setRowStretch(3, 1); layout()->setRowStretch(3, 1);
} }
KviTopicLabelLookOptionsWidget::~KviTopicLabelLookOptionsWidget() KviTopicLabelLookOptionsWidget::~KviTopicLabelLookOptionsWidget()

@ -178,8 +178,8 @@ KviUserListLookBackgroundOptionsWidget::KviUserListLookBackgroundOptionsWidget(T
//tqlayout()->setColStretch(0,1); //layout()->setColStretch(0,1);
tqlayout()->setRowStretch(1,1); layout()->setRowStretch(1,1);
} }
KviUserListLookBackgroundOptionsWidget::~KviUserListLookBackgroundOptionsWidget() KviUserListLookBackgroundOptionsWidget::~KviUserListLookBackgroundOptionsWidget()

@ -460,25 +460,25 @@ KviRegisteredUserEntryDialog::KviRegisteredUserEntryDialog(TQWidget *p,KviRegist
TQGroupBox * gb = new TQGroupBox(__tr2qs("Ignore features"),vb); TQGroupBox * gb = new TQGroupBox(__tr2qs("Ignore features"),vb);
connect(m_pIgnoreEnabled,TQT_SIGNAL(toggled(bool)),gb,TQT_SLOT(setEnabled(bool))); connect(m_pIgnoreEnabled,TQT_SIGNAL(toggled(bool)),gb,TQT_SLOT(setEnabled(bool)));
TQVBoxLayout * tqlayout = new TQVBoxLayout(gb,20,3); TQVBoxLayout * layout = new TQVBoxLayout(gb,20,3);
m_pIgnoreQuery = new KviStyledCheckBox(__tr2qs("Ignore query-messages"),gb); m_pIgnoreQuery = new KviStyledCheckBox(__tr2qs("Ignore query-messages"),gb);
tqlayout->addWidget(m_pIgnoreQuery); layout->addWidget(m_pIgnoreQuery);
m_pIgnoreChannel = new KviStyledCheckBox(__tr2qs("Ignore channel-messages"),gb); m_pIgnoreChannel = new KviStyledCheckBox(__tr2qs("Ignore channel-messages"),gb);
tqlayout->addWidget(m_pIgnoreChannel); layout->addWidget(m_pIgnoreChannel);
m_pIgnoreNotice = new KviStyledCheckBox(__tr2qs("Ignore notice-messages"),gb); m_pIgnoreNotice = new KviStyledCheckBox(__tr2qs("Ignore notice-messages"),gb);
tqlayout->addWidget(m_pIgnoreNotice); layout->addWidget(m_pIgnoreNotice);
m_pIgnoreCtcp = new KviStyledCheckBox(__tr2qs("Ignore ctcp-messages"),gb); m_pIgnoreCtcp = new KviStyledCheckBox(__tr2qs("Ignore ctcp-messages"),gb);
tqlayout->addWidget(m_pIgnoreCtcp); layout->addWidget(m_pIgnoreCtcp);
m_pIgnoreInvite = new KviStyledCheckBox(__tr2qs("Ignore invites"),gb); m_pIgnoreInvite = new KviStyledCheckBox(__tr2qs("Ignore invites"),gb);
tqlayout->addWidget(m_pIgnoreInvite); layout->addWidget(m_pIgnoreInvite);
m_pIgnoreDcc = new KviStyledCheckBox(__tr2qs("Ignore DCCs"),gb); m_pIgnoreDcc = new KviStyledCheckBox(__tr2qs("Ignore DCCs"),gb);
tqlayout->addWidget(m_pIgnoreDcc); layout->addWidget(m_pIgnoreDcc);
TQWidget *w = new TQWidget(vb); TQWidget *w = new TQWidget(vb);
w->setSizePolicy(TQSizePolicy::Ignored,TQSizePolicy::Ignored); w->setSizePolicy(TQSizePolicy::Ignored,TQSizePolicy::Ignored);

@ -592,10 +592,10 @@ void KviSharedFilesWindow::copyLocalFileToClipboard()
if(!t)return; if(!t)return;
TQString tmp = t->localFileName(); TQString tmp = t->localFileName();
if(tmp.isEmpty())return; if(tmp.isEmpty())return;
TQApplication::tqclipboard()->setSelectionMode(false); TQApplication::clipboard()->setSelectionMode(false);
TQApplication::tqclipboard()->setText(tmp); TQApplication::clipboard()->setText(tmp);
TQApplication::tqclipboard()->setSelectionMode(true); TQApplication::clipboard()->setSelectionMode(true);
TQApplication::tqclipboard()->setText(tmp); TQApplication::clipboard()->setText(tmp);
} }
void KviSharedFilesWindow::openLocalFileFolder() void KviSharedFilesWindow::openLocalFileFolder()

@ -102,7 +102,7 @@ static bool str_kvs_fnc_fromclipboard(KviKvsModuleFunctionCall * c)
TQString szString; TQString szString;
KVSM_PARAMETERS_BEGIN(c) KVSM_PARAMETERS_BEGIN(c)
KVSM_PARAMETERS_END(c) KVSM_PARAMETERS_END(c)
TQClipboard *cb = TQApplication::tqclipboard(); TQClipboard *cb = TQApplication::clipboard();
szString = cb->text(TQClipboard::Clipboard); szString = cb->text(TQClipboard::Clipboard);
c->returnValue()->setString(szString); c->returnValue()->setString(szString);
return true; return true;
@ -132,7 +132,7 @@ static bool str_kvs_cmd_toClipboard(KviKvsModuleCommandCall * c)
KVSM_PARAMETERS_BEGIN(c) KVSM_PARAMETERS_BEGIN(c)
KVSM_PARAMETER("value",KVS_PT_STRING,KVS_PF_OPTIONAL,szValue) KVSM_PARAMETER("value",KVS_PT_STRING,KVS_PF_OPTIONAL,szValue)
KVSM_PARAMETERS_END(c) KVSM_PARAMETERS_END(c)
TQClipboard *cb = TQApplication::tqclipboard(); TQClipboard *cb = TQApplication::clipboard();
cb->setText(szValue, TQClipboard::Clipboard ); cb->setText(szValue, TQClipboard::Clipboard );
return true; return true;
} }
@ -1360,17 +1360,17 @@ static bool str_kvs_fnc_word(KviKvsModuleFunctionCall * c)
int len = szString.length(); int len = szString.length();
while (idx<len) while (idx<len)
{ {
TQChar szTmp = szString[idx].tqunicode(); TQChar szTmp = szString[idx].unicode();
while (szTmp.isSpace()) while (szTmp.isSpace())
{ {
idx++; idx++;
szTmp = szString[idx].tqunicode(); szTmp = szString[idx].unicode();
} }
begin = idx; begin = idx;
while (idx<len && !szTmp.isSpace()) while (idx<len && !szTmp.isSpace())
{ {
idx++; idx++;
szTmp = szString[idx].tqunicode(); szTmp = szString[idx].unicode();
} }
if (iOccurence == (kvs_int_t)cnt) if (iOccurence == (kvs_int_t)cnt)
{ {
@ -1433,18 +1433,18 @@ static bool str_kvs_fnc_token(KviKvsModuleFunctionCall * c)
int len = szString.length(); int len = szString.length();
while (idx<len) while (idx<len)
{ {
TQChar szTmp = szString[idx].tqunicode(); TQChar szTmp = szString[idx].unicode();
// while (szTmp==sep) // while (szTmp==sep)
while (sep.contains(szTmp)) while (sep.contains(szTmp))
{ {
idx++; idx++;
szTmp = szString[idx].tqunicode(); szTmp = szString[idx].unicode();
} }
begin = idx; begin = idx;
while (idx<len && !sep.contains(szTmp)) while (idx<len && !sep.contains(szTmp))
{ {
idx++; idx++;
szTmp = szString[idx].tqunicode(); szTmp = szString[idx].unicode();
} }
if (n == cnt) if (n == cnt)
{ {
@ -1489,13 +1489,13 @@ static bool str_kvs_fnc_charsum(KviKvsModuleFunctionCall * c)
{ {
while(idx < len) while(idx < len)
{ {
sum += szString[idx].lower().tqunicode(); sum += szString[idx].lower().unicode();
idx++; idx++;
} }
} else { } else {
while(idx < len) while(idx < len)
{ {
sum += szString[idx].tqunicode(); sum += szString[idx].unicode();
idx++; idx++;
} }
} }
@ -1963,7 +1963,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
if(fmt) if(fmt)
{ {
TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * allocsize); TQChar * buffer = (TQChar *)kvi_malloc(sizeof(TQChar) * allocsize);
//TQChar * p = (TQChar *)s.tqunicode(); //TQChar * p = (TQChar *)s.unicode();
//9999999999999999999999999999999\0 //9999999999999999999999999999999\0
char numberBuffer[1024]; char numberBuffer[1024];
@ -1993,12 +1993,12 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
pVar = vArgs.first(); pVar = vArgs.first();
for(; fmt->tqunicode() ; ++fmt) for(; fmt->unicode() ; ++fmt)
{ {
if(reallen == allocsize)INCREMENT_MEM if(reallen == allocsize)INCREMENT_MEM
//copy up to a '?' //copy up to a '?'
if(fmt->tqunicode() != '?') if(fmt->unicode() != '?')
{ {
*p++ = *fmt; *p++ = *fmt;
reallen++; reallen++;
@ -2006,7 +2006,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
} }
++fmt; //skip this '?' ++fmt; //skip this '?'
switch(fmt->tqunicode()) switch(fmt->unicode())
{ {
case 's': case 's':
{ {
@ -2015,7 +2015,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
if(sz.isEmpty())continue; if(sz.isEmpty())continue;
int len = sz.length(); int len = sz.length();
if((allocsize - reallen) < len)INCREMENT_MEM_BY(len) if((allocsize - reallen) < len)INCREMENT_MEM_BY(len)
const TQChar * ch = sz.tqunicode(); const TQChar * ch = sz.unicode();
while(len--)*p++ = *ch++; while(len--)*p++ = *ch++;
reallen += sz.length(); reallen += sz.length();
pVar = vArgs.next(); pVar = vArgs.next();
@ -2149,7 +2149,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
} }
case '?': case '?':
{ {
if(fmt->tqunicode()) if(fmt->unicode())
{ {
if(reallen == allocsize)INCREMENT_MEM if(reallen == allocsize)INCREMENT_MEM
*p++ = *fmt; *p++ = *fmt;
@ -2171,15 +2171,15 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
int idx = 2; int idx = 2;
while((fmt->tqunicode() >= '0') && (fmt->tqunicode() <= '9') && (idx < 6)) while((fmt->unicode() >= '0') && (fmt->unicode() <= '9') && (idx < 6))
{ {
uPrecision *= 10; uPrecision *= 10;
fmtbuffer[idx] = fmt->tqunicode(); fmtbuffer[idx] = fmt->unicode();
uPrecision += fmtbuffer[idx] - '0'; uPrecision += fmtbuffer[idx] - '0';
fmt++; fmt++;
idx++; idx++;
} }
fmtbuffer[idx] = fmt->tqunicode(); fmtbuffer[idx] = fmt->unicode();
fmtbuffer[idx+1] = 0; fmtbuffer[idx+1] = 0;
if(pVar) if(pVar)
@ -2193,7 +2193,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
c->warning(__tr2qs("Missing argument for a floating point escape sequence, 0.0 assumed")); c->warning(__tr2qs("Missing argument for a floating point escape sequence, 0.0 assumed"));
argRValue = 0; argRValue = 0;
} }
switch(fmt->tqunicode()) switch(fmt->unicode())
{ {
case 'e': case 'e':
case 'E': case 'E':
@ -2212,7 +2212,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
fmt = save; fmt = save;
*p++ = '?'; //write it *p++ = '?'; //write it
reallen++; reallen++;
if(fmt->tqunicode()) if(fmt->unicode())
{ {
if(reallen == allocsize)INCREMENT_MEM if(reallen == allocsize)INCREMENT_MEM
*p++ = *fmt; *p++ = *fmt;
@ -2228,7 +2228,7 @@ static bool str_kvs_fnc_printf(KviKvsModuleFunctionCall * c)
{ {
*p++ = '?'; //write it *p++ = '?'; //write it
reallen++; reallen++;
if(fmt->tqunicode()) if(fmt->unicode())
{ {
if(reallen == allocsize)INCREMENT_MEM if(reallen == allocsize)INCREMENT_MEM
*p++ = *fmt; *p++ = *fmt;

@ -240,7 +240,7 @@ static bool system_kvs_fnc_getenv(KviKvsModuleFunctionCall *c)
static bool system_kvs_fnc_clipboard(KviKvsModuleFunctionCall *c) static bool system_kvs_fnc_clipboard(KviKvsModuleFunctionCall *c)
{ {
c->returnValue()->setString(g_pApp->tqclipboard()->text(TQClipboard::Clipboard)); c->returnValue()->setString(g_pApp->clipboard()->text(TQClipboard::Clipboard));
return true; return true;
} }
@ -275,7 +275,7 @@ static bool system_kvs_cmd_setClipboard(KviKvsModuleCommandCall * c)
KVSM_PARAMETERS_BEGIN(c) KVSM_PARAMETERS_BEGIN(c)
KVSM_PARAMETER("data",KVS_PT_STRING,KVS_PF_OPTIONAL,szValue) KVSM_PARAMETER("data",KVS_PT_STRING,KVS_PF_OPTIONAL,szValue)
KVSM_PARAMETERS_END(c) KVSM_PARAMETERS_END(c)
g_pApp->tqclipboard()->setText(szValue,TQClipboard::Clipboard); g_pApp->clipboard()->setText(szValue,TQClipboard::Clipboard);
return true; return true;
} }
@ -307,7 +307,7 @@ static bool system_kvs_cmd_setSelection(KviKvsModuleCommandCall * c)
KVSM_PARAMETERS_BEGIN(c) KVSM_PARAMETERS_BEGIN(c)
KVSM_PARAMETER("data",KVS_PT_STRING,KVS_PF_OPTIONAL,szValue) KVSM_PARAMETER("data",KVS_PT_STRING,KVS_PF_OPTIONAL,szValue)
KVSM_PARAMETERS_END(c) KVSM_PARAMETERS_END(c)
g_pApp->tqclipboard()->setText(szValue,TQClipboard::Selection); g_pApp->clipboard()->setText(szValue,TQClipboard::Selection);
return true; return true;
} }
@ -337,7 +337,7 @@ static bool system_kvs_cmd_setSelection(KviKvsModuleCommandCall * c)
static bool system_kvs_fnc_selection(KviKvsModuleFunctionCall *c) static bool system_kvs_fnc_selection(KviKvsModuleFunctionCall *c)
{ {
c->returnValue()->setString(g_pApp->tqclipboard()->text(TQClipboard::Selection)); c->returnValue()->setString(g_pApp->clipboard()->text(TQClipboard::Selection));
return true; return true;
} }

Loading…
Cancel
Save