Choosing your development toolkit for desktop application programming

Although most programmers today focus on web-based programming, databases, macros and scripts, it is the desktop application which still seen as the most prestigous and most difficult type of programming. Partly, writing desktop applications is perceived as a more arduous and more skilled task because it is generally done in languages such as C or C++ which require more mucking in the tricky details of pointers and memory management. Mostly, however, the real challenge of writing desktop applications lies in the mastering of an operating system’s graphical interface system. Getting that nice window and pretty buttons to appear on the screen can be a daunting task.

Fortunately, there are a number of development toolkits which can vastly simplify the task, so you can make windows and buttons in record time. Which development toolkit you choose depends on your needs, your pocketbook, and even your political and ideosyncratic preferences. This article will lay out the basic choices and hopefully give you some pointers to think about when choosing your toolkit. Since I am an amateur programmer, people who program for profit may not find my comments as helpful, although I may give you some thoughts to chew on.

Most programmers simply assume that they should use Microsoft Foundational Classes (MFC) since the majority of programmers uses them. A smaller percentage are wedded to Borland’s OWL. Both of these choices, however, are costly and lock you into a single platform.

Although the world is dominated by Windows today, there are reasons to not marry yourself exclusively to Microsoft’s platform. Today Microsoft Windows dominates the desktop and probably will for decades to come, but people who contract for specialty software often have reasons to choose a UNIX-like platform such as security, stability, scalability and customability. Looking at how fast GNU/Linux has grown in the embedded and server markets in recent years, it would not be wise to choose a toolkit which isn’t capable of functioning in a UNIX-like environment. Much of the server and specialty software market is moving to GNU/Linux and other UNIX platforms like BSD and Solaris. People who want software which harnesses multiple processors and embedded microprocessors are turning to UNIX-like platforms in increasing numbers. Microsoft is certainly a player in the server and embedded markets, but not the majority player.

It is precisely in the big and small processor environments where much of the application development work can be found today, since these areas need custom software which are designed for their special needs. Certainly Windows Server and Windows CE work on big and small iron, respectively, but GNU/Linux is growing much faster. Today, Windows % of Servers and %.

Unlike on the computer desktop, the user often doesn’t have any idea what OS is running under the hood, and even when they do, the Windows logo generally isn’t the deciding factor for buying a embedded device. People buying devices with tiny screens don’t necessarily expect to see a Windows logo, so hardware makers are free to chose any OS which serves their needs. Windows CE generally requires more memory and processing power than competing OSes, so hardware manufacturers are Although Microsoft Windows CE has been capturing market share in the embedded market, overtaking Palm and other more established OSes, embedded GNU/Linux has been growing even faster. Makers of embedded hardware want to be able to customize and tinker with their OS, and Microsoft hasn’t been able to compete with GNU/Linux on these terms.

The fact that Microsoft released parts of Windows CE 6 under an open source license shows that Microsoft realizes how precarious its position has become when competing against much freer GNU/Linux in the embedded market.

Cracks are starting to show in the Microsoft monopoly, with a number of governments such as Brazil, Venezuela, South Korea, and China openly advocating the use of GNU/Linux. The European Union is showing a new toughness in confronting Microsoft’s monopolistic practices. A number of the major computer venders now offer to sell Linux machines online even if they are hard to find on the website. This Christmas Walmart will be selling low-end Linux boxes. Although everyone still uses Linux, millions of people are downloading the latest version of Ubuntu and setting up dual-boot machines at home to play with Linux.

Of course people have been predicting for over a decade that the upcoming year would be the GNU/Linux on the desktop, but it There have been important reasons All of these does not auger well for the Microsoft Windows

Mac OS X, which is based on BSD, has long been considered a declining platform, but the Mac’s recent move to Intel processors may open a whole new market if Apple decides to market it correctly. If Apple agressively promotes OS X on the standard may suddenly be a viable alternative to the millions of people who are fed up with the bugs, unreliability and unsafe architecture of the Windows system, but daunted by the tecnical challange of installing GNU/Linux.

wxWidgets, which used be known as wxWindows until Microsoft forced them to change their name in 2005, is a extremely versatile toolkit running on virtually every major platform. It is the best cross-platform toolkit for embedded market, running on Windows CE and embedded GNU/Linux with X11 (tinyX). The Palm OS 6 (Cobalt) port is not yet fully developed, but progressing rapidly. wxWidgets is a excellent toolkit for UNIX-like systems which have little memory and processing power, since its wxUniversal toolkit can run on top of X-Windows with direct calls to Xlib. It has been around since 1992, so it has support for older systems such as DOS, OS2, Windows95 and Mac OS 9.1. wxWidgets is considered easier to learn than GTK+ and usually requires less coding than GTK+, but just as free both in its cost and its license (LGPL with a few modifications). Like GTK+, it is developed by an open community, although it doesn’t count on as much corporate support as GTK+. Like GTK+ and Qt, this toolkit works with almost any language, including C#, Python, Ruby, PHP, Haskell, Lua, Eiffel, BASIC, Java, JavaScript, and Euphoria. The notable exception is C which xWidgets doesn’t support since it is programmed in C++ and relies heavily on objects. If you aren’t an object-oriented programmer, it is best to avoid wxWidgets, because it will force you to think in that way.

Although wxWidgets can run directly on top of X11, most people use the UNIX/Linux port which is based on the GTK+ 2 widget set, so it is a tad slower than just writing your programs with GTK+, since it has to go through an extra translation layer. wxWidgets doesn’t have nearly as good of support for graphics as GTK+, and people who want graphics capabilities often make calls to GTK+ functions inside wxWidgets. Like GTK+, wxWidgets suffers from haphazard documentation of its functions, since there is no company overseeing its development. There is only one book available to learn the toolkit, which was coauthored by Julian Smart, the founder of wxWidgets. A number of the more popular IDEs support wxWidgets such as KDevelop, Bloodshed Dev C/C++ and MinGW Developer Studio, plus some specially designed IDEs such as CodeBlocks and wxHatch. In my opinion, the GUI editors (resource editors) for wxWidgets such as wxGlade and DialogBlocks aren’t as good as Glade 3 for GTK+.

FLTK (Fast and Light Tool Kit) requires little processing power and memory to run this toolkit. The people who use FLTK swear by it, but they are a small crowd. There are no high profile projects which use FLTK, making it unlikely that you will get a corporate job programming in FLTK in the near future. FLTK requires that you are comfortable with pointers when programming. It has fewer built-in widgets and functions and is less developed than Qt, Gtk+ and wxWidgets. Documentation is even less than Gtk+ and wxWidgets and there are no books on it, so you will have to learn by reading the API documentation. Still, if you like being closer to the bare metal of the OS and like to participate of a developing project, FLTK may be your type of toolkit. If you want to develop embedded applications, wxWidgets is better due to its support for most of the major embedded OSes, but FLTK may be a good choice for embedded Linux running X11 (tinyX).

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s