diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-11 04:58:26 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-11 04:58:26 +0000 |
commit | 838baf3f99ec5ab81b063eb5449a3381d860f377 (patch) | |
tree | dd31abcfde08ca92e4623b8f50b3d762a87c997a /kgoldrunner/src/kgrcanvas.cpp | |
parent | 2bf598bafa22fac4126fc8842df6b0119aadc0e9 (diff) | |
download | tdegames-838baf3f99ec5ab81b063eb5449a3381d860f377.tar.gz tdegames-838baf3f99ec5ab81b063eb5449a3381d860f377.zip |
TQt4 port kdegames
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1236074 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kgoldrunner/src/kgrcanvas.cpp')
-rw-r--r-- | kgoldrunner/src/kgrcanvas.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/kgoldrunner/src/kgrcanvas.cpp b/kgoldrunner/src/kgrcanvas.cpp index 111913a1..907463e5 100644 --- a/kgoldrunner/src/kgrcanvas.cpp +++ b/kgoldrunner/src/kgrcanvas.cpp @@ -2,7 +2,7 @@ kgrcanvas.cpp - description ------------------- begin : Wed Jan 23 2002 - copyright : (C) 2002 by Marco Krüger and Ian Wadham + copyright : (C) 2002 by Marco Kr�ger and Ian Wadham email : See menu "Help, About KGoldrunner" ***************************************************************************/ @@ -34,8 +34,8 @@ class KGoldrunner; -KGrCanvas::KGrCanvas (TQWidget * parent, const char *name) - : TQCanvasView (0, parent, name) +KGrCanvas::KGrCanvas (TQWidget * tqparent, const char *name) + : TQCanvasView (0, tqparent, name) { setBackgroundMode (NoBackground); m = new TQCursor (); // For handling the mouse. @@ -117,7 +117,7 @@ bool KGrCanvas::changeSize (int d) return FALSE; } - TQWMatrix wm = worldMatrix(); + TQWMatrix wm = tqworldMatrix(); double wmScale = 1.0; // Set the scale back to 1:1 and calculate the new scale factor. @@ -145,7 +145,7 @@ bool KGrCanvas::changeSize (int d) #else KGrMessage::information (this, i18n( "Change Size" ), i18n( "Sorry, you cannot change the size of the playing area. " - "That function requires Qt Library version 3 or later." )); + "That function requires TQt Library version 3 or later." )); return FALSE; #endif } @@ -196,8 +196,8 @@ void KGrCanvas::setTitle (TQString newTitle) void KGrCanvas::makeTitle () { - // This uses a calculated TQLabel and TQFont size because a QCanvasText - // object does not always display scaled-up fonts cleanly (in Qt 3.1.1). + // This uses a calculated TQLabel and TQFont size because a TQCanvasText + // object does not always display scaled-up fonts cleanly (in TQt 3.1.1). if (title != 0) title->close (TRUE); // Close and delete previous title. @@ -210,7 +210,7 @@ void KGrCanvas::makeTitle () title->setPaletteForegroundColor (textColor); title->setFont (TQFont (fontInfo().family(), (baseFontSize * scaleStep) / baseScale, TQFont::Bold)); - title->setAlignment (Qt::AlignCenter); + title->tqsetAlignment (TQt::AlignCenter); title->raise(); title->show(); } @@ -257,12 +257,12 @@ void KGrCanvas::makeHeroSprite (int i, int j, int startFrame) i++; j++; heroSprite->move (i * 4 * STEP, j * 4 * STEP, startFrame); heroSprite->setZ (1); - heroSprite->setVisible (TRUE); + heroSprite->tqsetVisible (TRUE); } void KGrCanvas::setHeroVisible (bool newState) { - heroSprite->setVisible (newState); // Show or hide the hero. + heroSprite->tqsetVisible (newState); // Show or hide the hero. } void KGrCanvas::makeEnemySprite (int i, int j, int startFrame) @@ -396,8 +396,8 @@ void KGrCanvas::initView() #else TQPixmap * pm; TQPoint * pt; - QList<TQPixmap> pmList; - QList<TQPoint> ptList; + TQList<TQPixmap> pmList; + TQList<TQPoint> ptList; pt = new TQPoint (0, 0); // "Hot spot" not used in KGoldrunner. @@ -469,7 +469,7 @@ void KGrCanvas::initView() #ifdef QT3 enemySprites = new TQPtrList<TQCanvasSprite> (); #else - enemySprites = new QList<TQCanvasSprite> (); + enemySprites = new TQList<TQCanvasSprite> (); #endif enemySprites->setAutoDelete(TRUE); } |