GUnit documentation now online

GUnit

On Friday Peter Hagg has put the official GUnit documentation online.

There’s a manual, API reference and some demos (like a “Our first test case”) and samples.

GMainLoop vs. worker thread

A few days ago Emmanuele blogged about “Lazy loading”. He illustrates how to make it possible to offload the loading of many items in for example a liststore. Yet not having to use a worker-thread.

Interestingly I used the exact same technique for destroying the header proxy instances in the summary view of tinymail. ps. Grep for “relaxed” in that source-code.

Note that tinymail uses proxy instances and a custom gtktreestore implementation for making it possible to show huge amounts of rows in the view (yet not using a lot memory, which is the most important aspect of tinymail). It basically uses the model view controller paradigm in such a way that only the visible rows are really loaded. It really depends on the context which technique you should use. So called “programming patterns” (like design patterns) don’t exist to force you into using a specific one. They serve as a guideline.

I guess both samples illustrate that you can do various tasks in the background without using threads.