What’s up with the scrollbar?

First, it was Ubuntu which innovated in the scrollbars creating a nice overlay, but making them unusable for those like me using a track pointer or a mouse without wheel.

Now, with GTK-3.0, the scrollbars have also changed their default behavior and when clicking above or below, the scrollbar moves immediately to that position.

Again, this makes it unusable unless you have a wheel in your mouse or have another fancy way of scrolling, like a touch pad.

I’m nowadays a proud owner of a Lenovo X220 and I use the track pointer included disabling the annoying touch pad thanks to the Touchpad Indicator GNOME extension. I say “annoying” because, when using the track pointer, I tend to touch every now and the the touch pad with unpredictable results.

So, with the new behavior and without the possibility of scrolling with a mouse wheel or a touch pad, viewports with a long extension are really difficult to browse with the pointer. This is the case for several of my mail folders in Evolution. As a result, I was getting nuts.

Therefore, I wanted to go back to the old behavior. This is: when clicking above the bar it would mean “PgUp” and when clicking below “PgDown”.

Fortunately, GTK-3.0 provides a way of tuning this. You have to add an option to its “settings.ini” file. If you want to apply it system wide, you will do it in “/etc/gtk-3.0/settings.ini” while if you want only to affect an user, you will do it in “~/.config/gtk-3.0/settings.ini”.

This is how it looks like:

Hope this helps to someone else! 🙂

Introducing Facerecognition Resetter Plugin for the Nokia N9

As my mate SimĂłn was writing short time ago in his post Announcing the Gallery Tilt Shift plugin for the Nokia N9, we got published at Igalia some plugins for enhancing the experience of the built-in Gallery application in the N9/N950 through the Nokia Store: Enlarge & Shrink Plugin, Gallery Tilt Shift Plugin, and Facerecognition Resetter Plugin.

The Enlarge & Shrink Plugin is a filter developed by AntĂ­a Puentes for the built-in Gallery application which applies a radial distortion to a picture featuring an enlarge or shrink effect (also known as punch or pinch).

The Gallery Tilt Shift Plugin is a filter developed by SimĂłn Pena for the built-in Gallery application which makes a picture look like a miniature.

Finally, Facerecognition Resetter Plugin was developed by me. It is a add-on for the built-in Gallery application which is not a real filter for the pictures. Instead, it is just a way of forcing the deletion or un/protection of the face recognition database through its usage from Gallery. The main reason for doing this is a well known bug in the face recognition feature.

If you are experiencing that the the N9 is not recognizing faces any more or it is not giving any more suggestions just install Facerecognition Resetter Plugin and click on the “Protect” button. You want to do this even if you are not suffering this problem since this will prevent it from appearing in the future.

BTW, comments and reviews in the Nokia Store will be welcomed 😀

But, specifically, why would we want to reset or un/protect the face recognition database? Or, actually, what the heck is that face recognition database? Let’s get to the beginning.

When Nokia released the PR1.2 update for the Harmattan platform they included a new feature which made the N9 to be the first smartphone with integrated automated face recognition.

This feature, when activated, let the Gallery or Camera application to automatically recognize faces on the pictures stored in the device, showing a white bubble with a question mark on top of the region detected as a face.

Clicking on such bubble you would be able to select one of your contacts to be assigned as the detected face.

The algorithm would be even learning as the user selected and assigned faces to contacts so at some point it would be also suggesting the proper contact for the detected faces. The user, then, would only have to double tap on the suggestion bubble to confirm such contact.

Everything seemed great but after a while, some users started to complain that this feature eventually stopped working. Either it was not suggesting anyone, when there were people tagged in a big number of pictures or it was just not recognizing faces any more.

As with any software, the face recognition feature contains bugs and this problem was the consequence of one that Nokia has not yet fixed to the current date.

The technical explanation is that the algorithm that performs the face detection relies in SQLite to store its learning parameters and contacts. This database is located at:

/home/user/.local/share/gallerycore/data/faces.db

This file and its directory are protected through the usage of the AEGIS “powered” gallerycoredata-user user and gallerycoredata-users group. Also, the file permissions mask for them are 070 in the case of the directory and 060 in the case of the file.

When doing transactions to the database file the SQLite driver may create some temporal files as the journal one, to be able to recover the database under disaster. This journal file gets the UID and GID of the running process and the permissions from a combination of the permissions of the original database file and the running process’ umask. As a consequence, the journal file usually has the permissions mask 040.

While using the Camera or Gallery application the SQLite file is open. Whether a disaster may happen, although we hold the journal file, the owner of that file is not able to read it. Hence, the SQLite database remains useless for the processes with the same UID than the owner of the journal file, even when they belong to the same group than that file.

What it happen afterwards is that the SQLite database remained waiting to be “recovered” using the journal file but as the journal could not be read, the face recognition algorithm could not provide the learned information and suggest contacts any more. The solution for this would have been as easy as to change the file permissions of the journal file but this is not even possible for the root user since only the gallerycore-user user and those belonging to the gallerycore-users group were allowed through AEGIS to read and change the files on the parent directory of the database file.

Hence, the only way of being able to do a hack that would solve this problem was that the actual application doing such changes would be either Gallery or Camera. Fortunately, Gallery had the possibility of being extended through plugins and that’s the reason why Facerecognition Resetter is such.

Following, you can watch a video featuring an usage introduction tutorial and a detailed explanation of its usage below it.

The plugin shows 3 buttons for its corresponding actions:

  • Reset the database: As simple as that. It will delete the directory and files containing all the information gathered through the face recognition algorithm. From that on, the face recognition feature will start to work again but the learning gotten previously and powering the suggestions will be lost.
  • Protect the database: This will correct the permissions of the directories and files containing all the information gathered through the face recognition algorithm. From that on, the face recognition feature will start to work again and the suggestions would have the learning gotten previously. The problem will not show up in the future ever again but the database will remain protected and only usable through Gallery and Camera (or any other application with the proper AEGIS tokens).
  • Unprotect the database: This will correct the permissions of the directories and files containing all the information gathered through the face recognition algorithm. From that on, the face recognition feature will start to work again and the suggestions would have the learning gotten previously. The problem will not show up in the future ever again and the database will be available to any other application that would like to make use of it.

The permissions get corrected when un/protecting since the plugin sets the SGID bit to the parent directory of the database file so any other files created under it will belong to the same group than the directory and not to the GID of the running process that created that file. Also, the database will have now the 660 mask so any temporal file created by the SQLite drive will attempt to keep the same mask.

And with this, we can keep enjoying the usage of the face recognition feature of the N9 and go to celebrate it with some beers!!! 😀

This and the other plugins are Open Source, so you can go to their page at GitHub: Enlarge & Shrink, Gallery Tilt Shift and Facerecognition Resetter

Also, don’t forget to take a look at all the applications published by Igalia at the Nokia Store

Download Facerecognition Resetter Plugin from Nokia Store

Igalia wallpapers

Igalia wallpaper for the N9/N950

“Igalia wallpaper for the N9/N950”

Some weeks ago we decided to do an upgrade to the information that we are showing in our Igalia’s website. Due to these changes, I had the chance to play a little bit with some new graphic material that was used in the upgrade.

As a result, I’ve created based on Opsou’s Pedro Figueras original idea some different wallpapers for most of my GNU/Linux powered devices.

Just click in the images and go to download them at their original resolution.

I’ve uploaded it to a public Git repository which you can download with the following command:

~#  git clone http://git.igalia.com/art/wallpapers.git
4x3 Igalia wallpaper

“4×3 Igalia wallpaper”

16x9 Igalia wallpaper

“16×9 Igalia wallpaper”

Igalia wallpaper for the N900/N810/N800/N770

“Igalia wallpaper for the N900/N810/N800/N770”

Attending the Automotive Linux Summit 2012

Next Wednesday I will be attending the Automotive Linux Summit 2012.

It will be a good time to meet the key people pushing the usage of Linux in the automotive arena and I hope to have a great time at the Heritage Motor Centre in Warwickshire.

If you happen to attend the event and want to have a good chat with an Igalian about any of the technologies in which we are strongly involved: WebKit, rendering, compilers, Grilo, GStreamer, the kernel, Qemu, Yocto, OSTree, Skeltrack, OpenCV, a11y, Qt, Gtk+ and so on. Just poke me whenever you see me around 😉

NSLU2, Grilo and UPnP in Ubuntu’s GNOME

Going quickly to the “ham”, if you are running Ubuntu Precise on your machine and want to have Grilo support including its UPnP plugin in totem and rhythmbox just add Grilo Team‘s PPA:

~#  sudo add-apt-repository ppa:grilo-team/ppa

Then, pull down the latest list of software including the PPA you just added:

~#  sudo apt-get update 

Install the needed packages and upgrate any old one:

~#  sudo apt-get install totem rhythmbox grilo-plugins-0.1
~#  sudo apt-get upgrade

That’s it! Enjoy your Grilo powered totem and rhythmbox!

Now, the long boring story 😉

Last weekend I found some time to resurrect my dear NSLU2 which passed away some months ago when its attached USB hard drive started failing. I have reports from several USB hard drives dying while being attached to a NSLU2 so I may have to take a look to that at some point, but that would be in another moment.

Thanks to good Martin Michlmayr I only had to follow quickly his installation guide and I could have the Debian Squeeze firmware image he provides running smoothly in a matter of minutes.

Afterwards, I followed the counsels of Juan and Mario to tweak my Slug.

The customization to highlight was adding a MediaTomb server since one of the main features that I wanted to add to my Slug was the possibility of serving audio and video through UPnP.

Everything seemed in place but, when I checked in my desktop running Ubuntu Precise how to access my music from rhythmbox and my videos from totem I had a sad surprise. None of them have UPnP support and, what is worse, none of them have Grilo support out of the box in Precise. And I say worse because, among other plugins, Grilo already provides UPnP support and AFAIK, totem and rhythmbox have upstream Grilo plugins for quite some time already.

So, what was the problem? Why weren’t they in Precise?

Well, in the case of rhythmbox it seems just a small mistake in the debian packaging, as it is pointed in this report in Launchpad’s bug 973295. Astonishingly, it has not yet been fixed!

Hence, I downloaded the sources for the precise-proposed rhythmbox’s package and I did the proper changes and uploaded it to the Grilo Team PPA.

Rhythmbox and Grilo 0.1

“Rhythmbox and Grilo 0.1”

In the case of totem what happened was that Grilo’s plugin was removed as for the version that was packaged for Precise, in the road to add a new and better plugin for Grilo 0.2. Which is what it is in totem upstream nowadays.

Therefore, I re-took the old patch for totem’s Grilo 0.1 plugin in GNOME’s bug 628648, downloaded the sources for the precise-proposed totem’s package, patched and uploaded it to the Grilo Team PPA.

Totem and Grilo 0.1

“Totem and Grilo 0.1”

In the path for all these changes I joint the Grilo Team at gitorious and made also some changes to its packaging.

Now I can enjoy my UPnP served music and videos from my favorite applications in GNOME!!!

Hopefully, for the next Ubuntu’s release we will have Grilo 0.2 already integrated and totem will come with its plugin out of the box. By now, rhythmbox’s Grilo plugin has yet not been migrated.

Grilo 0.2 is a great library for accessing the media content from several resources. Juan, the Grilo master, has been working in Igalia writing a new, clean, easily extendable and powerful API that is ready for use and which keeps enhancing everyday. However, Grilo’s adoption is coming surprisingly slow. Out of GNOME other projects have shown quite some interest as it was the case of Media Explorer, but in GNOME I only know of its support by the 0.2 version in totem. Anyone willing to bring the power of Grilo to Music, rhythmbox, banshee and the like? 😀

Update: It seems I rushed too much since Jonathan Matthew migrated rhythmbox Grilo plugin to 0.2 pretty recently. Thanks Matthew!

Tasting some more Spain at GUADEC

GUADEC’s core days finished on Sunday. Some people departed then but still quite a lot of hackers have stayed for the three days of BoF, workshops and hacking.

If you are one of those, you may have already taken a good taste of what Galicia and Coruña can offer.

Therefore, I’m posting this entry to suggest a new option for the ones wanting to try new things from the vast offer os Spanish products.

Coruña is holding these days one of its most important annual festivals and because of that other regions of Spain have set a small town representing them and their typical food and products in the city center. This town has been placed in the “Jardines de MĂ©ndez NĂșñez” (MĂ©ndez NĂșñez’s gardens):


Ver mapa mĂĄs grande

Castilla y LeĂłn, Asturias, Castilla la Mancha, Cantabria, AndalucĂ­a y AragĂłn are the Spanish regions that have an own “house” in this town, although there are several other regions missing.

In their houses you will be able to find good food, usually as tapas, and good drinks. The price rates are a little bit higher than in the local “tapas” places but quite cheap nevertheless.

You are welcome to visit them and try some products, like morcilla (black pudding), from my own region: LeĂłn.

Regional Houses in A Coruña

“Certamen de casas regionales”, by Septem Trionis

GUADEC 2012 T-Shirts and other [d|r]usty artwork

Let’s go quickly to the important stuff: I’ve been helping the great team that is organizing GUADEC 2012 in A Coruña. I cannot count myself among this amazing group of people since I’ve scarcely devoted any time to the tasks they needed from me but this is the result out of it, in the shape of a t-shirt 🙂

GUADEC 2012 Attendant T-Shirt

I cannot get all the credit of it, I was basing the final design on the previous work done by William Carlson and some drafts done by Alba Castro. You can find all the material in this public git repository hosted at Igalia.

Also, I did a small variation for the t-shirts of the staff, which will be red. This is back of the female’s version:

GUADEC 2012 Staff T-Shirt

Doing artwork for GNOME events is no new thing for me. I’ve been regularly doing some stuff for them. Some just for Igalia, my company, but also some other for the event itself.

2010

Last thing I designed before 2012 were the t-shirts (again) for the GUADEC-ES 2010 that took place also in Coruña. I got inspired that year by the soccer world cup that would be won by Spain (yeah!!!). Here you can see the 3 versions, starting by the Brazil one:

GUADEC-ES 2010 Brazil T-Shirt FrontGUADEC-ES 2010 Brazil T-Shirt Back

Denmark:

GUADEC-ES 2010 Denmark T-Shirt FrontGUADEC-ES 2010 Denmark T-Shirt Back

And a female’s version:

GUADEC-ES 2010 Female T-Shirt FrontGUADEC-ES 2010 Female T-Shirt Back

This last model is the one that holds the final sorting of the back logos that was printed for all the t-shirts. Actually, Xulia Barros, from FreeWear did a small modification to the final design leaving some space among the lines for the “7” in the back.

Again, you can find all the material in this public git repository hosted at Igalia.

2006

Even before 2010 I found myself tangled with The Gimp, Sodipodi and Inkscape, later. In 2006 I did a small design for that year’s GUADEC-ES which consisted on the header:

GUADEC-ES 2006 Header

and foot of its webpage:

GUADEC-ES 2006 Foot

The lady was inspired on PasiphaĂ« who has a sculpture in Vilanova’s see shore while the sea tide was inspired by The Great Wave off Kanagawa.

You can find all the material in this public git repository hosted at Igalia.

And finally getting to the end … or maybe better the beginning.

2005

In 2005 Coruña was hosting for the first of several times the GUADEC-ES. For that event I did most of the artwork that was used. Web page, printed banners, badges, talks’ book, but one of the things that I was most proud of was the animated banners that were featuring for some time in Barrapunto, the Spanish version of Slashdot:

GUADEC-ES 2005 Banner Animation

And I learn to do it the hard way. You cannot imagine how difficult was by the time to do a GIF animation with The GIMP!

Also, that year was a great one for the t-shirts. Most of the attendants liked them and we had them in several colors: red, green, blue, orange and, as always (or almost 😉 ), black. I think that was once in a lifetime for a hacker’s conference 😀

GUADEC-ES 2005 T-Shirt

Even, with Chema‘s help, the master of organizing events, I was experimenting with some sketches done directly in the sand, from which I got inspired to do the rest of the material:

GNOME in the sand

Of course, you can find all the material in this public git repository hosted at Igalia.

BTW, if you have been able to read this boring post until here, you are my hero 😀

GUADEC is at home … and I’m abroad

Or kind of … because unlike you may guess from the title, I’m actually attending mighty GUADEC 2012

Attending GUADEC 2012 badge

I’ve attended GUADEC 2006 in Vilanova i la Geltru, GUADEC 2007 in Birmingham, GUADEC 2008 in Istanbul and the Desktop Summit in Gran Canaria as a guest in all of them.

Finally, this year the event comes home but, funnily enough, I moved to Helsinki some months ago so I’m again a visitor. Now in A Coruña 🙂

Honestly, I can’t wait to attend some of the talks and meet again the GNOME folks. Also, my mates Igalians are featuring quite some talks in the program meanwhile Igalia itself has been doing quite an effort to host some of the hackfests and meetings that are happening during these days.

And not only that!. As I was saying, I’m a visitor again so I only have pending to thank Igalia again for sponsoring my trip!

Igalia

Extending the life of your N8x0: Second update for Automatic Skype Launcher

Back again with a new release, the 0.0.3, of Applications Fullscreener and Automatic Skype Launcher.

Just download and install them in your N8x0 for making it become a good 24/7 Skype phone. For more information about the goals and features of this project you can check the previous post Extending the life of your N8x0: Automatic Skype Launcher.

Skype Tango Icon

I took the chance to update also the artwork used in these two applications. First thing, I created a Tango-ized version of the Skype logo.

Then, I used the previous magnificent art works from Andreas Nilsson and Jakub Steiner to create the new icons, and these are the result:

Applications Fullscreener Icon Applications Fullscreener Debian Package Icon Applications Fullscreener Icon Applications Fullscreener Settings Icon

Anyway, going to the actual changes.

The most important change for Applications Fullscreener is:

  • There was a second bash helper to launch a certain application and send the fullscreen key event some time afterwards. It was not fully featured but now it is.

You can, also, check the complete ChangeLog for Applications Fullscreener.

The most important changes for Automatic Skype Launcher are:

  • The Automatic Skype Launcher service was not stopping when uninstalled. Now this is corrected.
  • The init service was not starting correctly in some scenarios due to some uninitialized variables. This has been corrected.
  • In the previous version, I added an alarm triggered by the alarmd daemon to restart Skype (and the service). This was not working always. Now, killing Skype is forced.

You can, also, check the complete ChangeLog for Automatic Skype Launcher.

That’s it. Comments and patches are welcomed!

Extending the life of your N8x0: Update for Automatic Skype Launcher

I’ve just released the 0.0.2 version of Applications Fullscreener and Automatic Skype Launcher.

As I was already commenting in my previous post Extending the life of your N8x0: Automatic Skype Launcher, just download them and install them in your N8x0 for making it become a good 24/7 Skype phone.

The most important change for Applications Fullscreener is:

  • I’ve added a helper to launch a certain application and send the fullscreen key event some time afterwards.
    This is specially useful for launching an application through the DSME watchdog daemon in Maemo4.x. Using this helper as a wrapper, the application will receive the fullscreen event some time after being launched while the watchdog keeps track of the helper. In this case, if either the helper or the application dies, both die and, hence, the DSME will relaunch them both.

You can, also, check the complete ChangeLog for Applications Fullscreener.

The most important changes for Automatic Skype Launcher are:

  • I’ve added a Control Panel plugin for setting several behaviors of the application: starting an init service, using a watchdog for keeping it alive, trying to fullscreen Skype after launching it as a service and the time at which the service will be restarted, if so.

Automatic Skype Launcher Control Panel plugin snapshot

  • I’ve added a Home Desktop applet for making it easier to launch manually Skype, not having to get into the applications menu.

Automatic Skype Launcher Home Desktop applet snapshot

  • The Automatic Skype Launcher service was not stopping when the N8x0 was turned off while charging. Now this is corrected.
  • In the previous version, I added a cron.daily script to restart Skype (and the service). Actually, the N8x0 doesn’t have a cron daemon, by default. This is now corrected through the usage of an alarm triggered by the alarmd daemon.

You can, also, check the complete ChangeLog for Automatic Skype Launcher.

That’s it. Comments and patches are welcomed!