You definitely need to read a Qt tutorial (and maybe a C++ tutorial depending on your knowledge of C++).
Have a look at this SO question : https://stackoverflow.com/questions/475345/
Doing the tutorial, you'll learn how to add buttons to a form and how a function will be triggered when a button is clicked.
I also recommend reading C++ GUI Programming with Qt 4.
Your problem is very simple.
Create console application in QtCreator, and edit your main.cpp this way:
int main(int argc, char *argv)
QApplication a(argc, argv);
// get current date
// create other date
// by giving date 12.21.2012 (joke about end of the world)
QDate dEndOfTheWord(2012, 12, 21);
qDebug() << "Today is" << dNow.toString("dd.MM.yyyy")
<< "Days to end of the world: "
And you'll got output like:
Today is "18.12.2012" Days to end of the world: 3
Today is "18.12.2012" Days to end of the world: 3
P.S. But my advice to you is learn C++ (add to your favorite this topic -- The Definitive C++ Book Guide and List), and then learn Qt (I recommend C++ GUI Programming with Qt 4 by Jasmin Blanchette & Mark Summerfield and Summerfields other books).
Linux is the most accessible and has the most mature desktop functionality. BSD (in its various flavours) has less userspace baggage and would be easier to understand at a fundamental level. In this regard it is more like a traditional Unix than a modern Linux distribution. Some might view this as a good thing (and from certain perspectives it is) but will be more alien to someone familiar with Windows.
The main desktop distributions are Ubuntu and Fedora. These are both capable systems but differ somewhat in their userspace architecture The tooling for the desktop environment and default configuration for system security works a bit differently on Ubuntu than it does on most other Linux or Unix flavours but this is of little relevance to development. From a user perspective either of these would be a good start.
From a the perspective of a developer, all modern flavours of Unix and Linux are very similar and share essentially the same developer tool chain. If you want to learn about the system from a programmer's perspective there is relatively little to choose.
Most unix programming can be accomplished quite effectively with a programmer's editor such as vim or emacs, both of which come in text mode and windowing flavours. These editors are very powerful and have rather quirky user interfaces - the user interfaces are ususual but contribute significantly to the power of the tools. If you are not comfortable with these tools, this posting discusses several other editors that offer a user experience closer to common Windows tooling.
There are several IDEs such as Eclipse that might be of more interest to someone coming off Windows/Visual Studio.
Some postings on Stackoverflow that discuss linux/unix resources are:
What are good linux-unix books for an advancing user
What are some good resources for learning C beyond K&R
Resources for learning C program design
If you have the time and want to do a real tour of the nuts and bolts Linux From Scratch is a tutorial that goes through building a linux installation by hand. This is quite a good way to learn in depth.
For programming, get a feel for C/unix from K&R and some of the resources mentioned in the questions linked above. The equivalent of Petzold, Prosise and Richter in the Unix world are W Richard Stevens' Advanced Programming in the Unix Environment and Unix Network Programming vol. 1 and 2.
Learning one of the dynamic languages such as Perl or Python if you are not already familiar with these is also a useful thing to do. As a bonus you can get good Windows ports of both the above from Activestate which means that these skills are useful on both platforms.
If you're into C++ take a look at QT. This is arguably the best cross-platform GUI toolkit on the market and (again) has the benefit of a skill set and tool chain that is transferrable back into Windows. There are also several good books on the subject and (as a bonus) it also works well with Python.
Finally, Cygwin is a unix emulation layer that runs on Windows and gives substantially unix-like environment. Architecturally, Cygwin is a port of glibc and the crt (the GNU tool chain's base libraries) as an adaptor on top of Win32. This emulation layer makes it easy to port unix/linux apps onto Cygwin. The platform comes with a pretty complete set of software - essentially a full linux distribution hosted on a Windows kernel. It allows you to work in a unix-like way on Windows without having to maintain a separate operating system installations. If you don't want to run VMs, multiple boots or multiple PCs it may be a way of easing into unix.
C++ GUI Programming with Qt4
I also would like to recommend this book: C++ GUI Programming with Qt 4.
It is my favorite !
I would suggest reading the book C++ GUI Programming with Qt4.
It covers almost all features of Qt, is easy to read for a beginner, and also includes an introduction to C++ and Java, explaining the basic concepts required for developing with Qt.
I really enjoyed this book.