Skip to main content

Trolltech's Qt 4.3.0 really begins to dazzle

It's not hard to impress me with new visual software. I love eye candy, the flashier the better. So it should come as no surprise that I'm awfully impressed with the latest version of the Qt framework, 4.3.0. I installed it on three systems for a quick and dirty evaluation; algol (my XP Core Duo notebook), europa (my OpenSuse 10.2 Athlon XP system), and my daughter's Toshiba Satellite A135 notebook running Vista Home Premium. I've got screen shots from XP and Suse, but I didn't bother to do a Vista capture. I'll explain why later.

Installing Qt Windows Open Source Edition is dead simple. Download and click on the installation binary. It will install the complete Qt set of tools and examples, and if you don't have it installed already, it will also install a copy of MinGW to compile applications with Qt. Note that the Windows version of the Qt framework does not have to be compiled. Everything is pre-built and ready to use. The screen shot below is the application QtDemo with three of the demo applications launched and arranged around it.

One really interesting new feature is the integration of Javascript into the framework. You can see the Javascript demo running in the very small window at the bottom of the screen. It's displaying an analog clock. That clock is being setup in Javascript, and rendered using calls to Qt's underlying graphics primitives. Very slick.

Installing Qt X11 Open Source Edition and getting it to work takes a little more effort. Qt is the foundation for KDE, so it's usually already installed (minus the examples and demos). To get the absolute latest you download the sources, run configure, make, and make install. No big deal, but with this framework it takes some number of hours on europa. Once built and installed it's then available for demonstrations and further development.

When I built Qt 4.3.0 I decided to build it with the latest version of gcc, 4.2.0. I figured I'd test the latest gcc's C++ compilation capabilities with a reasonably non-trivial set of source code. I did that, it succeeded in building, and then QtDemo failed to execute. It died with a signal 11. You can see where it segfaulted (via gdb) in the window below.

Well, I knew I was pushing my luck by compiling the latest Qt with the latest gcc. So I simply changed my environment to use the older gcc (the default 4.1.2 for Suse 10.2) and moved the binaries and installation built with gcc 4.2.0 out of the way, as it were. Then I uncompressed Qt again, and rebuilt everything with gcc 4.1.2. Sure enough, QtDemo ran just fine (as you can see below). I don't know if I should file a bug report with Trolltech or the gcc developers, but right now it looks like Qt 4.3.0 has compilation issues with gcc 4.2.0. I'd have to do a fair amount of debugging to see if there really is a compiler problem or if there's a linker issue between executables and libraries built with gcc 4.2.0 linked against other libraries in the Suse distribution built with gcc 4.1.2.

Once I got Qt rebuilt with 4.1.2 and installed I fired up QtDemo and started four of its demo applications. Three of them match the same demo apps I started on Windows. The forth was a little Bit Torrent client in the upper left corner of the screen. I decided to download the latest Fedora release with it, Fedora 7 Live CD. And it worked. Yes, it's very primitive compared to Azureus and KTorrent, but the fact it was included demonstrates the depth and breadth of the Qt demonstration applications as well as the power of the framework.

I should also note that all the full-screen screen shots were made with the Screenshot demo app (Desktop | Screenshot).

Observations

The best 'experience' was under Windows XP. Every application was pre-built and every demo ran, especially the OpenGL demos. What's more, the bouncing green balls only appeared on the QtDemo main page when it ran under Windows XP. That effect was missing on both the Suse and Vista installations.

Under OpenSuse 10.2, everything built except the OpenGL demos. I'm still trying to find out why. OpenGL demos have built under every other Qt release, such as 4.2.3. Other than OpenGL everything built and runs just fine. What was nice is that it picked up my OpenSuse KDE theme and used it where appropriate. Everything ran as smoothly under OpenSuse as it did Windows XP. That's interesting to me as OpenSuse runs on a single core Athlon XP (32-bit), while my Windows XP system is powered by a Core Duo. It will take more sophisticated applications to begin to see differences between the two platforms.

Of the three, the Vista installation was the least satisfying. None of the OpenGL demos worked. I'm none too impressed with the Vista theme. It looks too much like a bad Beryl theme. That's why I didn't bother to grab any screen shots from Vista. It would have been pointless.

I expect this version of Qt to really shine on Linux, Windows and Mac OS X. If you haven't stepped up from Qt 3 to Qt 4, then this is the version to seriously consider switching to. And if you've got an older version of Qt 4, then this is most definitely the version to update to. I'll have more to write about this release of Qt in the near future.

Comments

  1. Hi Bill,
    Read your post on Qt with interest.
    I recently intalled Qt4.3.0 on
    my Fedora 7 VM Appliance that has
    gcc 4.1.2. I get seg fault using
    "qtdemo" and the error is the same
    as you got while using gcc 4.2.0:
    >> QMetaObject::activate...
    >> ...kernel/qobject.cpp:2985
    >> 2985 void QMetaObject...
    Do you have any suggestions on
    how I diagnose this seg fault?
    Thanks,
    Ravi

    ReplyDelete
  2. I read this entry with great interest. Thank you.

    ReplyDelete

Post a Comment

All comments are checked. Comment SPAM will be blocked and deleted.

Popular posts from this blog

A Decade Long Religious Con Job

I rarely write inflammatory (what some might call trolling) titles to a post, but this building you see before you deserves it. I've been seeing this building next to I-4 just east of Altamonte/436 and Crane's Roost for nearly 12 years, and never knew who owned it. Today on a trip up to Lake Mary with my wife I saw it yet again. That's when I told her I wanted to stop by on the way back and poke around the property, and photograph any parts of it if I could.

What I discovered was this still unfinished eighteen story (I counted) white elephant, overgrown with weeds and yet still under slow-motion construction. It looks impressive with its exterior glass curtain walls, but that impression is quickly lost when you see the unfinished lower stories and look inside to the unfinished interior spaces.

A quick check via Google leads to an article written in 2010 by the Orlando Sentinel about the Majesty Tower. Based on what I read in the article it's owned by SuperChannel 55 WA…

cat-in-a-box channels greta garbo

So I'm sitting at my computer, when I start to notice a racket in back. I ignore it for a while until I hear a load "thump!", as if something had been dropped on the floor, followed by a lot of loud rattling. I turn around and see Lucy in the box just having a grand old time, rolling around and rattling that box a good one. I grab the GX1 and snap a few shots before she notices me and the camera, then leaps out and back into her chair (which used to be my chair before she decided it was her chair).

Just like caring for Katie my black Lab taught me about dogs, caring for Lucy is teaching me about cats. She finds me fascinating, as I do her. And she expresses great affection and love toward me without coaxing. I try to return the affection and love, but she is a cat, and she takes a bat at me on occasion, although I think that's just her being playful. She always has her claws in when she does that.

She sits next to me during the evening in her chair while I sit in mi…

first night for the gingersnaps

The first night has passed and the two have managed to survive, in spite of what their tiny hearts might have thought when first arriving. Greebo, the larger of the two, has been in hiding the entire time so far. Ponder has spent the time zipping in and out of hiding spots, checking things out, and learning just how comfortable pillows are for resting your head.

During the night I felt the tiny body of Ponder hitting the bed as he leaped up on the side, and then climbed to the top to run around on top of me. At least once he play-attacked my fingers. He might be small but his claws are still quite sharp.

When I got up in the morning the bowl of cat kitten food was fairly well depleted. It's been refilled and fresh water put in the big dish on the floor. I'm assuming that both Greebo and Ponder are feeding and drinking. I have seen Greebo under the furniture peeking out at me when I went looking for him. I'm leaving him alone while he continues to adjust.

So far the guys h…