Home > Articles > Programming > User Interface (UI)

  • Print
  • + Share This
Like this article? We recommend

Other Contestants

You're likely to hear of several other toolkits, especially if your preferred platform is UNIX. All are similar to Qt in offering relatively rich widget sets, having relatively liberal licensing, and being portable to Windows and sometimes beyond (at least in principle). Here are a couple of the main contenders:

  • GTK+ is the basis for such well-known applications as the GIMP image manipulator and GNOME desktop environment. GTK+ and Qt are close rivals in many respects. GTK+ is particularly popular in Linux-oriented shops. I find Qt's documentation far better than GTK+'s; moreover, Qt is designed for C++ programming, while GTK+'s native bindings are with C. Qt-based development feels "cleaner" to me, and the Qt libraries more mature and, in my experience, more portable. On the other hand, the GTK+ maintainers have lofty ambitions for their toolkit, and have made a great deal of progress over the last few years.

  • wxWindows is arguably as mature as Qt, and boasts a less restrictive license. Like Qt, its native binding is to C++. While programming with wxWindows strongly resembles Qt programming, its architectural design is quite different. wxWindows relies on native toolkits on different platforms (GTK+ or Motif for UNIX, MFC for older Windows versions, and so on), while Qt takes responsibility for this layer. This difference affects development less than many observers advertise; what should matter are the ease of programming and the achieved appearance of the two libraries, which are quite close. In this perspective, architecture becomes a religious dimension, one which the experienced Qt and wxWindows maintenance teams have largely rendered moot by the excellence and compatibility of their libraries.

There are at least a dozen other toolkits in common use, including XPCOM, Fox, and FLTK. You should be familiar with at least the following two, which originated in the 1980s:

  • For more than a decade, Motif was the unrivaled leader among UNIX-hosted GUI toolkits. Motif and its open source work-alike Lesstif are still available for all UNIX platforms and remain in wide use, mostly in older applications. Motif is designed for C bindings. While it remains quite capable, at least on a theoretical level, it simply doesn't provide the appearance that most end users have come to expect. I'm a good Motif programmer, but I recommend that my clients choose a newer toolkit for all but very exceptional projects.

  • Most of my programming relies on Tk. I generally use a scripting interface to Tk, though; it's simply not as convenient for C++ programming, and Qt and wxWindows are better choices for projects committed to pure C++ coding. Also, although Tk's visual appearance is quite customizable, the default for the current release is to look as "old-fashioned" as Motif. Before you make such a commitment, consider whether Tk's flexibility and portability might persuade you to consider a two-language architecture.

  • + Share This
  • 🔖 Save To Your Account