Learn Qt

Teaching Qt® to the world!

Flower

Getting Qt

Before you can start learning Qt, you need to download it. The easiest way to do this is to visit http://www.qtsoftware.com and visit their download section. The most likely download you want to make if you’re new to Qt is the open source SDK. It includes everything and can be downloaded for free.

The SDK download page at Qt Software.

The SDK download page at Qt Software.

You’ll find different versions for different platforms – simply pick the one suitable for you. Or, if you’re on Linux, check to see if your distribution has it prepackaged.

Linux TipsAre you running Linux and are unsure about your platform being 32-bit or 64-bit? Simply run uname -m from the console. If the output contains i386 or i686, you’re running 32-bit Linux. If it contains x86_64 or 64bit, then you’re running 64-bit Linux.

Now, all you have to do is to step through the installer to install QtCreator, the latest version of Qt along with all the tools.

fact-logoRunning the installer can be tricky. For instance, on Linux, you might have to make the file run-able by applying chmod +x on it. On Vista, you need to ensure that you have write permissions in the directory where the installer is placed (so that it can extract itself).

As soon as QtCreator is installed, launch it (there should be a desktop shortcut, a start menu entry, or you can simply run it from the command prompt – the choices are endless). This will bring you to the front page shown below (you will probably not have any projects to choose from though).

The QtCreator frontpage.

The QtCreator frontpage.

The front page lets you go through the getting started guide. Do that – it is valuable reading. You can also check out the QtCreator videos posted by Qt Software at YouTube.

When you have looked at videos and browsed the documentation, it is time to actually try your install. Start by selecting File – New…, then create a Qt4 Gui Application.

Creating a Gui Project using QtCreator.

Creating a Gui Project using QtCreator.

The project will be generated from a wizard. Simply go through it, changing as little as possible along the way. This means specifying where your project should reside, click Next tree times and then clicking Finish.

This project should build out of the box, so simply click the big green arrow in the lower left corner (the one without a small bug on it) and wait. In a couple of seconds you should be faced with an empty window titled MainWindow. Congratulations – you’ve just build a Qt application!

Your very first Qt application.

Your very first Qt application.

Be Sociable, Share!

One Response to “Getting Qt”

  1. April 20th, 2009 at 16:29

    Aprende Qt mediante tutoriales | KDE Blog says:

    […] Getting Qt (Obteniendo Qt)-Shows how to download, install and get started with QtCreator and the Qt […]

Leave a Reply

You must be logged in to post a comment.