PDA

View Full Version : Pop Up Windows in Qt



AlecC
6th June 2011, 00:37
Hi, I'm new to Qt and I wanted to make a gui for a program I was making. What I want to know is how exactly do you make a pop up window for a program because my program is intended to check a website and tell you if an update had occurred. Originally I just made it print out something like "Update" on the command line. But since I added a GUI I want it to now have a dialogue box come up that says "Update" when an update does occur. Also could someone tell me how to make another dialogue box with a list that just keeps track of all previous updates like in my original one i had "Update 8:45" and "Update 9:00" with the time it happened next to it . So I want to make some kind of window, dialogue box, or tab that keeps track of it or at least dumps out the string of it into a list continuously after each update. Help please I'm really desperate right now >.>, I really appreciate it.

ChrisW67
6th June 2011, 01:35
What have you tried? QDialog for example?

AlecC
6th June 2011, 04:03
So far I've tried to reproduce what an example from QtCreator did, the AddressBook example. They had a button in a dialogue box which opened up another dialogue box to insert addresses and I tried to make it so that instead of clicking the button as a signal I would use something that would automatically tell the dialogue box to appear when an update occurred. The only problem is I don't know how to define that signal because so far I've only been working with clicked() as a signal.

Added after 1 53 minutes:

Actually this signals and slots problem is what is really getting me. Do you have any advice or do you know of a good tutorial for signals and slots because I have already read the one provided at http://doc.qt.nokia.com/4.7/signalsandslots.html and I still don't feel like I have a good understanding of it. Signals can be created by adding emit at the end of a method (along with some other stuff), but I do not understand what to emit and ho would it emit because the tutorial said that it would emit due to a change in a function but it is pretty vague on what that change is.