Page Personnelle de Vincent Kerhoas
Vincent Kerhoas
Professeur Agrégé
Page Personnelle de Vincent Kerhoas

Créer des IHM avec Qt

EX2 : AFFICHAGE D’UN MESSAGE (après appui sur un bouton)

Signal = Message envoyé par un widget lorsqu’un événement se produit
Ex : Clic sur un bouton (clicked())

Slot = Fonction appelée lorsqu’un événement s’est produit
Le Signal appelle le Slot
Slot == méthode d’une classe
Ex : Slot quit() (class QApplication) –> arrêt du programme

OBJET 1   OBJET 2
Attributs    
Méthodes    
Signaux ———> Slots
Slots    

main.cpp


mywindow.h


mywindow.cpp