Wednesday, December 12, 2007

This Blog Has Now Moved!!!

I'll be moving this blog to wordpress from now on. Everything is just so much more sexy over there... :-)

New address;

* Update
Feeds are at
Thanks to Javier for pointing this out.


Time has come to drop the previous profiling and start looking at tile-2 from GNOME svn instead.

I checked out the code this morning and had a look at it. Also took it for a test run and it feels a bit faster.

Next, I'll have to add the "poor mans profiling" code again. I'll also make use of callgrind.

As soon as I have the first profiling done, I'll submit a patch so that the context menu is not added on startup, but when the user right-clicks on an application.

Hope to get some time tomorrow to put up some nice graphs from the first round of profiling.

Sunday, December 2, 2007


Sunday morning, 7.30am. Should really be in bed still but have had problems with sleeping in lately. That's good and bad I guess. The good is that I have more time, The bad is.. uhm... Well, I'm sure there's something bad with not sleeping enough.

Good to see that Michael Meeks is on the case of optimizing as well.

With regards to performance, I don't think it's ever possible to optimize to the point where AB pops up within a second without changing the way it works. At the moment, it will make a call to gtk_widget_show_all which is the most expensive operation in the code. Even if some optimization can be done, the time it takes to show AB will always depend on how many .desktop files you have.

The way to get around that would be to show the window with only the number of apps that are visible, then once it's shown, add the rest of the apps.

I've been experimenting with it, using a loop like this;

void ui_itterator(GtkWidget *wid, gpointer unused)
if (GTK_IS_CONTAINER(wid)) {
while (gtk_events_pending())
gtk_container_foreach(GTK_CONTAINER(wid), ui_itterator, NULL);

while (gtk_events_pending())

No need to start laughing! It's only an experiment to see how it works :-) I need to spend more time with it and figure out how to show all widgets but the apps, calculate how many apps that will fit in the visible window space, then loop through to show them.
I don't know if this is the best approach but something like this is needed for sure. Looking at Nautilus, it will show the window with nothing in it until it fetched all files so I hope I'm on the right track here.