summaryrefslogtreecommitdiffstats
path: root/kopete/libkopete/ui/kopetelistviewitem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kopete/libkopete/ui/kopetelistviewitem.cpp')
-rw-r--r--kopete/libkopete/ui/kopetelistviewitem.cpp246
1 files changed, 123 insertions, 123 deletions
diff --git a/kopete/libkopete/ui/kopetelistviewitem.cpp b/kopete/libkopete/ui/kopetelistviewitem.cpp
index fda2ff4c..888f9d5b 100644
--- a/kopete/libkopete/ui/kopetelistviewitem.cpp
+++ b/kopete/libkopete/ui/kopetelistviewitem.cpp
@@ -29,14 +29,14 @@
#include <kiconloader.h>
#include <kstringhandler.h>
-#include <qapplication.h>
-#include <qpixmap.h>
-#include <qpainter.h>
-#include <qptrlist.h>
-#include <qrect.h>
-#include <qtimer.h>
-#include <qheader.h>
-#include <qstyle.h>
+#include <tqapplication.h>
+#include <tqpixmap.h>
+#include <tqpainter.h>
+#include <tqptrlist.h>
+#include <tqrect.h>
+#include <tqtimer.h>
+#include <tqheader.h>
+#include <tqstyle.h>
#ifdef HAVE_XRENDER
# include <X11/Xlib.h>
@@ -54,7 +54,7 @@ namespace ListView {
class ComponentBase::Private
{
public:
- QPtrList<Component> components;
+ TQPtrList<Component> components;
};
ComponentBase::ComponentBase()
@@ -71,7 +71,7 @@ ComponentBase::~ComponentBase()
uint ComponentBase::components() { return d->components.count(); }
Component *ComponentBase::component( uint n ) { return d->components.at( n ); }
-Component *ComponentBase::componentAt( const QPoint &pt )
+Component *ComponentBase::componentAt( const TQPoint &pt )
{
for ( uint n = 0; n < components(); ++n )
{
@@ -113,13 +113,13 @@ void ComponentBase::componentResized( Component * )
{
}
-std::pair<QString,QRect> ComponentBase::toolTip( const QPoint &relativePos )
+std::pair<TQString,TQRect> ComponentBase::toolTip( const TQPoint &relativePos )
{
for ( uint n = 0; n < components(); ++n )
if ( component( n )->rect().contains( relativePos ) )
return component( n )->toolTip( relativePos );
- return std::make_pair( QString::null, QRect() );
+ return std::make_pair( TQString::null, TQRect() );
}
void ComponentBase::updateAnimationPosition( int p, int s )
@@ -127,9 +127,9 @@ void ComponentBase::updateAnimationPosition( int p, int s )
for ( uint n = 0; n < components(); ++n )
{
Component *comp = component( n );
- QRect start = comp->startRect();
- QRect target = comp->targetRect();
- QRect rc( start.left() + ((target.left() - start.left()) * p) / s,
+ TQRect start = comp->startRect();
+ TQRect target = comp->targetRect();
+ TQRect rc( start.left() + ((target.left() - start.left()) * p) / s,
start.top() + ((target.top() - start.top()) * p) / s,
start.width() + ((target.width() - start.width()) * p) / s,
start.height() + ((target.height() - start.height()) * p) / s );
@@ -150,8 +150,8 @@ public:
{
}
ComponentBase *parent;
- QRect rect;
- QRect startRect, targetRect;
+ TQRect rect;
+ TQRect startRect, targetRect;
int minWidth, minHeight;
bool growHoriz, growVert;
bool show; /** @since 23-03-2005 */
@@ -199,19 +199,19 @@ void Component::setToolTipSource( ToolTipSource *source )
d->tipSource = source;
}
-std::pair<QString,QRect> Component::toolTip( const QPoint &relativePos )
+std::pair<TQString,TQRect> Component::toolTip( const TQPoint &relativePos )
{
if ( !d->tipSource )
return ComponentBase::toolTip( relativePos );
- QRect rc = rect();
- QString result = (*d->tipSource)( this, relativePos, rc );
+ TQRect rc = rect();
+ TQString result = (*d->tipSource)( this, relativePos, rc );
return std::make_pair(result, rc);
}
-QRect Component::rect() { return d->rect; }
-QRect Component::startRect() { return d->startRect; }
-QRect Component::targetRect() { return d->targetRect; }
+TQRect Component::rect() { return d->rect; }
+TQRect Component::startRect() { return d->startRect; }
+TQRect Component::targetRect() { return d->targetRect; }
int Component::minWidth() { return d->minWidth; }
int Component::minHeight() { return d->minHeight; }
@@ -235,22 +235,22 @@ bool Component::setMinHeight( int height )
return true;
}
-void Component::layout( const QRect &newRect )
+void Component::layout( const TQRect &newRect )
{
if ( rect().isNull() )
- d->startRect = QRect( newRect.topLeft(), newRect.topLeft() );
+ d->startRect = TQRect( newRect.topLeft(), newRect.topLeft() );
else
d->startRect = rect();
d->targetRect = newRect;
//kdDebug(14000) << k_funcinfo << "At " << rect << endl;
}
-void Component::setRect( const QRect &rect )
+void Component::setRect( const TQRect &rect )
{
d->rect = rect;
}
-void Component::paint( QPainter *painter, const QColorGroup &cg )
+void Component::paint( TQPainter *painter, const TQColorGroup &cg )
{
/*painter->setPen( Qt::red );
painter->drawRect( rect() );*/
@@ -378,7 +378,7 @@ void BoxComponent::calcMinSize()
relayout();
}
-void BoxComponent::layout( const QRect &rect )
+void BoxComponent::layout( const TQRect &rect )
{
Component::layout( rect );
@@ -413,7 +413,7 @@ void BoxComponent::layout( const QRect &rect )
{
Component *comp = component( n );
- QRect rc;
+ TQRect rc;
if ( horiz )
{
rc.setLeft( rect.left() + pos );
@@ -464,7 +464,7 @@ void BoxComponent::componentResized( Component *component )
class ImageComponent::Private
{
public:
- QPixmap image;
+ TQPixmap image;
};
ImageComponent::ImageComponent( ComponentBase *parent )
@@ -487,12 +487,12 @@ ImageComponent::~ImageComponent()
delete d;
}
-QPixmap ImageComponent::pixmap()
+TQPixmap ImageComponent::pixmap()
{
return d->image;
}
-void ImageComponent::setPixmap( const QPixmap &img, bool adjustSize)
+void ImageComponent::setPixmap( const TQPixmap &img, bool adjustSize)
{
d->image = img;
if ( adjustSize )
@@ -503,30 +503,30 @@ void ImageComponent::setPixmap( const QPixmap &img, bool adjustSize)
repaint();
}
-static QPoint operator+( const QPoint &pt, const QSize &sz )
+static TQPoint operator+( const TQPoint &pt, const TQSize &sz )
{
- return QPoint( pt.x() + sz.width(), pt.y() + sz.height() );
+ return TQPoint( pt.x() + sz.width(), pt.y() + sz.height() );
}
-/*static QPoint operator+( const QSize &sz, const QPoint &pt )
+/*static TQPoint operator+( const TQSize &sz, const TQPoint &pt )
{
return pt + sz;
}*/
-void ImageComponent::paint( QPainter *painter, const QColorGroup & )
+void ImageComponent::paint( TQPainter *painter, const TQColorGroup & )
{
- QRect ourRc = rect();
- QRect rc = d->image.rect();
+ TQRect ourRc = rect();
+ TQRect rc = d->image.rect();
// center rc within our rect
rc.moveTopLeft( ourRc.topLeft() + (ourRc.size() - rc.size()) / 2 );
// paint, shrunk to be within our rect
painter->drawPixmap( rc & ourRc, d->image );
}
-void ImageComponent::scale( int w, int h, QImage::ScaleMode mode )
+void ImageComponent::scale( int w, int h, TQImage::ScaleMode mode )
{
- QImage im = d->image.convertToImage();
- setPixmap( QPixmap( im.smoothScale( w, h, mode ) ) );
+ TQImage im = d->image.convertToImage();
+ setPixmap( TQPixmap( im.smoothScale( w, h, mode ) ) );
}
// TextComponent
@@ -534,13 +534,13 @@ class TextComponent::Private
{
public:
Private() : customColor( false ) {}
- QString text;
+ TQString text;
bool customColor;
- QColor color;
- QFont font;
+ TQColor color;
+ TQFont font;
};
-TextComponent::TextComponent( ComponentBase *parent, const QFont &font, const QString &text )
+TextComponent::TextComponent( ComponentBase *parent, const TQFont &font, const TQString &text )
: Component( parent ), d( new Private )
{
setFont( font );
@@ -554,12 +554,12 @@ TextComponent::~TextComponent()
delete d;
}
-QString TextComponent::text()
+TQString TextComponent::text()
{
return d->text;
}
-void TextComponent::setText( const QString &text )
+void TextComponent::setText( const TQString &text )
{
if ( text == d->text ) return;
d->text = text;
@@ -567,12 +567,12 @@ void TextComponent::setText( const QString &text )
calcMinSize();
}
-QFont TextComponent::font()
+TQFont TextComponent::font()
{
return d->font;
}
-void TextComponent::setFont( const QFont &font )
+void TextComponent::setFont( const TQFont &font )
{
if ( font == d->font ) return;
d->font = font;
@@ -584,7 +584,7 @@ void TextComponent::calcMinSize()
setMinWidth( 0 );
if ( !d->text.isEmpty() )
- setMinHeight( QFontMetrics( font() ).height() );
+ setMinHeight( TQFontMetrics( font() ).height() );
else
setMinHeight( 0 );
@@ -597,15 +597,15 @@ int TextComponent::widthForHeight( int )
// allegedly if this is not done the protocol icons overlap the text.
// i however have never seen this problem (which would almost certainly
// be a bug somewhere else).
- return QFontMetrics( font() ).width( d->text ) + 2;
+ return TQFontMetrics( font() ).width( d->text ) + 2;
}
-QColor TextComponent::color()
+TQColor TextComponent::color()
{
- return d->customColor ? d->color : QColor();
+ return d->customColor ? d->color : TQColor();
}
-void TextComponent::setColor( const QColor &color )
+void TextComponent::setColor( const TQColor &color )
{
d->color = color;
d->customColor = true;
@@ -618,13 +618,13 @@ void TextComponent::setDefaultColor()
repaint();
}
-void TextComponent::paint( QPainter *painter, const QColorGroup &cg )
+void TextComponent::paint( TQPainter *painter, const TQColorGroup &cg )
{
if ( d->customColor )
painter->setPen( d->color );
else
painter->setPen( cg.text() );
- QString dispStr = KStringHandler::rPixelSqueeze( d->text, QFontMetrics( font() ), rect().width() );
+ TQString dispStr = KStringHandler::rPixelSqueeze( d->text, TQFontMetrics( font() ), rect().width() );
painter->setFont( font() );
painter->drawText( rect(), Qt::SingleLine, dispStr );
}
@@ -634,8 +634,8 @@ void TextComponent::paint( QPainter *painter, const QColorGroup &cg )
class DisplayNameComponent::Private
{
public:
- QString text;
- QFont font;
+ TQString text;
+ TQFont font;
};
DisplayNameComponent::DisplayNameComponent( ComponentBase *parent )
@@ -650,12 +650,12 @@ DisplayNameComponent::~DisplayNameComponent()
delete d;
}
-void DisplayNameComponent::layout( const QRect &rect )
+void DisplayNameComponent::layout( const TQRect &rect )
{
Component::layout( rect );
// finally, lay everything out
- QRect rc;
+ TQRect rc;
int totalWidth = rect.width();
int usedWidth = 0;
bool exceeded = false;
@@ -671,7 +671,7 @@ void DisplayNameComponent::layout( const QRect &rect )
if ( comp->rtti() == Rtti_TextComponent )
{
comp->show();
- comp->layout( QRect( usedWidth+ rect.left(), rect.top(),
+ comp->layout( TQRect( usedWidth+ rect.left(), rect.top(),
totalWidth - usedWidth,
comp->heightForWidth( totalWidth - usedWidth ) ) );
} else {
@@ -681,7 +681,7 @@ void DisplayNameComponent::layout( const QRect &rect )
else
{
comp->show();
- comp->layout( QRect( usedWidth+ rect.left(), rect.top(),
+ comp->layout( TQRect( usedWidth+ rect.left(), rect.top(),
comp->widthForHeight( rect.height() ),
comp->heightForWidth( rect.width() ) ) );
}
@@ -695,7 +695,7 @@ void DisplayNameComponent::layout( const QRect &rect )
}
}
-void DisplayNameComponent::setText( const QString& text )
+void DisplayNameComponent::setText( const TQString& text )
{
if ( d->text == text )
return;
@@ -706,15 +706,15 @@ void DisplayNameComponent::setText( const QString& text )
void DisplayNameComponent::redraw()
{
- QColor color;
+ TQColor color;
for ( uint n = 0; n < components(); ++n )
if( component( n )->rtti() == Rtti_TextComponent )
{
((TextComponent*)component(n))->color();
}
- QValueList<Kopete::Emoticons::Token> tokens;
- QValueList<Kopete::Emoticons::Token>::const_iterator token;
+ TQValueList<Kopete::Emoticons::Token> tokens;
+ TQValueList<Kopete::Emoticons::Token>::const_iterator token;
clear(); // clear childs
@@ -722,7 +722,7 @@ void DisplayNameComponent::redraw()
ImageComponent *ic;
TextComponent *t;
- QFontMetrics fontMetrics( d->font );
+ TQFontMetrics fontMetrics( d->font );
int fontHeight = fontMetrics.height();
for ( token = tokens.begin(); token != tokens.end(); ++token )
{
@@ -733,8 +733,8 @@ void DisplayNameComponent::redraw()
break;
case Kopete::Emoticons::Image:
ic = new ImageComponent( this );
- ic->setPixmap( QPixmap( (*token).picPath ) );
- ic->scale( INT_MAX, fontHeight, QImage::ScaleMin );
+ ic->setPixmap( TQPixmap( (*token).picPath ) );
+ ic->scale( INT_MAX, fontHeight, TQImage::ScaleMin );
break;
default:
kdDebug( 14010 ) << k_funcinfo << "This should have not happened!" << endl;
@@ -745,7 +745,7 @@ void DisplayNameComponent::redraw()
setColor( color );
}
-void DisplayNameComponent::setFont( const QFont& font )
+void DisplayNameComponent::setFont( const TQFont& font )
{
for ( uint n = 0; n < components(); ++n )
if( component( n )->rtti() == Rtti_TextComponent )
@@ -753,7 +753,7 @@ void DisplayNameComponent::setFont( const QFont& font )
d->font = font;
}
-void DisplayNameComponent::setColor( const QColor& color )
+void DisplayNameComponent::setColor( const TQColor& color )
{
for ( uint n = 0; n < components(); ++n )
if( component( n )->rtti() == Rtti_TextComponent )
@@ -767,7 +767,7 @@ void DisplayNameComponent::setDefaultColor()
((TextComponent*)component(n))->setDefaultColor();
}
-QString DisplayNameComponent::text()
+TQString DisplayNameComponent::text()
{
return d->text;
}
@@ -835,7 +835,7 @@ Kopete::Contact *ContactComponent::contact()
}
// we don't need to use a tooltip source here - this way is simpler
-std::pair<QString,QRect> ContactComponent::toolTip( const QPoint &/*relativePos*/ )
+std::pair<TQString,TQRect> ContactComponent::toolTip( const TQPoint &/*relativePos*/ )
{
return std::make_pair(d->contact->toolTip(),rect());
}
@@ -860,16 +860,16 @@ class SharedTimer : private QTimer
int users;
public:
SharedTimer( int period ) : period(period), users(0) {}
- void attach( QObject *target, const char *slot )
+ void attach( TQObject *target, const char *slot )
{
- connect( this, SIGNAL(timeout()), target, slot );
+ connect( this, TQT_SIGNAL(timeout()), target, slot );
if( users++ == 0 )
start( period );
//kdDebug(14000) << "SharedTimer::attach: users is now " << users << "\n";
}
- void detach( QObject *target, const char *slot )
+ void detach( TQObject *target, const char *slot )
{
- disconnect( this, SIGNAL(timeout()), target, slot );
+ disconnect( this, TQT_SIGNAL(timeout()), target, slot );
if( --users == 0 )
stop();
//kdDebug(14000) << "SharedTimer::detach: users is now " << users << "\n";
@@ -879,11 +879,11 @@ public:
class SharedTimerRef
{
SharedTimer &timer;
- QObject * const object;
+ TQObject * const object;
const char * const slot;
bool attached;
public:
- SharedTimerRef( SharedTimer &timer, QObject *obj, const char *slot )
+ SharedTimerRef( SharedTimer &timer, TQObject *obj, const char *slot )
: timer(timer), object(obj), slot(slot), attached(false)
{
}
@@ -909,16 +909,16 @@ class Item::Private
{
public:
Private( Item *item )
- : layoutAnimateTimer( theLayoutAnimateTimer(), item, SLOT( slotLayoutAnimateItems() ) )
+ : layoutAnimateTimer( theLayoutAnimateTimer(), item, TQT_SLOT( slotLayoutAnimateItems() ) )
, animateLayout( true ), opacity( 1.0 )
- , visibilityTimer( theVisibilityTimer(), item, SLOT( slotUpdateVisibility() ) )
+ , visibilityTimer( theVisibilityTimer(), item, TQT_SLOT( slotUpdateVisibility() ) )
, visibilityLevel( 0 ), visibilityTarget( false ), searchMatch( true )
{
}
- QTimer layoutTimer;
+ TQTimer layoutTimer;
- //QTimer layoutAnimateTimer;
+ //TQTimer layoutAnimateTimer;
SharedTimerRef layoutAnimateTimer;
SharedTimer &theLayoutAnimateTimer()
{
@@ -932,7 +932,7 @@ public:
float opacity;
- //QTimer visibilityTimer;
+ //TQTimer visibilityTimer;
SharedTimerRef visibilityTimer;
SharedTimer &theVisibilityTimer()
{
@@ -961,14 +961,14 @@ bool Item::Private::animateChanges = true;
bool Item::Private::fadeVisibility = true;
bool Item::Private::foldVisibility = true;
-Item::Item( QListViewItem *parent, QObject *owner, const char *name )
- : QObject( owner, name ), KListViewItem( parent ), d( new Private(this) )
+Item::Item( TQListViewItem *parent, TQObject *owner, const char *name )
+ : TQObject( owner, name ), KListViewItem( parent ), d( new Private(this) )
{
initLVI();
}
-Item::Item( QListView *parent, QObject *owner, const char *name )
- : QObject( owner, name ), KListViewItem( parent ), d( new Private(this) )
+Item::Item( TQListView *parent, TQObject *owner, const char *name )
+ : TQObject( owner, name ), KListViewItem( parent ), d( new Private(this) )
{
initLVI();
}
@@ -987,10 +987,10 @@ void Item::setEffects( bool animation, bool fading, bool folding )
void Item::initLVI()
{
- connect( listView()->header(), SIGNAL( sizeChange( int, int, int ) ), SLOT( slotColumnResized() ) );
- connect( &d->layoutTimer, SIGNAL( timeout() ), SLOT( slotLayoutItems() ) );
- //connect( &d->layoutAnimateTimer, SIGNAL( timeout() ), SLOT( slotLayoutAnimateItems() ) );
- //connect( &d->visibilityTimer, SIGNAL( timeout() ), SLOT( slotUpdateVisibility() ) );
+ connect( listView()->header(), TQT_SIGNAL( sizeChange( int, int, int ) ), TQT_SLOT( slotColumnResized() ) );
+ connect( &d->layoutTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( slotLayoutItems() ) );
+ //connect( &d->layoutAnimateTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( slotLayoutAnimateItems() ) );
+ //connect( &d->visibilityTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( slotUpdateVisibility() ) );
setVisible( false );
setTargetVisibility( true );
}
@@ -1023,7 +1023,7 @@ void Item::slotLayoutItems()
}
int height = component( n )->heightForWidth( width );
- component( n )->layout( QRect( 0, 0, width, height ) );
+ component( n )->layout( TQRect( 0, 0, width, height ) );
//kdDebug(14000) << k_funcinfo << "Component " << n << " is " << width << " x " << height << endl;
}
@@ -1169,62 +1169,62 @@ void Item::setHeight( int )
KListViewItem::setHeight( minHeight );
}
-int Item::width( const QFontMetrics &, const QListView *lv, int c ) const
+int Item::width( const TQFontMetrics &, const TQListView *lv, int c ) const
{
// Qt computes the itemRect from this. we want the whole item to be
// clickable, so we return the widest we could possibly be.
return lv->header()->sectionSize( c );
}
-void Item::paintCell( QPainter *p, const QColorGroup &cg, int column, int width, int align )
+void Item::paintCell( TQPainter *p, const TQColorGroup &cg, int column, int width, int align )
{
- QPixmap back( width, height() );
- QPainter paint( &back );
+ TQPixmap back( width, height() );
+ TQPainter paint( &back );
//KListViewItem::paintCell( &paint, cg, column, width, align );
// PASTED FROM KLISTVIEWITEM:
// set the alternate cell background colour if necessary
- QColorGroup _cg = cg;
+ TQColorGroup _cg = cg;
if (isAlternate())
if (listView()->viewport()->backgroundMode()==Qt::FixedColor)
- _cg.setColor(QColorGroup::Background, static_cast< KListView* >(listView())->alternateBackground());
+ _cg.setColor(TQColorGroup::Background, static_cast< KListView* >(listView())->alternateBackground());
else
- _cg.setColor(QColorGroup::Base, static_cast< KListView* >(listView())->alternateBackground());
+ _cg.setColor(TQColorGroup::Base, static_cast< KListView* >(listView())->alternateBackground());
// PASTED FROM QLISTVIEWITEM
{
- QPainter *p = &paint;
+ TQPainter *p = &paint;
- QListView *lv = listView();
+ TQListView *lv = listView();
if ( !lv )
return;
- QFontMetrics fm( p->fontMetrics() );
+ TQFontMetrics fm( p->fontMetrics() );
// any text we render is done by the Components, not by this class, so make sure we've nothing to write
- QString t;
+ TQString t;
// removed text truncating code from Qt - we do that differently, further on
int marg = lv->itemMargin();
int r = marg;
- // const QPixmap * icon = pixmap( column );
+ // const TQPixmap * icon = pixmap( column );
const BackgroundMode bgmode = lv->viewport()->backgroundMode();
- const QColorGroup::ColorRole crole = QPalette::backgroundRoleFromMode( bgmode );
+ const TQColorGroup::ColorRole crole = TQPalette::backgroundRoleFromMode( bgmode );
if ( _cg.brush( crole ) != lv->colorGroup().brush( crole ) )
p->fillRect( 0, 0, width, height(), _cg.brush( crole ) );
else
{
- // all copied from QListView::paintEmptyArea
+ // all copied from TQListView::paintEmptyArea
- //lv->paintEmptyArea( p, QRect( 0, 0, width, height() ) );
- QStyleOption opt( lv->sortColumn(), 0 ); // ### hack; in 3.1, add a property in QListView and QHeader
- QStyle::SFlags how = QStyle::Style_Default;
+ //lv->paintEmptyArea( p, TQRect( 0, 0, width, height() ) );
+ TQStyleOption opt( lv->sortColumn(), 0 ); // ### hack; in 3.1, add a property in TQListView and QHeader
+ TQStyle::SFlags how = TQStyle::Style_Default;
if ( lv->isEnabled() )
- how |= QStyle::Style_Enabled;
+ how |= TQStyle::Style_Enabled;
- lv->style().drawComplexControl( QStyle::CC_ListView,
- p, lv, QRect( 0, 0, width, height() ), lv->colorGroup(),
- how, QStyle::SC_ListView, QStyle::SC_None,
+ lv->style().drawComplexControl( TQStyle::CC_ListView,
+ p, lv, TQRect( 0, 0, width, height() ), lv->colorGroup(),
+ how, TQStyle::SC_ListView, TQStyle::SC_None,
opt );
}
@@ -1233,7 +1233,7 @@ void Item::paintCell( QPainter *p, const QColorGroup &cg, int column, int width,
if ( isSelected() &&
(column == 0 || lv->allColumnsShowFocus()) ) {
p->fillRect( r - marg, 0, width - r + marg, height(),
- _cg.brush( QColorGroup::Highlight ) );
+ _cg.brush( TQColorGroup::Highlight ) );
// removed text pen setting code from Qt
}
@@ -1242,16 +1242,16 @@ void Item::paintCell( QPainter *p, const QColorGroup &cg, int column, int width,
// draw the tree gubbins
if ( multiLinesEnabled() && column == 0 && isOpen() && childCount() ) {
int textheight = fm.size( align, t ).height() + 2 * lv->itemMargin();
- textheight = QMAX( textheight, QApplication::globalStrut().height() );
+ textheight = QMAX( textheight, TQApplication::globalStrut().height() );
if ( textheight % 2 > 0 )
textheight++;
if ( textheight < height() ) {
int w = lv->treeStepSize() / 2;
- lv->style().drawComplexControl( QStyle::CC_ListView, p, lv,
- QRect( 0, textheight, w + 1, height() - textheight + 1 ), _cg,
- lv->isEnabled() ? QStyle::Style_Enabled : QStyle::Style_Default,
- QStyle::SC_ListViewExpand,
- (uint)QStyle::SC_All, QStyleOption( this ) );
+ lv->style().drawComplexControl( TQStyle::CC_ListView, p, lv,
+ TQRect( 0, textheight, w + 1, height() - textheight + 1 ), _cg,
+ lv->isEnabled() ? TQStyle::Style_Enabled : TQStyle::Style_Default,
+ TQStyle::SC_ListViewExpand,
+ (uint)TQStyle::SC_All, TQStyleOption( this ) );
}
}
}
@@ -1260,14 +1260,14 @@ void Item::paintCell( QPainter *p, const QColorGroup &cg, int column, int width,
//do you see a better way to tell the TextComponent we are selected ? - Olivier 2004-09-02
if ( isSelected() )
- _cg.setColor(QColorGroup::Text , _cg.highlightedText() );
+ _cg.setColor(TQColorGroup::Text , _cg.highlightedText() );
if ( Component *comp = component( column ) )
comp->paint( &paint, _cg );
paint.end();
#ifdef HAVE_XRENDER
- QColor rgb = cg.base();//backgroundColor();
+ TQColor rgb = cg.base();//backgroundColor();
float opac = 1.0;
if ( d->visibilityTimer.isActive() && Private::fadeVisibility )
{