diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /kpresenter/KPrPBPreview.cpp | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kpresenter/KPrPBPreview.cpp')
-rw-r--r-- | kpresenter/KPrPBPreview.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/kpresenter/KPrPBPreview.cpp b/kpresenter/KPrPBPreview.cpp index 07209b93..bbc14a57 100644 --- a/kpresenter/KPrPBPreview.cpp +++ b/kpresenter/KPrPBPreview.cpp @@ -20,20 +20,20 @@ #include "KPrPBPreview.h" -#include <qpainter.h> +#include <tqpainter.h> #include <KoTextZoomHandler.h> #include "KPrUtils.h" -KPrPBPreview::KPrPBPreview( QWidget* parent, const char* name, PaintType _paintType ) - : QFrame( parent, name ) +KPrPBPreview::KPrPBPreview( TQWidget* tqparent, const char* name, PaintType _paintType ) + : TQFrame( tqparent, name ) { //FIXME zoom _zoomHandler=new KoTextZoomHandler(); paintType = _paintType; - pen = KoPen( black, 1, SolidLine ); - brush = QBrush( white, SolidPattern ); - gradient = new KPrGradient( Qt::red, Qt::green, BCT_GHORZ, false, 100, 100 ); + pen = KoPen( black, 1, Qt::SolidLine ); + brush = TQBrush( white, SolidPattern ); + gradient = new KPrGradient( TQt::red, TQt::green, BCT_GHORZ, false, 100, 100 ); savedGradient = gradient; setFrameStyle( WinPanel | Sunken ); @@ -48,26 +48,26 @@ KPrPBPreview::KPrPBPreview( QWidget* parent, const char* name, PaintType _paintT } } -void KPrPBPreview::resizeEvent( QResizeEvent *e ) +void KPrPBPreview::resizeEvent( TQResizeEvent *e ) { - QFrame::resizeEvent( e ); + TQFrame::resizeEvent( e ); if ( gradient ) { #if 1 gradient->setSize( contentsRect().size() ); - repaint(); + tqrepaint(); #endif } } -void KPrPBPreview::drawContents( QPainter *painter ) +void KPrPBPreview::drawContents( TQPainter *painter ) { painter->save(); painter->translate( contentsRect().x(), contentsRect().y() ); if ( paintType == Pen ) { painter->fillRect( 0, 0, contentsRect().width(), contentsRect().height(), - colorGroup().base() ); + tqcolorGroup().base() ); KoSize diff1( 0, 0 ), diff2( 0, 0 ); int _w = int( pen.pointWidth() ); @@ -94,7 +94,7 @@ void KPrPBPreview::drawContents( QPainter *painter ) } else if ( paintType == Brush ) { painter->fillRect( 0, 0, contentsRect().width(), contentsRect().height(), - colorGroup().base() ); + tqcolorGroup().base() ); painter->fillRect( 0, 0, contentsRect().width(), contentsRect().height(), brush ); } else if ( paintType == Gradient ) painter->drawPixmap( 0, 0, gradient->pixmap()); @@ -109,7 +109,7 @@ KPrPBPreview::~KPrPBPreview() } -void KPrPBPreview::setGradient( const QColor &_c1, const QColor &_c2, BCType _t, +void KPrPBPreview::setGradient( const TQColor &_c1, const TQColor &_c2, BCType _t, bool _unbalanced, int _xfactor, int _yfactor ) { gradient->setColor1( _c1 ); @@ -118,7 +118,7 @@ void KPrPBPreview::setGradient( const QColor &_c1, const QColor &_c2, BCType _t, gradient->setUnbalanced( _unbalanced ); gradient->setXFactor( _xfactor ); gradient->setYFactor( _yfactor ); - repaint( false ); + tqrepaint( false ); } |