diff options
Diffstat (limited to 'doc/html/tutorial1-04.html')
-rw-r--r-- | doc/html/tutorial1-04.html | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/doc/html/tutorial1-04.html b/doc/html/tutorial1-04.html index 005aa983c..820cc797d 100644 --- a/doc/html/tutorial1-04.html +++ b/doc/html/tutorial1-04.html @@ -59,11 +59,11 @@ public: <a href="qwidget.html#setMinimumSize">setMinimumSize</a>( 200, 120 ); <a href="qwidget.html#setMaximumSize">setMaximumSize</a>( 200, 120 ); - <a href="qpushbutton.html">TQPushButton</a> *tquit = new <a href="qpushbutton.html">TQPushButton</a>( "Quit", this, "tquit" ); - tquit-><a href="qwidget.html#setGeometry">setGeometry</a>( 62, 40, 75, 30 ); - tquit-><a href="qwidget.html#setFont">setFont</a>( TQFont( "Times", 18, TQFont::Bold ) ); + <a href="qpushbutton.html">TQPushButton</a> *quit = new <a href="qpushbutton.html">TQPushButton</a>( "Quit", this, "quit" ); + quit-><a href="qwidget.html#setGeometry">setGeometry</a>( 62, 40, 75, 30 ); + quit-><a href="qwidget.html#setFont">setFont</a>( TQFont( "Times", 18, TQFont::Bold ) ); - <a href="qobject.html#connect">connect</a>( tquit, SIGNAL(<a href="qbutton.html#clicked">clicked</a>()), qApp, SLOT(<a href="qapplication.html#tquit">tquit</a>()) ); + <a href="qobject.html#connect">connect</a>( quit, SIGNAL(<a href="qbutton.html#clicked">clicked</a>()), qApp, SLOT(<a href="qapplication.html#quit">quit</a>()) ); } @@ -116,15 +116,15 @@ constructor. <p> Because this widget doesn't know how to handle resizing, we fix its size by setting the minimum and maximum to be equal. In the next chapter we will show how a widget can respond to resize event from the user. -<p> <pre> <a href="qpushbutton.html">TQPushButton</a> *tquit = new <a href="qpushbutton.html">TQPushButton</a>( "Quit", this, "tquit" ); - <a name="x2308"></a> tquit-><a href="qwidget.html#setGeometry">setGeometry</a>( 62, 40, 75, 30 ); - <a name="x2307"></a> tquit-><a href="qwidget.html#setFont">setFont</a>( TQFont( "Times", 18, TQFont::Bold ) ); +<p> <pre> <a href="qpushbutton.html">TQPushButton</a> *quit = new <a href="qpushbutton.html">TQPushButton</a>( "Quit", this, "quit" ); + <a name="x2308"></a> quit-><a href="qwidget.html#setGeometry">setGeometry</a>( 62, 40, 75, 30 ); + <a name="x2307"></a> quit-><a href="qwidget.html#setFont">setFont</a>( TQFont( "Times", 18, TQFont::Bold ) ); </pre> <p> Here we create and set up a child widget of this widget (the new widget's -parent is <tt>this</tt>) which has the widget name "tquit". The widget +parent is <tt>this</tt>) which has the widget name "quit". The widget name has nothing to do with the button text; it just happens to be similar in this case. -<p> Note that <tt>tquit</tt> is a local variable in the constructor. MyWidget +<p> Note that <tt>quit</tt> is a local variable in the constructor. MyWidget does not keep track of it, but TQt does, and will by default delete it when MyWidget is deleted. This is why MyWidget doesn't need a destructor. (On the other hand, there is no harm in deleting a child @@ -132,7 +132,7 @@ when you choose to, the child will automatically tell TQt about its imminent death.) <p> The setGeometry() call does the same as move() and resize() did in the previous chapters. -<p> <pre> <a name="x2306"></a><a name="x2304"></a> <a href="qobject.html#connect">connect</a>( tquit, SIGNAL(<a href="qbutton.html#clicked">clicked</a>()), qApp, SLOT(<a href="qapplication.html#tquit">tquit</a>()) ); +<p> <pre> <a name="x2306"></a><a name="x2304"></a> <a href="qobject.html#connect">connect</a>( quit, SIGNAL(<a href="qbutton.html#clicked">clicked</a>()), qApp, SLOT(<a href="qapplication.html#quit">quit</a>()) ); } </pre> <p> Because the MyWidget class doesn't know about the application object, it |