Sharp Qtopia Desktop Spécifications Page 33

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 63
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 32
SHARP CORPORATION
Sharp SL-series Zaurus “Qtopia” Development Start-up Guide
Ver 1.11, February 28, 2003, 33/63
Add SLOT definition to the class definition
In order to create your own slot, you would have to add a Q_OBJECT statement in the ordinary class definition. In
addition, you would also have to add a definition of your own SLOT that you are about to create, by stating the
SLOT name to either
public slots:
or
private slots:
.
class myMainWindow : public Qwidget
{
Q_OBJECT
public:
myMainWindow();
public slots:
void testSlot();
private:
Qlabel *mylabel;
};
Create the actual SLOT
You do not need any special tricks to implement your own SLOT. Code your SLOT just like you do for the
functions and methods you implement.
Connect SIGNAL and SLOT
Use
connect
method to connect the SIGNAL and the SLOT. The following is an example that executes the
created
testSlot
when mybutton is clicked.
Connect( mybutton, SIGNAL(clicked()), this, SLOT( testSlot()) );
Using “moc” (Meta Object Compiler)
The SIGNAL and SLOT framework is Qt specific, and thus you need to do the necessary task for the compilation.
As mentioned earlier, you need to use a “moc” tool to generate source file(s) so that the C++ compiler can
recognize and handle the code. (See section 2.2.3 for the “moc” tool information.)
Vue de la page 32
1 2 ... 28 29 30 31 32 33 34 35 36 37 38 ... 62 63

Commentaires sur ces manuels

Pas de commentaire

Elitegroup 258KA v.7 manuály

Uživatelské manuály a uživatelské příručky pro Notebooky Elitegroup 258KA v.7.
Poskytujeme 1 manuály pdf Elitegroup 258KA v.7 ke stažení zdarma podle typů dokumentů: Uživatelský manuál






Další produkty a příručky pro Notebooky Elitegroup

Modely Typ Dokumentu
258KA v.8 Uživatelský manuál   Elitegroup 258KA v.8 User Manual, 9 stránky
259EI Uživatelský manuál   Elitegroup 259EI Manuale d'uso, 97 stránky
257SA1 v.2 Uživatelský manuál   Elitegroup 257SA1 v.2 User Manual, 10 stránky
257SA1 v.3 Uživatelský manuál   Elitegroup 257SA1 v.3 User Manual, 13 stránky
257SA1 v.1 Uživatelský manuál   Elitegroup 257SA1 v.1 User Manual, 27 stránky
259EI Uživatelský manuál   Elitegroup 259EI Manual del usuario, 98 stránky
257SA1 v.4 Uživatelský manuál   Elitegroup 257SA1 v.4 User Manual [en] , 12 stránky
257SA1 v.6 Uživatelský manuál   Elitegroup 257SA1 v.6 User Manual [en] [fr] , 6 stránky
257SA1 v.8 Uživatelský manuál   Elitegroup 257SA1 v.8 User Manual, 9 stránky
257SA1 v.7 Uživatelský manuál   Elitegroup 257SA1 v.7 User Manual [en] [de] [fr] [it] , 8 stránky
257SA1 v.5 Uživatelský manuál   Elitegroup 257SA1 v.5 User Manual, 17 stránky
257SA1 v.3 Uživatelský manuál   Elitegroup 257SA1 v.3 Manuel d'utilisation, 6 stránky
257SA1 v.4 Uživatelský manuál   Elitegroup 257SA1 v.4 Manuel d'utilisation, 12 stránky
257SA1 v.6 Uživatelský manuál    Elitegroup 257SA1 v.6 Manuel d'utilisation [en] , 6 stránky
257SA1 v.5 Uživatelský manuál   Elitegroup 257SA1 v.5 Manuel d'utilisation [en] , 17 stránky
257SA1 v.1 Uživatelský manuál   Elitegroup 257SA1 v.1 Manuel d'utilisation, 27 stránky
257SA1 v.7 Uživatelský manuál   Elitegroup 257SA1 v.7 Manuel d'utilisation [en] , 8 stránky
257SA1 v.8 Uživatelský manuál   Elitegroup 257SA1 v.8 Manuel d'utilisation [en] , 8 stránky
257SA1 v.3 Uživatelský manuál   Elitegroup 257SA1 v.3 Benutzerhandbuch [en] [es] [fr] , 6 stránky
257SA1 v.5 Uživatelský manuál   Elitegroup 257SA1 v.5 Benutzerhandbuch [en] [ru] [es] [fr] , 17 stránky