3 August 2009

libchamplain 0.3.6 released, now using Clutter 1.0

libchamplain’s development was not blocked by the never ending delays in Clutter 1.0′s release. But we were waiting for 1.0 with eager.  And now the results are in.  Clutter 1.0 introduces many changes that simplified libchamplain’s code and solved some of our long standing issues at the same time.

Taking opportunity of the new introduced animations in Clutter, I added new marker animations in libchamplain:

If you are viewing through a planet, or a non HTML5 capable browser, here’s the file.

Since porting to Clutter 1.0 was the only condition set by the Gnome release team for libchamplain’s inclusion in Gnome 2.28, we can consider it a done deal!

See the complete announcement.

In other news, libchamplain 0.3.5 was also released last Saturday. It is the last release to use Clutter 0.8, but it also has very good Perl and Python bindings. Since Clutter 1.0′s bindings are not ready yet, libchamplain 0.3.5 is the last release to have bindings until Clutter gets some!

8 June 2009

Introducing geoclue-properties

While deploying Geoclue with friends, I came to the conclusion that we need a GUI tool for end users to setup Geoclue.  Geoclue-properties was born.  gstreamer-properties was an inspiration (for the name, and part of the visual aspect).

I started the project only last Monday night, but you can already do this with it:

  • See your current address and postion according to Geoclue
  • List installed providers and their provided services
  • Set an address on the Manual provider
  • Set the address for the current network on the Localnet provider
  • List previously configured addresses in the Localnet provider

Just the last items save the user of having to use dbus-send incantations.   For the screenshot lovers, here’s your dose.

The project is still quite embryonic.  It is my first attempt at using Python for such a task and I lack knowledge (and quite frankly time) on how to create the project’s infrastructure (almost as if I am missing autotools — scary!).  If someone is willing to contribute that or point me the doc I’d appreciate!

Try it!

12 May 2009

Python’s hidden poisoned apple for GPL applications

I’d like to make people aware of something my colleague Daf pointed out to me: one cannot use Python‘s SSL code (this also applies to other Python projects such as M2Crypto) in a GPL licensed application because it uses OpenSSL.

The problem resides in OpenSSL’s license which requires :

3. All advertising materials mentioning features or use of this software
must display the following acknowledgement:
“This product includes cryptographic software written by
Eric Young (eay@cryptsoft.com)”
The word ‘cryptographic’ can be left out if the routines from the library
being used are not cryptographic related :-) .

and (because of its dual license)

3. All advertising materials mentioning features or use of this
software must display the following acknowledgment:
“This product includes software developed by the OpenSSL Project
for use in the OpenSSL Toolkit. (http://www.openssl.org/)”

This requirement as been marked as GPL incompatible.  Therefore, any GPL application using it is in license violation. While the OpenSSL FAQ stipulates that you can use it with GPL applications, this opinion is not shared by everyone. This is a quite big unadvertised licensing problem.

Now, I am not a lawyer but I can point to some existing solutions to this problem:

  1. Fix Python to not use such a poisonous (to GPL) licensed library.
  2. Do not use Python’s SSL code and use other implementations such as python-gnutls.  This solution less appealing as replacement libraries often don’t completely cover python’s API.
  3. Relicense your GPL application to “GNU GPL  with the OpenSSL special
    exemption.” (as wget did) and add mentions to OpenSSL in your advertising materials. This solution is sometimes hard to implement as you have to contact all past contributors.
4 May 2009

libchamplain 0.3 released!

I am proud to announce the release of libchamplain 0.3, the first development release toward 0.4.  libchamplain is a map widget.  It is the work of many months (as far as November) and many contributors since FOSDEM.  Here is a short list of what you get:

  • Support for proxies
  • Support for custom map sources
  • A way to list the available map sources
  • Support for 2 new built-in map sources: Cycle Map and Osmarender
  • A bunch of new function to allow more control on the UI
  • A nicer, more flexible Marker API
  • Nicer default markers: they are now grey, have rounded corners and cast a shadow!
  • Notification when the view is loading content and when it’s done
  • Support for locking down available zoom levels
  • A more intelligent cache that can be purged
  • Bindings (in the works): Perl, Python, C# and C++

Of course being a development release, the API isn’t entirely stable yet.  For instance, the code surrounding the ChamplainMapSourceDesc introduced this weekend is subject to be reviewed in the next weeks.

Yet, this release is a big step forward introducing a lot of the desired features while leaving some for an upcoming release (such as the ability to draw lines on the map).

You can grab the tarball or clone the source code.  You can read the NEWS or read about the API.

On a side note, libchamplain as been officially proposed as an external dependency for GNOME 2.28.

26 April 2009

Writing a nice API: comments needed

In the race to the 0.3 development release, we are reviewing the API to see it is nice to use, bindable and most of all intuitive to g* coders.  But sometimes, it is hard to find out how to do it well: comments on this particular issue would be appreciated.

ChamplainView is the map view that displays the map.  It needs a ChamplainMapSource from which it gets the map.  There are specialised objects that inherit from ChamplainMapSource such as ChamplainNetworkMapSource and the upcoming ChamplainLocalMapSource (or what ever it will be named by the end of the SoC).

champlainNetworkMapSource* champlain_network_map_source_new_full (const gchar *name,
    const gchar *license,
    const gchar *license_uri,
    guint min_zoom,
    guint map_zoom,
    guint tile_size,
    ChamplainMapProjection projection,
    const gchar *uri_format);

As you don’t want to fill all this information each time you create a new map source, libchamplain currently provides helper constructions:

ChamplainMapSource * champlain_map_source_new_osm_mapnik (void);
ChamplainMapSource * champlain_map_source_new_osm_cyclemap (void);
ChamplainMapSource * champlain_map_source_new_osm_osmarender (void);
ChamplainMapSource * champlain_map_source_new_oam (void);
ChamplainMapSource * champlain_map_source_new_mff_relief (void);

We think it could be interesting to replace these by a Factory to which you pass an enum value to get the constructed ChamplainMapSource.  You would probably be able to add your own map source constructor (as you can implement your own map sources).  You would probably be able to get the list of available map source too.

The question is: is this overkill? the best way to do it? is there something similar in glib or gtk to get inspired from? We base most of the API decisions by looking at other Gtk+ widgets, but this particular object seems to be a different case.

We are asking for your ideas.

20 April 2009

libchamplain has got a SoC project

There will be a Google Summer of Code project for libchamplain – your Clutter based Map Widget for your Clutter or Gtk+ based applications. This project will be realized by Simon Wenner.  He will be working on getting the map rendered locally (using OpenStreetMap xml data) as opposed to downloading the pre-rendered tiles as libchamplain currently does.  At the end of the summer, libchamplain will support both for best flexibility.

This functionality means a lot of possibilities for libchamplain: better accessibility, smaller bandwidth needs, smaller cache footprint, more context data and finally themable maps.  These can be very useful if you are running on different platforms such as Maemo 5 or a desktop: bigger fonts, more contrast, tango colors!

(oh and by the way, this is the new default markers: more on them in a later post)

Unfortunately, another very interestant SoC idea didn’t make it to selected list: a glib based OSM data API.  That would have made it very useful to access the downloaded data.  But hey, that will be for later!  Thanks to all the students that submitted a project idea on libchamplain :-)

22 March 2009

Some libchamplain love

libchamplain is a map widget for your application.

I’ve just tagged some bugs or enhancements with the gnome-love keyword.  If you ever wanted to contribute to libchamplain, I think these bugs should be rather simple to fix/implement.

In other news, I selected a list of bugs and features that needs to be fixed before a 0.4 release is made.   Such a release will happen before Gnome 2.28 as I plan to ask to be an external dependency (as Empathy, Eog-plugin and f-spot will have use for it).  The list of bugs is listed in on the mailling list.

Libchamplain is part of Gnome’s Google Summer of Code.  There are already some libchamplain ideas. These ideas are planned for 0.6 release, but the work need to start this summer! Students: apply!

Yes, you did read f-spot! Anders Mørk-Pedersen started a f-spot plug-in to display the geolocation information of your photos!  It even works with multiple selected photos.  Now the poor Anders is so busy with school that it is stuck in a demo state. Anyone interested to help should ping us about it!  libchamplain in f-spot was made possible by Stephane Delcroix‘s hard work both to libchamplain’s bindings and clutter’s.

Along the python and managed bindings, perl bindings have been announced.  Emmanuel Rodriguez is writing them with support from the perl community. He’s also contributing unit tests in perl.  These have already proven to be quite useful!

Finally, I decided to give it a try and create a website and logo for libchamplain.  I quickly made the site by borrowing Cheese‘s website hehe. The logo represents a jigsaw puzzle piece of a world map as libchamplain is a module to add to existing applications to add maps. I tried to tango-ify it as much my capabilities allow me, if you have a better touch here’s the svg.  Since I have so much use for The Gimp and Inkscape, I donated to the Libre Graphics Meetup!

That was a short résumé of what happened in libchamplain recently, excluding the 53 files changed, 3591 insertions and 1165 deletions.

9 March 2009

Familiar Faces

I think Facebook fixed their “People you may know” feature, because recently it was showing people I didn’t really know but this morning I knew the listed names and faces and among these:


(Not an actual screenshot, edited to remove non FOSS people)

Now, it is not as if I could be friend with them – after all I know their name/face because we attended the same conferences or read Planet Gnome.  I don’t want to be that excessive Facebook-friend-adder.  I personally draw the line by asking myself “Would that person know/remember who I am?”, therefore I try to only add people that I’ve talked with in real life.

Facebook chose the word Friend to identify the persons I allow to see my information.  It is a rather strong word because some of the people in my “friend” list are just acquaintances and they mix with my best friends!  Yet, they are people I’d like to keep informed about.

Thanks Facebook for forcing me to think about what defines friendship before breakfast ;-)

25 February 2009

libchamplain progress in Febuary

After this (IMHO) successful presentation at FOSDEM, people spontaneously offered their help.  Many more showed their interest into the ideas or to use it.  Let’s see what is developing from that.

For the new readers, libchamplain is a Clutter based map displaying widget.  It intends to be a light embeddable map widget for all applications with nice eye candy.  For instance, the current API concentrates on how to draw markers and display maps rather than parsing raw GPX data.

Some days before FOSDEM, work started on libchamplain 0.3.  This version will be the development version leading to libchamplain 0.4 (kind of using the same numbering schema than Clutter).  Along with all the promised features (routes, custom map sources and being bindings friendly), this version will have a better code base.  It is already much cleaner than the 0.2 series, and yet a lot of work is left to be done.  I had written a MVC version of the code and I am slowly merging this work (from the MVC branch) back into master.  Also, one of the biggest change is that libchamplain and libchamplain-gtk are now under the same git tree.  Packagers will hate us a little now, but it should provide simpler to maintain in the future.  All bindings will also be under the same tree, in the bindings directory.

There is a new demo portraying an animated marker. See demos/animated-marker.c.

Anders Mørk-Pedersen has been around before FOSDEM working on managed bindings for libchamplain.  With Stéphane Delcroix special touch, they got them running.  They are merged, and I think, ready to be tested.  Now, I am not telling you yet what those bindings are going to be used for…  ;-)

Denk Padje offered his help working on the python bindings.  While we got somethings to generate, neither of us are python specialist.  We could use some help.  The branch is bindings-python.  Once the bindings are running, examples will be written.

Libchamplain could certainly profit from Google’s Summer of Code.  Ideas such as having map drawn locally from raw map data and supporting more map sources and map projections (at least one that doesn’t make Greenland the size of South America) will probably be added to Gnome’s pool of ideas.

Now that we have a mailing list, I think a proper web site should come next.  I would also like the project to have a neat logo.  But nothing too fancy as it is a library after all.  May be someone could come up with something like likes of Geoclue’s logo, but may be as a puzzle piece (clearly indicating that it is a library).  Also, I like the Tango colors ;-)

That’s it for Febuary.

8 February 2009

Bringing geolocation into Gnome

This week-end, I presented a talk at FOSDEM about how “Bringing geolocation into GNOME”.  While giving some background definitions and ideas for geolocation, it mostly covered what are technologies currently available to achieve these goals.

I have the impression that the talk was well received, it certainly boosted my interest into spending long nights infront of the screen pushing libchamplain forward much more!

Bringing geolocation into GNOME

All of the demonstrated code is already available.  For EOG plugin, see the EOG-plugins svn repo, a release should be available in the Gnome 2.28 timeframe.  For the Empathy Geolocation, it is available in my empathy repo, and the telepathy parts already have been released.  This feature should be merged first thing in the 2.27 development cycle, allowing a smooth testing period before 2.28.  As for Emerillion, it was the first public mention of this promizing application.  It shall be announced in a close future.

To make this presentation, I used clutter-toys/opt, a clutter based presentation tools.  The slides are defined in a xml file.  I enhanced it to support embedded maps.  So if you add the following xml code, you’ll have an interactive map of Brussels, with very usefull places marked, right into your slide! Grab the branch into my clutter-toys repo.

<map width="600" height="500" zoom-level="13" latitude="50.84" longitude="4.37">
      <marker latitude="50.842966" longitude="4.35153">Porte Noire</marker>
      <marker latitude="50.845127" longitude="4.349878">Mannequin Pis</marker>
      <marker latitude="50.848548" longitude="4.353633">Délirium Café</marker>
      <marker latitude="50.821391" longitude="4.39393">Université Libre</marker>