From 0f92dd542b65bc910caaf190b7c623aa5158c86a Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Mon, 14 Nov 2011 22:33:41 -0600 Subject: Fix native TQt3 accidental conversion to tquit --- doc/html/designer-manual-6.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'doc/html/designer-manual-6.html') diff --git a/doc/html/designer-manual-6.html b/doc/html/designer-manual-6.html index a1997e542..9c9845df8 100644 --- a/doc/html/designer-manual-6.html +++ b/doc/html/designer-manual-6.html @@ -176,7 +176,7 @@ INCLUDEPATH += $(QTDIR)/tools/designer/uilib

We do not include the creditformbase.ui file since this file will be read at runtime, as we'll see shortly. We must include the tqui library since the functionality we retquire is not part of the standard TQt library.

Creating main.cpp

-

The main.cpp is tquite standard. It will invoke the form we're going to create in TQt Designer as its main form. This form will then load and execute the dynamic dialog.

+

The main.cpp is quite standard. It will invoke the form we're going to create in TQt Designer as its main form. This form will then load and execute the dynamic dialog.

    #include <qapplication.h>
     #include "mainform.h"
 
@@ -194,7 +194,7 @@ INCLUDEPATH += $(QTDIR)/tools/designer/uilib
  

We create a new instance of our MainForm class, set it to be the main widget, show it and enter the event loop in the app.exec() call.

Creating the Main Form

Designing the Form
-
  1. Open the receiver.pro project file in TQt Designer. We'll create a dialog as our main window which we'll use to invoke the dynamic dialog. Press Ctrl+N to launch the New File dialog and click OK to get the default which is a dialog. Change the dialog's name to 'MainForm' and its caption to 'Main Form'. Add two buttons, one called 'creditPushButton' with the text '&Credit Dialog', and the other called 'tquitPushButton' with the text '&Quit'. (For each button click the Push Button toolbar button, then click the form. Change the properties in the property window to those we've just described.)

    +
    1. Open the receiver.pro project file in TQt Designer. We'll create a dialog as our main window which we'll use to invoke the dynamic dialog. Press Ctrl+N to launch the New File dialog and click OK to get the default which is a dialog. Change the dialog's name to 'MainForm' and its caption to 'Main Form'. Add two buttons, one called 'creditPushButton' with the text '&Credit Dialog', and the other called 'quitPushButton' with the text '&Quit'. (For each button click the Push Button toolbar button, then click the form. Change the properties in the property window to those we've just described.)

    2. We will now add a couple of labels so that we can show the settings the user chose in the dynamic dialog. Click the Text Label toolbar button, then click the form below the Credit Dialog button. Change the label's text to 'Credit Rating'. Add another text label below the Quit button. Change its name to 'ratingTextLabel' and its text to 'Unrated'.

    3. We'll now lay out the widgets. Click the form then press Ctrl+G (lay out in a grid).

    4. We'll now handle the signals and slots connections. Invoke the View and Edit Connections dialog and connect the credit dialog button's clicked() signal to a new creditDialog() custom slot (which is created by clicking the Edit Slots... button). Now connect the Quit button's clicked() signal to the dialog's accept() function.

      -- cgit v1.2.1