Go forward in time to June 2004.
About Jeff's post about 28 cool things to do in GNOME:
1. Preview widget for gnome-terminal's background file chooser. Do make sure you use gdk_pixbuf_new_from_file_at_size() rather than loading the image and then scaling it for the preview; the former is going to be faster and use less memory.
3. Delete anything by dragging to the trash. This is about making the Nautilus trash can support a magic drag target like application/x-delete-me. Applications which use this drag target would receive the drag-data-delete signal when they should delete the item that was dragged into the trash.
14. .hidden file support for GtkFileChooser. You probably want to read the .hidden file when a folder is loaded and install a file monitor for it. Then, when a file's information is read, you should see if that file is in the .hidden data and call gtk_file_info_set_is_hidden() as appropriate. By the way, this is bug #129170.
21. GtkEntryCompletion for Nautilus's location dialog. Maybe it should just use GtkFileChooserEntry, but that's a private API right now. The problem with exposing it is that it uses things like GtkFileSystem and GtkFilePath, which are also private APIs. Still, this could be solved in a similar way to how GtkFileChooser exports both file names and URIs rather than opaque GtkPathNames.
My patch to make Vino use Xdamage wasn't getting any events at all. It turns out that I forgot to call gdk_x11_register_standard_event_type(), so my event filter would never get any events from the Xdamage extension.
It works now, and the updated patch is here. I think just the autoconf-fu needs to be prettified, as it is a total hack right now.
I'm trying to compile a checklist of things that applications need to do to make them integrate well with the rest of the desktop. The idea is to have an introductory document that will help people plan ahead when writing applications, or to help them in extending existing programs so that they will play well with the rest of GNOME. So far I have these items:
Did I miss something? A bunch of this stuff is badly documented and people must often resort to checking the source code of core desktop apps to figure out how to make things work.
I finally got off my ass today, took the CPU fan off my fast machine, and looked in amazement at the complete mess that was the heat sink under the fan. It was completely encrusted with dirt and dust, which prevented air from flowing through the slits. No wonder my poor machine was overheating all the time: a few seconds after booting the CPU would climb to 70°C and hang; now it sits still at about 38°C.
Søren posted a really good list of interaction problems in GTK+. Maybe some of these would be nice projects for novice hackers in the gnome-love project. Also related to this:
Jim Cape posted code with a replacement for GnomeFileEntry and a button to select images. The idea is to polish the API and include these widgets into GTK+.
Owen has a sexy document about rendering text at different resolutions. Always a man of impeccable taste, he selected a passage from Ben Franklin's autobiography as example copy. Of course a citation from Fart Proudly would have been equally appropriate.
Mauricio and Ángeles invited Juan José, Edna, Toño, and ourselves to their house for a barbecue.
Other than that, today consisted of sleeping and fighting the Emacs debugger.
RML pointed out a very interesting thread going on about performance-tuning for the desktop. Tasty bits include Søren on sysprof/speedprof/memprof, Alex on Nautilus, and the conclusion of it all.
My friend Alan linked to an article about Chilango expatriates, that is, people who used to live in Mexico City but moved elsewhere. The main reasons why Oralia and I moved to Xalapa are the following.
First is crime. In absolute terms it is perhaps not the most important reason (one does not get mugged every day), but it is extremely uncomfortable to live in fear. After my mom's kidnapping there was a steady stream of unpleasant news from other family members or close friends. Nothing had happened to us yet, but it seemed inevitable. A long time ago Miguel told me, "crime is moving closer to one": in the past one would hear stories of a friend of a cousin of a coworker being mugged, and one would be terrified; things gradually got closer to immediate acquaintances, such as one's mom or a close friend. In Xalapa one can stroll downtown at midnight quite at ease; in Mexico City you have to be rather crazy to do that, or you have to be a corpulent ninja like Joakim.
Second is price. Housing in Mexico City is getting very expensive, by Mexican standards. Living in the interesting valley neighborhoods (Coyoacán, Del Valle, Narvarte, Condesa, Roma) is expensive unless you want a super-tiny rental apartment. We used to pay 7000 pesos a month for a small (60 m2) apartment in Coyoacán, and that was in an older/shabbier part of the otherwise awesome area. That was a large chunk of my salary. Then we used to pay 5000 pesos a month for a slightly bigger apartment in Del Valle, which was great because it was literally around the corner from the office. However, the building was old and it got very little sunlight. Buying a house or an apartment was out of the question: apartments in the same neighborhood as the office ran for one or two million pesos, and they were invariably small and badly designed. The other option would be to move to one of the suburbs. They are all really far away from the interesting parts of the city, or even the office. Public transportation is painful: once you step out of the Metro, you have to use the ridiculously bad peseros, or mini-buses. Mexico City is so large that Metro stations are spaced very far apart from each other, so walking is not always an option. Also, suburbs more often than not have only a single access way which is perennially congested, and there is no Metro going into them. The southern suburbs which are built on hills are especially problematic because of that. The northern suburbs are too far away to be practical. In Xalapa we pay 3000 pesos a month for a house, and while we have not saved enough money quite yet to buy a house, nice places actually fall within our price range.
We used to think that traffic in Mexico City was a problem, but after seeing Xalapa that is no longer the case. Everyone in Xalapa follows a very simple driving algorithm:
The corollary of (1) is that very often you get an arrangement like this:
B B C AD
B is a bus stopped on the right lane. C and D are moving cars. A is an asshole who sees the free space in front of D. He fails to notice the bus B, so he cuts in front of D. Finding an obstacle, he starts honking. D then starts honking as well, because A cut him off. This happens all the fucking time. The other corollary of (1) is that people race for all the free spaces ahead of them, grid-locking themselves out at street crossings very quickly, and in very amusing ways. By virtue of (2) they also honk until they manage to inch themselves out of grid-lock.
Oh, and they never yield to pedestrians.
These days when we go to Mexico City it is like driving in heaven. People seldom honk their horns. They yield for pedestrians and for merging traffic. It's amazing. Their driving algorithm is to carefully avoid hitting surrounding cars; they know that there are so many vehicles that it is futile to try to cut them all off, or to try to be aggressive. The result, just like self-regulating dynamic systems, is beautiful.
However, at least for us traffic in Xalapa is not a huge problem as we can walk mostly everywhere: downtown, to restaurants, to bookstores, to school. The car sits in our garage unused for days. In the end we pay less for rent and fuel than we would if we were still living in Mexico City.
The only thing I miss so far is the large record and book stores. Restaurants, even for non-Mexican food, are plentiful here. Even books and CDs are not a big problem, as we stock up on them every time we go to Mexico City.
John Brownlow has been tracking news items of the atrocities in Iraq in his Unintended Consequences weblog.
Today I wrote a patch to add Xdamage support to Vino. I haven't compiled it yet because my gnu-tls setup is fubared, but I'm pretty excited about Xdamage and what it could do for screenshot hacks, pagers, and the like.
Back from Tapachula, where I gave two talks at the Primer Ciclo de Conferencias de Software Libre. I had a nice conversation with one of the teachers from the university, who had some horror stories to tell. Some professors have started to use free software as a means of teaching their students — the Linux kernel for the operating systems class, GNOME for user interfaces. In contrast, other old-school professors have fallen into disenchantment, even going as far as telling the students not to worry about computer science, as there is better money to be made in carrying around and laying network cables. It turns out that the university wants to fire the "new style" professors, for actually teaching useful things.
Before going to Tapachula we went to the movies to watch Dirty Pretty Things. Holy shit, what an excellent movie.
Nested containers.
¡Vamos, vamos, vamos, al Circo Atayde Hermanos!
Last night we finally went to watch Kill Bill. I'm itching for the second part to show up here.
Historically, elections in Mexico have been either a blatant fraud, or highly dubious. It is only the last presidential election that was reasonably trustworthy, modulo campaign overspending, funny funding sources, and all that. Mexico uses paper ballots and hand counting. This article on Indian voting machines and their procedures is quite interesting.
Today I fixed a bunch of stuff in BonoboDockItem, but it is still not done. It had some important problems, like listing its subwidgets from its GtkContainer::forall implementation when the dock item is floating: in that case, the subwidgets are no longer real children of the dock item, but rather of the floating GtkWindow it creates. All sorts of trouble ensued. Also, it did funny things with reparenting, which I've fixed.
The moral of the story is that you should not try to be smarter than GTK+ when it comes to the widget/container hierarchy. It will not work.
It looks like we will not be continuing our French course at the Alianza Francesa de Xalapa. The beginner's courses advance way too slowly, and the students are, with few exceptions, air-headed teenagers who got sent by their parents, rather than wanting to learn French for themselves — they have no interest in the class whatsoever. We may look at the Language Center of the University; hopefully it will be better.
It's ridiculously warm in Xalapa right now. I'm all sweaty and my glasses fog up easily.
Irons at the Hacienda del Lencero:
We found a pretty good Japanese restaurant! Somehow it feels weird to find so much good foreign food in Xalapa.
I've been trying to fix the toolbar-rework branch of libbonoboui, namely BonoboDockItem and friends. The code in there uses the new GtkToolbar rather than a custom toolbar widget, but it's not quite done yet. The process of fixing it makes me wonder whether I'm fixing symptoms rather than more basic issues. Fortunately, the job that Arvind did on converting BonoboUI to GtkToolbar is pretty good.
John Palmieri is completely right in his comment about GNOME documentation: we need infrastructure to let people contribute to the documentation easily. Right now it is too much of a pain to get gtk-doc going, and editing documentation is a pain.
Josh Green released refdbg, a debugger for GObject reference counts. This could be a nice little tool.
Back in Xalapa, thankfully back to being with my beautiful wife. I was feeling pretty high-strung over the last few days, but now the tension disappeared.
Woooo, Matthias released GTK+ 2.4.1!
I guess the key to understanding the new GtkFileChooser is to realize that bookmarks don't have to be long-lived. Everyone will put their ~/Documents and ~/Downloads in there, but you can also create bookmarks that you remove after a short time. Say you will be opening a bunch of files from the same folder, but then you'll never use that folder again — for example, when you download a manual, read a bunch of documentation files, and then get rid of it. In that case, it is useful to create a bookmark while you are reading the manual, and remove it afterwards. Or say you create a new folder for a subsection of your web page with the intention of adding files to it ("pictures-for-2004-05-03"). You may use that folder for a short while while you edit and save the images, but afterwards you won't have any more use for it. In that case, a short-lived bookmark is also useful.
Go backward in time to April 2004.
Federico Mena-Quintero <federico@gnome.org> Mon 2004/May/03 13:00:33 CDT