From fef846914f8db6dc117e206ef913d519bf6bb33e Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Mon, 29 Jul 2024 12:43:23 +0900 Subject: Rename basic widget nt* related files to equivalent tq* Signed-off-by: Michele Calgaro --- doc/html/tutorial1-13.html | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'doc/html/tutorial1-13.html') diff --git a/doc/html/tutorial1-13.html b/doc/html/tutorial1-13.html index c2a54718f..b9b83a367 100644 --- a/doc/html/tutorial1-13.html +++ b/doc/html/tutorial1-13.html @@ -90,7 +90,7 @@ except that we've added some lines at the end: widget's children.

        l->addWidget( lcd, 1 );
 
-

At the top we add the TQLCDNumber with a non-zero stretch. +

At the top we add the TQLCDNumber with a non-zero stretch.

        l->addWidget( slider );
         l->addWidget( label );
 
@@ -235,8 +235,8 @@ which was last seen as MyWidget. void newGame(); private: - TQLCDNumber *hits; - TQLCDNumber *shotsLeft; + TQLCDNumber *hits; + TQLCDNumber *shotsLeft; CannonField *cannonField; }; @@ -278,7 +278,7 @@ working with self-contained components.

We also use the cannonField's canShoot() signal to enable or disable the Shoot button appropriately.

        TQPushButton *restart
-            = new TQPushButton( "&New Game", this, "newgame" );
+            = new TQPushButton( "&New Game", this, "newgame" );
         restart->setFont( TQFont( "Times", 18, TQFont::Bold ) );
 
         connect( restart, TQ_SIGNAL(clicked()), this, TQ_SLOT(newGame()) );
@@ -286,8 +286,8 @@ the Shoot button appropriately.
 

We create, set up, and connect the New Game button as we have done with the other buttons. Clicking this button will activate the newGame() slot in this widget. -

        hits = new TQLCDNumber( 2, this, "hits" );
-        shotsLeft = new TQLCDNumber( 2, this, "shotsleft" );
+

        hits = new TQLCDNumber( 2, this, "hits" );
+        shotsLeft = new TQLCDNumber( 2, this, "shotsleft" );
         TQLabel *hitsL = new TQLabel( "HITS", this, "hitsLabel" );
         TQLabel *shotsLeftL
             = new TQLabel( "SHOTS LEFT", this, "shotsleftLabel" );
@@ -322,7 +322,7 @@ ordinary functions, too.)
     {
         if ( cannonField->gameOver() || cannonField->isShooting() )
             return;
-        shotsLeft->display( shotsLeft->intValue() - 1 );
+        shotsLeft->display( shotsLeft->intValue() - 1 );
         cannonField->shoot();
     }
 
@@ -331,8 +331,8 @@ air, we return immediately. We decrement the number of shots left and tell the cannon to shoot.

    void GameBoard::hit()
     {
-        hits->display( hits->intValue() + 1 );
-        if ( shotsLeft->intValue() == 0 )
+        hits->display( hits->intValue() + 1 );
+        if ( shotsLeft->intValue() == 0 )
             cannonField->setGameOver();
         else
             cannonField->newTarget();
@@ -343,7 +343,7 @@ number of hits. If there are no shots left, the game is over. Otherwise,
 we make the CannonField generate a new target.
 

    void GameBoard::missed()
     {
-        if ( shotsLeft->intValue() == 0 )
+        if ( shotsLeft->intValue() == 0 )
             cannonField->setGameOver();
     }
 
@@ -351,8 +351,8 @@ we make the CannonField generate a new target. shots left, the game is over.

    void GameBoard::newGame()
     {
-        shotsLeft->display( 15 );
-        hits->display( 0 );
+        shotsLeft->display( 15 );
+        hits->display( 0 );
         cannonField->restartGame();
         cannonField->newTarget();
     }
-- 
cgit v1.2.3