N810 and new GTK+/Hildon stack

hildon

As others have alread commented, the new tablet is now out. But I’m a software guy, so I’ll talk about the software it runs and let others dissect the hardware.

As Michael says we had to break the API to unfuck cleanup the mess that was our stack until now. This sucks, but I think the benefits are worth it: we now use a slightly modified (but ABI compatible, unlike before) GTK+ 2.10.12, the most egregious crack is gone from Hildon, you have cairo, which is used to render almost all the text you see on the device (but use it with moderation please, it’s not a speed demon yet :)), the theming infrastructure is greatly improved, etc.

The differences in our GTK+ are documented for a change, and there’s an on-going effort to provide a coherent start page for the platform at live.gnome.org/Hildon. Now we need the validation of the community, so please port your apps and write new and excellent free software for Hildon.

Posted in General | 3 Comments

GTK+ hacking with Emacs, a small trick

I always like to read others people hacking tips, mostly because I suck a lot at using any tool correctly and I am almost always enlightened by them. Today I’ll try to contribute one small trick to the pool.

I remember the last time I posted something about gtk-look.el, someone asked me: “Why would you want to use that? You know about devhelp right?”. My answer at that point was “It’s faster and I like to get the help inside emacs if it’s possible”. Those are quite valid points on their own, but today I can add more benefits: meet Icicles.

The short description of Icicles is that it adds super-powers to any emacs mini-buffer interaction, among other things. But as always, an example is more instructive than a thousand words.

Say we are merrily hacking on our GTK+ application with GtkTreeView (a classical mistake), and we have, as always, forgotten how to set a treeview in multiple selection mode. No problem, let’s look it up. First, we press C-h C-j , bind in our box to ‘gtk-look’. After that we type ‘selection’, as we’re pretty sure the function will contain that name.

selection

Now we press S-TAB, which is Apropos-Complete in Icicles (ie, show me any string that contains my input).

S-TAB

Well, there’s quite a few huh? No problem, let’s narrow the search with M-*, aka Match-Also-Regexp. This will filter our result with everthing than does not match our input, akin to adding an extra grep to end of a pipe in a shell. So, as we are interested in GtkTreeView, we do M-* tree S-TAB:

Narrow it down

That’s better! In fact I think I see what I want now, gtk_tree_selection_set_mode. So once more… M-* set_mode S-TAB… There’s only one hit now, so Icicles will select it automatically for us in the mini-buffer:

Bingo

Enter, and we open it in our browser of choice (w3m for emacs here):

Doc

Yep, that was it.

Of course the beauty of this is that we did all that pretty fast and without moving our hands from the keyboard.

There are other cool things here, like the ability to save any completion to a cache to speed up things massively. Say, if you hack on GTK+ you are bound to cycle through its docs many times, so save only the gtk API reference search to a cache file and start your completions from there. See this for more details.

This of course barely scratches the surface, so if you use emacs I recommend you to spend some time in the Icicles wiki, install it and play with it. You won’t be disappointed.

Posted in General | 3 Comments

If you see the Buddha on the road, port it to GTK+

Ok, there’s something to play with now for the very early adopters:

  • Checkout Epiphany trunk (http://svn.gnome.org/svn/epiphany/trunk/)
  • Apply the patch on bug 459333
  • Checkout WebKit trunk (http://svn.webkit.org/repository/webkit/trunk)
  • Build and install the GTK port:
    • cd WebKit
    • WebKitTools/Scripts/build-webkit –qmakearg=WEBKIT_INC_DIR=$PREFIX/include/WebKit –qmakearg=WEBKIT_LIB_DIR=$PREFIX/lib –gdk
    • cd WebKitBuild/Release && make install
    • For me the path to the pc file was broken and had to fix it in the Makefile, will open a bug tomorrow
  • Compile Epiphany with –with-engine=webkit flag
  • I didn’t say it would be easy

If everything succeeds you should be able to launch the browser and load URLs from the entry. Beware that the port is very basic, so almost nothing will work. A lot of work is needed both in ephy and webkit, if you want to help come to at irc.gnome.org or at irc.freenode.org.

Some (IMHO) exciting ideas are on the backburner for WebKit-GTK, so stay tuned. The basic summary would be that this could become the really integrated browser GNOME deserves, down to the engine level.

PS: following the tradition of silly hackergotchies someone might want to use this for mine. Photo by the crazy Peruvian (aka Diego).

Posted in General | 17 Comments

Freedom of expression

The next image has made a big splash today in Spain:

Jueves

It’s a satire about our Prince and Princess being extremely happy about the new 2500 euro per newborn the government has announced, because it will be the closest thing to a real salary/job they’ll ever get. The magazine where it’s been published has been censured and retired from the market, charged with “offenses to the Crown”.

I find the mere concept of actually having a King in the 21st century ludicrous, being of the opinion that the system, even being as benign as it is, should be simply dismantled to enlarge the scope of human freedom. What is totally unacceptable is that the existence of the Crown is in fact limiting one of the fundamental rights of every person, freedom of expression. I sincerely hope this will trigger a massive reaction in the Spanish society that will finally put the Royal family where it belongs: the exile.

Posted in General | 10 Comments

Epiphany + Webkit

Ephy Webkit

As jdub would say: crack now, analysis later.

Posted in General | 29 Comments

aoeui: the case for dvorak

It’s been one week now since I switched to the dvorak layout, the main reasons for it being a preemptive strike on RSI and the desire of going through a formal touch typing training without the vices of many years of crappy qwertying. It’s been easily one of the most mentally exhausting experiences in my life, and the shock of the first couple of days is something worth noting: when you type at less than 10 words per minute using your computer becomes a very alienating activity, and the tools that were previously your second home become total strangers (ahem, emacs).

Of course I still write like crap (maybe around 25-30 wpm if you trust gtypist), but I can already see how this layout was actually designed to ease writing (in english). The downside is that some well known keyboard interactions are qwerty-centric, like Ctrl-C, Ctrl-V and Ctrl-X, and some emacs key chords feel more forced than the usual. Another problem is that my hacking productivity went to hell temporarily, but I still have hopes of doing something interesting during GUADEC with the Epiphany and maemo guys among others (btw, already in Birmingham: horrible flight, and they lost the luggage of almost all the nokians, me included. Impressive).

Posted in General | 7 Comments

Siberian reinforcements

After a very productive GTK+ Meeting yesterday I’ve voluntereed to resurrect the Weekly Bug Reports (like this) with the aim of improving the rotting patch scenario of gtk+’s bugzilla. So, if you have GTK+ patches waiting for review in bugzilla, you are not in my preliminary list (don’t panic, I’m planning to use bugzilla for this) and would like to see this changing, send me an email to xan TA gnome TOD org.

git-send-bugzilla is amazing, check it out if you are not using it yet.

Finally, as seen on Acts of Volition:

Posted in General | 2 Comments

Breaking News

Tommi is now officially one of the few and proud GtkMenu experts (you touch it you own it). Send your condolence letters and GtkMenu questions to:

Tommi Komulainen
Pit of Despair, GtkMenu Section (Bottom)
Helsinki, Finland
Posted in General | 2 Comments

Origami Rose

Finally spent some time adding the search functionality for gtk-look.el, you can check my ugly hack here (the new function is gtk-lookup-search-symbol). Used the O’Reilly book Writing GNU Emacs Extensions as an introduction to the subject, and had lots of fun with it. When Emacs switches to a modern lisp in 2025 I bet it will be a lot more fun 🙂

Ninja master Daniel Piedra^WStone instructed me about the evils of falling back to fbCompositeGeneral in the X fb code. Indeed the sucker appears quite a lot in my powerpc oprofile logs. One uninformed wild guess is that the lack of something like fbaltivec.c is not helping here. No good drivers + exotic architecture really buys you all the tickets for the most slow rendering path.

Last but not least, the Epiphany SoC application by Imran Patel to merge History and Bookmarks under a new backend was accepted! If it succeeds it should improve the Epihany user experience and allow other parts of the desktop to easily access that data.

PS: the nice origami rose was done by my girlfriend Sandra. I tried to do some stuff with her but the results won’t be shown to protect the innocent bystander.

Posted in General | 5 Comments

What? A coke is a coke

Sent a proposal to improve the situation for GTK+ wannabe-maintainers. Didn’t get much feedback, but we’ll probably meet again this thursday from 18:00 UTC+2 at -love/irc.gimp.org. Would be specially interested in getting volunteers to get the “GTK+ hackers guide” started 🙂 (A brief summary of my proposal is: 1) Gather a GTK+ love bug list with easy bugs for beginners. Something like this but hopefully using bugzilla and with the maintainers support. 2) Create a short guide with the most basic concepts a GTK+ hacker should understand thoroughly explained. Hopefully it’d be mostly a matter of collecting, updating and expanding the already available and scattered docs).

Ranted with fellow Nokian and emacs user Dirk Jan (there’s no need to panic, it’s only dutch) about how nice would it be to get the devhelp functionality from within emacs. Well, this morning he sent me this, which I’m already loving. It’s only missing search to be completely perfect 🙂 (Tempted to get my hands dirty with elisp and just do it).

PS: the title is the canonical answer a waiter from Brussels will give you if you ask for a “big coke”.

Posted in General | 2 Comments