Clutter & Cogl Wayland update

Published on December 16, 2011 in Uncategorized. 4 Comments

Lots of us over at Intel towers are working hard to bring you a great new Wayland powered experience.

Cogl and Clutter have now been updated to work with the latest Wayland master. You need to compile master Cogl with:

./configure --enable-wayland-egl-platform=yes --enable-gl

And then to run any applications using Cogl on Wayland you need to setup the environment variable COGL_RENDERER=egl_wayland then you can run cogl-crate!

For Clutter you need to compile Clutter master with:

./configure --enable-wayland-backend

You also need to set an environment variable to choose the Clutter backend too – in this case it’s CLUTTER_BACKEND=wayland (and you need to set COGL_RENDERER too) then you can run test-actors!

Or just look at the video below spacer

Direct Vimeo link!

A big kudos needs to go to Robert Bragg, Neil Roberts and Emmanuele Bassi for helping make this happen.

The Clutter client side support is basically complete so i’ve now moved onto working on GTK and MX – watch this space for updates!

Nicely formatting number types

Published on April 29, 2011 in Uncategorized. 2 Comments

I came across the following compiler warning today:

||   CC     libplurk_la-plurk-item-view.lo
|| plurk-item-view.c: In function ‘construct_image_url’:
plurk-item-view.c|233| warning: format ‘%lld’ expects type ‘long long int’,
but argument 3 has type ‘gint64’

Tut tut tut .. a compiler warning! How could the commiter had let this happen? Lets look at the code …

url = g_strdup_printf ("avatars.plurk.com/%s-medium%lld.gif", ...);

Ahaha .. they’re probably using a 32-bit system, the nice thing to do here is:

url = g_strdup_printf ("avatars.plurk.com/%s-medium%" G_GINT64_FORMAT ".gif", ...);

To handle the case that on a 64-bit system you can represent a gint64 as a long rather than needing to go for a long long. I’ve seen this quite a bit with debugging output for size_t for which G_GSIZE_FORMAT is definitely your friend.

London GNOME Beer 3.0

Published on April 4, 2011 in Uncategorized. 0 Comments

In/near London on April the 8th? Like beer? Like pizza? Love GNOME? Then you probably want this wiki page.

Autofoo: AC_ARG_ENABLE

Published on February 7, 2011 in Uncategorized. 4 Comments

Spent some of my morning fixing a build issue that came down to the use of AC_ARG_ENABLE. I thought it was worth recording some notes for its use:

Something enabled by default:

AC_ARG_ENABLE([badgers],
              [AC_HELP_STRING([--enable-badgers=@<:@yes/no@:>@],
                              [Enable badgers @<:@default=yes@:>@])],
              [],
              [enable_badgers=yes])

Something disabled by default:

AC_ARG_ENABLE([badgers],
              [AC_HELP_STRING([--enable-badgers=@<:@yes/no@:>@],
                              [Enable badgers @<:@default=no@:>@])],
              [],
              [enable_badgers=no])

Observe that in this case the only thing that changes is the default value in the third parameter to AC_ARG_ENABLE (and also the documentation spacer )

Something enabled by default but with a –disable syntax:

AC_ARG_ENABLE([badgers],
              [AC_HELP_STRING([--disable-badgers],
                              [Disable badgers],
              [],
              [enable_badgers=yes])

Notice that this case is just the same as the first except with the help changed. Of course you actually need to use the value from the flag. I think this is more readable if presented outside the AC_ARG_ENABLE parameters this is possible because AC_ARG_ENABLE always sets a variable called enable_<thing>. Awesome, huh?

For conditional pkg-config:

AS_IF([test "x$enable_badgers" = "xyes"],
      [PKG_CHECK_MODULES(BADGERS, [badgers-1.0])],
      [])

For conditional building:

AM_CONDITIONAL(ENABLE_BADGERS, test "x$badgers" = xyes)

Work with us!

Published on January 27, 2011 in Uncategorized. 5 Comments

Are you graduating this year? Or recently graduated? Do you want to work in Open Source? Do you have the right to work in the UK? Do you want to work with some of the best minds in the field: Chris Lord, of Happy Wombats fame; Damien Lespiau, the Clutter GST mastermind; Emmanuele Bassi, our Clutter super-hero; Jussi Kukkonen, who puts the clue in Geoclue; Ross Burton, our EDS magician; Srini Ragavan, Evolution shiny-thing maker; Thomas Wood, of the MX and control-center massive; Tomas Frydrych, our Antarctic naming scheme generator and of course pippin.

Interested? Take a look at our job entry. I should be around as FOSDEM so feel free to corner me to talk.

GUADEC 2010

Published on July 30, 2010 in Uncategorized. 0 Comments

GUADEC is going really well this year, great to catch up with folks. A big thank you to everyone who came along to my tips and tricks talk yesterday. I hope that everyone discovered something new; I certainly did whilst preparing it. As suggested i’ll try and get this content all collated up into a wiki page. Watch this space.


spacer
Awesome photo CC gonzalemario – bit.ly/9Z0iIf

GNOME in Moblin: People panel

Published on November 4, 2009 in Uncategorized. 4 Comments

Previously i’d talked about how we use GNOME technologies in the Moblin Myzone. Now i’m going to talk about another component that i’m responsible for, the People Panel.

An important aspect of the Moblin user experience is about communicating with others and this panel provides quick access to do this. The core of the content is provided by an abstraction, simplification and aggregation library called Anerley. This provides a “feed” of “items” (an addressbook of people) that aggregates across the system addressbook, powered by EDS, and your IM roster, powered by Telepathy. You have small set of actions you can do on these people such as start an IM conversation / email / edit them with Contacts. The core of our IM experience is supplied by the awesome Empathy. We’ve been working with the upstream maintainers to accomodate some of the needs of Moblin into the upstream source. This included the improvements to the accounts dialog and wizard that landed for GNOME 2.28.

spacer

One of the biggest problems with the IM experience in Moblin 2.0 was that it was easy to miss when somebody was talking to you. If you were looking away when the notification popped up, whoops, it’s gone. With our switch to Mission Control 5 I was able to integrate a Telepathy Observer into Anerley and the People Panel. An Observer will be informed of channels that are requested on the system. This allows us to show ongoing conversations in the panel and by exploiting channel requests and window presentation allow the user to switch between ongoing conversations. This wouldn’t have been possible without the assistance of the nice folks in #telepathy and at Collabora: Sjoerd, Will, Jonny and countless others.

GNOME in Moblin: Myzone

Published on October 23, 2009 in Uncategorized. 1 Comment

Howdy, i’m sure most people are aware of the recent release of Moblin 2.0; a user experience for netbooks. I’m going to write a few blog posts about how the Moblin user experience is built on the awesome technologies in the GNOME platform.

So first up, let’s look at the Myzone, we’re starting here since this is the first thing I really worked on in the Moblin UX and i’ve been able to see it through from early ideas to the 2.0 and 2.1 releases.

So, deep breath, the idea behind the Myzone is to provide a springboard to things that matter to you most: your recent files and web pages you’ve visited, your upcoming events and things you need to do, things that are happening on social web services and your favourite applications.

Now then, that’s the theory, how does it work:

  • Recent files: Recent file information is pulled from the GtkRecentManager and the thumbnails are pulled from the XDG thumbnail specification directory. Metadata for the file comes courtesy of gio which I presume comes from shared-mime-info. Yay. By using the GtkRecentManager for all our recent activity metadata across the platform we’re allowing legacy GNOME applications to just work. Sweet.
  • Events and tasks: These are pulled from EDS using libjana, a calendaring library primarily developed by Chris Lord (of Dates fame.) A couple of months back (well, uh, March) I enhanced libjana to support tasks and thus we are able reuse the existing Tasks/Dates apps for interacting with the calendar.
  • Favourite apps: Here I let the side down. I use some quite crazy custom format for doing this which frankly stinks. I’m going to try and sit down with the GNOME shell guys to see if we can come up with some better way for dealing with user originated application metadata.
  • Social networking/web service integration: This comes courtesy of Mojito and librest, two projects that I and the esteemed Ross Burton have been working on. Mojito is a project that pulls in content from a variety web services into a centralised place, abstracting some of the complexity and the makes it trivial to query. librest is a library for to keep developers happy even though they’re having to deal with web services. It does this by making requests and parsing the result simple.


spacer
Myzone in action

Moblin talks this week at GCDS

Published on July 4, 2009 in Uncategorized. 0 Comments

I hope everyone is enjoying the ice cream! So this week there are going to be some talks by me and my colleagues at the summit.

11:30 on Sunday, Joshua Lock will be talking about ConnMan and the lesson’s that he’s learnt from building the Moblin UI for it. This talk will take place in Room 3, “Palacio de la música”. ConnMan: New Connection Manager

5pm on Sunday, I will be talking about Mojito and librest; social web service integration for the GNOME/Moblin stack. This talk will take place in the “Gran Canaria” room. Sipping Mojitos and thinking RESTful thoughts

5:45pm on Sunday, our glorious Emmanuele Bassi will be giving five short lightening talks on various aspects of the Clutter library. This talk will be in the “Cámara” room. State of Clutter

10am on Monday, Patrick Ohly, author of SyncEvolution will be talking about synchonisation in the “Gran Canaria” room. Synchronization: From the SyncML Protocol to Free and Open Implementations

11am on Tueday, Chris Lord, animations guru, will be showing off his Clutter animations skills in the “Cámara” room. Building complex UI animations in Clutter 1.0

And last but not least, at 12pm on Wednesday, our very emminet use experience designer Nick Richards will be taking to the state to talk about the Moblin Netbook UI. Designing Moblin-Netbook. A free desktop on a 7-10″ Screen

A little bit more RESTful

Published on June 13, 2009 in Uncategorized. 3 Comments

So my last blog post about my work on web services integration: GNOME web services integration: Introducing librest was quite some time ago. Apologies, things have been pretty busy with Moblin.

There are two traditional models for parsing XML, SAX and DOM based methods. These are both pretty heavyweight technologies but for the work i’m doing on web services I want something a bit lighter and a bit simpler to extract just the information I care about. Inspired by the Beautiful Soup HTML screen-scraping library I sought to build an API that lets you trivially find the content you are looking for.

Here is an example:

n = rest_xml_node_find (root, “photo”);
while (n)
{
  title = rest_xml_node_find (n, “title”);
  printf (“%s”, title->content);
  n = n->next;
}

Fundamentally the libREST XML parsing strategy turns the XML into a tree of nodes, where a node can have siblings (accessed through a next pointer) or childen (stored in a hash of child tag name to node). This combined with a simple tree walking function (rest_xml_node_find) results in very minimalistic code for extracting just the content you care about.

You can find the source code for libREST in git.




gipoco.com is neither affiliated with the authors of this page nor responsible for its contents. This is a safe-cache copy of the original web site.