2007-12-12

12 12 2007

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.





2007-12-02

12 12 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)) {

            gtk_widget_show(wid);

            while (gtk_events_pending())

                  gtk_main_iteration();

            gtk_container_foreach(GTK_CONTAINER(wid), ui_itterator, NULL);

}      gtk_widget_show(wid);

      while (gtk_events_pending())

            gtk_main_iteration();

}

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.





2007-11-30

12 12 2007

Another Friday, another waking up at 3.45 in the morning. But it’s worth it. Lot’s of interesting things happen at that time in the morning, such as birds waking up, the absence of trains but specifically the openSUSE GNOME meeting on IRC (#opensuse-gnome on FreeNode).

It’s a lot of fun participating in these meetings. Perhaps the most important, and fun, bit is the ability to influence the next version of openSUSE.

The openness of the GNOME team has been absolutely fantastic, and the influence that they let us “normal” people have is great, so a big thank you to them for making this happen!

Also, this morning, I got word that a patch I wrote for Slab was accepted;

Nov 30 03:05:15 captain_magnus: thanks for the flicker patch – I submitted it

Fun fun fun 🙂

Having patches accepted not only gives you a feeling of having done something for the greater good (even though this particular patch was sort of a one liner) but also motivation to keep digging in to it.





2007-11-28

12 12 2007

Had a look at a bug report for the Main Menu, where renaming a document doesn’t properly update the URI for the file in the Recent Documents section.

When I started playing with it, I found a bug in the rename routine for Recent Documents.

If you right-click on an item in Recent Documents, you can select Rename. It then makes the document name editable. But unless you press Enter, this field will stay editable. So you can go and right-click on all your documents, select rename and the result is something like this;

Slab-Rename-Bug.jpg

When talking to jpr on IRC, he suggested that it should instead behave like Nautilus. That behavior will save whatever is in the editing field, unless you press ESC which will undo the editing, and exit the editing mode.

So even though this haven’t been reported as a bug, I’ll have a look at it and see if I can fix it up.

Plenty of stuff to do, but so little time 🙂





2007-11-26

12 12 2007

Rodrigo told me about some ideas coming up for the control center (which is using libslab);

* http://liquidat.files.wordpress.com/2007/10/systemsettings.png
* http://bugzilla.gnome.org/attachment.cgi?id=82393&action=view
* No big sidebar on the control center?
* Few choices visible at one time
* Use the same padding as Nautilus

The first three should be very doable and not require all that much work (although not sure what the “arrow back” means)

The “Few Choices” and “Use same padding as Nautilus” probably goes hand in hand. The issue at the moment is that Slab is designed to work with one icon size, so the padding (ie. space between the items) are hard coded.

I’ve already raised this issue with the developers as I want to be able to have a configurable icon size.

More talk is needed with all parties to see what they want to do, but it feels like something fun to do in between measuring performance!





2007-11-21

12 12 2007

Bought a new machine so that I could move to the fast lane.

Intel Core2Quad 8Gb of memory situated on a ASUS Maximus mobo, running openSUSE 10.3 x86_64.

Makes all the difference when profiling and compiling stuff.

Need to figure out how to setup my developer environment though, so have not had time to do much performance work on AB yet.

As soon as I sort it out, graphs will follow 🙂





2007-11-20

12 12 2007

In a previous post, I mentioned that we need to have goals.

I’m going to use Federicos goal of having the App Browser appear <1 second 🙂 Mission impossible? We will see… We have numbers now, so it’s time to take a closer look at the code.

I mentioned that I’ve cheated and actually done some of this before.

Well, I came as far as removing the creation of the context menu for each application. The menu that is added looks like this;

Context menu

It’d be better to create it if/when a user actually right clicks on the application.

So after removing the code that creates the menu, we end up with the following stats;

Prof3

Since this optimization business is not as simple as removing code that speed things up, we now need to come up with code to add this menu “on demand”.