<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.3.3" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>Blog of Tim Janik</title>
	<link>http://blogs.gnome.org/timj</link>
	<description>Technical ramblings by Tim Janik</description>
	<pubDate>Wed, 16 Jul 2008 12:15:37 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.3</generator>
	<language>en</language>
			<item>
		<title>16.07.2008 GUADEC 2008 Wrapup</title>
		<link>http://blogs.gnome.org/timj/2008/07/16/16072008-guadec-2008-wrapup/</link>
		<comments>http://blogs.gnome.org/timj/2008/07/16/16072008-guadec-2008-wrapup/#comments</comments>
		<pubDate>Wed, 16 Jul 2008 08:45:10 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[Events]]></category>

		<category><![CDATA[General]]></category>

		<category><![CDATA[Gtk+]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/07/16/16072008-guadec-2008-wrapup/</guid>
		<description><![CDATA[
 Guadec has been in interesting conference, particularly because it took place in Istanbul this year. I tried to keep a few notes throughout the days to wrap up the experience and discussions here.
 
 Sunday
 
 Headed off for Istanbul, partial Imendio meet-up at the airport in Vienna, gathered remaining Imendians at the airport [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break --></p>
<p align="left"> Guadec has been in interesting conference, particularly because it took place in Istanbul this year. I tried to keep a few notes throughout the days to wrap up the experience and discussions here.</p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Sunday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> Headed off for Istanbul, partial Imendio meet-up at the airport in Vienna, gathered remaining Imendians at the airport in Istanbul. Like many others, we stayed at the Golden Long Hotel near the seaside.</p>
<p align="center"><a href="http://testbit.eu/~timj/blogstuff/sundown_bosporus.png"> <img src="http://testbit.eu/~timj/blogstuff/sundown_bosporus.png" class="doxercss-frame" border="1" /> </a></p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Monday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> Kris and I met up with the Gnome release team where we summarized the Gtk+-3.0 ideas that have been cooked up during and after the Berlin Gtk+ Hackfest.</p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Tuesday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> I was planning to attend the Maemo BOF in the morning, but shortly after arriving at the conference venue, <a href="http://www.gnome.org/~federico/news.html">Federico</a> literally dragged me into the DVCS BOF. Still, I only managed to attend the second half of it which was almost exclusively about <a href="http://bazaar-vcs.org/"> Bazaar</a> features. People told me the first hour had been quite the contrary and focused mostly on <a href="http://git.or.cz/"> Git</a> hyping. Clearly, there was no consensus after the meeting on what the future versioning system in Gnome will be.<br />
I&#8217;m not surprised that is the case. As things currently stand, <a href="http://subversion.tigris.org/"> SVN</a> has very active development and user communities, Git is very actively developed, Bazaar is as well, as are a couple other <a href="http://en.wikipedia.org/wiki/Version_control_system"> VCS</a>es. Active developer and user communities are generally a good sign for a healthy project and also an indicator for future relevance. Thus, in any larger community such as the Gnome community, it&#8217;s easy to find lots of critics and lots of supporters for each of the bigger versioning systems and that&#8217;s unlikely to change much. Consequently, there&#8217;ll not be an easy consensus on switching to a single versioning system any time soon, so I think the most productive approach for Gnome to take is to prepare the hosting of multiple VCSes, certainly SVN, Git and Bazaar. Needless to say that cross-VCS integration will also become increasingly important in the future, so focus on maturing and extending git-svn, bzr-svn, bzr-git and the like makes a lot of sense.</p>
<p><!--- paragraph break --></p>
<p align="left"> Later that day, we had a Gtk+ Developers meeting in the medium sized presentation room. The place was a bit too large to have the planned face to face discussions so we&#8217;ve had to sacrifice some of the spontaneity to microphone resource sharing. Kris took minutes during the meeting and will probably post those to gtk-devel-list once he&#8217;s found a minute to process them. The meeting was quite productive nevertheless, we discussed the upcoming Gtk+ 2.14, features and schedule for 2.16 and 3.0 and a bit of the post-3.0 road map.<br />
Right after that discussion, Kris and I attended the advisory board meeting where we briefly wrapped up the developers meeting, the Gtk+ Hackfest in Berlin and the improvements the Gtk+ project has seen since the <a href="http://mail.gnome.org/archives/gtk-devel-list/2006-December/msg00074.html"> State of the Gtk+ Maintenance</a> email. In particular, we stressed that we now have the <a href="http://live.gnome.org/GtkTasks"> GtkTasks</a> and <a href="http://live.gnome.org/GTK+/3.0/Tasks"> Gtk+ 3.0 Tasks</a> wiki pages which can serve as an entry point for contributors and assistants to the project at various experience levels, in particular for companies that want to sponsor developer resources. Also for people that have an interest in long term Gtk+ project involvement, feel free to read up on <a href="http://blogs.gnome.org/timj/2008/05/16/16052008-becoming-a-gtk-maintainer/">how to become a Gtk+ maintainer</a>.</p>
<p><!--- paragraph break --></p>
<p align="left"> Pizza looks weird in Istanbul BTW:</p>
<p align="center"><a href="http://testbit.eu/~timj/blogstuff/pizza_istanbul.png"> <img src="http://testbit.eu/~timj/blogstuff/pizza_istanbul.png" class="doxercss-frame" border="1" /> </a></p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Wednesday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> Almost by accident (I was mostly looking for an air conditioned hall in the afternoon), I happened to be watching &#8220;Gnome Documentation: A year in review&#8221; by <a href="http://donscorgie.livejournal.com/">Don Scorgie</a> where he described the new user documentation tool <a href="http://live.gnome.org/ProjectMallard">Mallard</a>. For some time now, I&#8217;ve been working on a <a href="http://en.wikipedia.org/wiki/Wiki_syntax"> Wiki syntax parser</a> for <a href="http://git.testbit.eu/Doxer/"> Doxer</a> to unify the markup I have to use for my blog, inline documentation and CMS content <a href="http://testbit.eu/filter/tips">markup at testbit.eu</a>. (I have a blog entry in the queue on this for another day.) In this context, implementing a Doxer markup backend that generates Mallard&#8217;s XML input could be an attractive markup alternative for future Gnome documentation - it at least ended up on my ever growing TODO list. ;)</p>
<p> <!--- paragraph break --></p>
<p align="left"> Lots of people approached me throughout this and the following days for a chat about Gtk+-3.0 and what comes after that. With the <a href="http://mail.gnome.org/archives/gtk-devel-list/2008-June/msg00204.html"> merging of the GSEAL branch</a> into upstream trunk recently, there&#8217;s been a lot of focus on the technical preparative work we&#8217;re doing for the actual 3.0 release which is planned as an ABI break to Gtk+-2.16 without adding any new features (it&#8217;s basically just a re-release with all deprecated code removed and current &#8220;private&#8221; API really made private by moving it to non-installed source files).</p>
<p> <!--- paragraph break --></p>
<p align="left"> What has been lacking emphasis in this course is that 3.0 is going to be the necessary <em>enabler</em>, needed to work on implementing future visions of Gtk+ and to refactor the code base back to a healthy state where it becomes maintainable again. Quite expectedly, the need for the sealing and accompanied ABI break has been questioned several times, so I&#8217;ll reiterate the reasoning here:</p>
<ul type="disc">
<li> <em><a href="http://en.wikiquote.org/wiki/The_Matrix">Everybody falls the first time.</a></em><br />
Code development in open source projects is very evolutionary, especially for projects that don&#8217;t clone or reimplement existing specified APIs like Libc. A whole chapter is spent on prototypes in <a href="http://en.wikipedia.org/wiki/The_Mythical_Man-Month">The Mythical Man-Month</a>:<br />
<em>&#8220;Plan to throw one away; you will, anyhow.&#8221;</em><br />
So newly added components and APIs are almost certain to need fixups or revamps in future iterations (likely <a href="http://en.wikipedia.org/wiki/Second-system_effect">more than once</a>). If critical internals are being exposed and eternal ABI stability has been promised, this however becomes impossible. Given the development history of Gtk+ and the variety of interests in this project, it is vital for its future success to prepare for future changes and allow iterative improvements. After all, progressive improvements, appreciation of contributions and adaptions to changing circumstances is where the free software development model shows its strength. The <a href="http://en.wikipedia.org/wiki/Waterfall_model">waterfall design model</a> is not it.</li>
<li> <em>Gtk+-2.x is essentially a dead end.</em><br />
Everybody agrees that Gtk+-2.x is pretty much dead in a few revisions because of the huge work involved in its maintenance and no relief in sight with its current ABI maintenance policy. This is at least true for all current and past core team members (i.e. everyone who actively tried maintaining 2.x over a significant period). The question is whether we move to an entirely new toolkit (Clutter, Rapicorn, Qt, HippoCanvas, etc) or whether that &#8220;new&#8221; toolkit is Gtk+-3.0 which may be largely API compatible with Gtk+-2.x. In either case, applications and libraries will need to migrate to a new toolkit base with a different ABI, the main difference is the involved porting effort.</li>
<li> <em>GLib and Gtk+ do have a means to deal with API changes:</em><br />
1) We provide new alternative interfaces (functions).<br />
2) We deprecate old interfaces (functions) or provide compatibility code in old interfaces.<br />
Notably, this does only work for API that is exported via function symbols. Structure fields that are directly accessed from application code can&#8217;t be deprecated and removed without breaking ABI, and there is no compatibility code upstream could provide for these kind of accesses either. That&#8217;s why we want to move away from exposing any structure internals in 3.0 and beyond.</li>
<li> <em>3.0 will ABI-incompatibly remove all deprecated and private APIs.</em><br />
Of course, the above described deprecation scheme only scales well if deprecated APIs are <em>really removed</em> from the code base at some point. Technically, this is an ABI break which is why GLib/Gtk+ have not been doing this since 2.0. However, lots of other vendors do this to keep a healthy code base, e.g. Qt does break ABI between major releases, Python 3.0 will be incompatible with 2.5, Apple does remove long deprecated APIs in newer releases of Mac OS X, Symbian broke API and ABI in 9.x, Microsoft broke behavior from .NET 1.1 to 2.0, and the list goes on&#8230;<br />
By exposing only function symbols as future public interfaces, we&#8217;ll be able to provide arbitrary compatibility functionality for old interfaces on top of new components, add helpful runtime warnings for iterative migration and constrain future ABI breaks to removal of properly deprecated interfaces.</li>
<li> <em>User visible gains are post-3.0 features:</em><br />
Since GLib and Gtk+ are largely volunteer contribution based projects, it&#8217;s close to impossible to plan exact arrival of future features. However the following is a list of things that have (partially) been discussed as post-3.0 work during the Gtk+ Hackfest already:</p>
<ul type="square">
<li> Full support of alpha transparency for all widgets;</li>
<li> Support for (partial) stacking of widgets (needs transparency);</li>
<li> Offering easier layouting facilities;</li>
<li> Support for animated visible transitions between widget states;</li>
<li> Providing new UI metaphors based on simulation of physical effects like acceleration, 3D browsing of image collections, 3D skimming through notebook pages, and more;</li>
<li> Using IDL based type data generators and code generators to improve the way widgets are implemented;</li>
<li> Implementing a new theming system for the toolkit;</li>
<li> Moving towards exposing widget features only via interfaces that have their own handle (asymmetric query_interface).</li>
</ul>
</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> This is how GSEAL, the Gtk+-3.0 release and a couple <a href="http://live.gnome.org/GTK+/3.0/Tasks">remaining outstanding tasks</a> are going to enable development of exciting future user visible features. The next step for Gtk+ to get work in visionary areas off the ground is to start consideration of feature feasibility and implementations, required resources and tentative schedules.</p>
<p> <!--- paragraph break --></p>
<p align="left"> At the end of the day, we had the Opening Cocktails Party, during which I managed to catch Hallski tattooing J5:</p>
<p align="center"><a href="http://testbit.eu/~timj/blogstuff/gnometagging.png"> <img src="http://testbit.eu/~timj/blogstuff/gnometagging.png" class="doxercss-frame" border="1" /> </a></p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Thursday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> Thursdays most interesting event was of course the keynote by Kris which got hijacked by the Gnome release team for the announcement of Gnome 3.0 which is essentially Gnome 2.30 cleaned up and based on Gtk+-3.x. Kris&#8217; slides are available online:</p>
<pre>	<a href="http://people.imendio.com/kris/gtk-state-of-the-union-2008.pdf">http://people.imendio.com/kris/gtk-state-of-the-union-2008.pdf</a></pre>
<p align="left"> The slides provide a good overview of what Gtk+-2.14 will bring, prospects for 2.16 and visions/requests from the community for Gtk+&#8217;s future. As previously described, Gtk+-3.0 is about enabling refactorings and development of new features, and the plan is to do our best to make the transition away from old deprecated code as easy as possible. Other than properly porting an existing Gtk+-2.x application to work with the G_DISABLE_DEPRECATED, GTK_DISABLE_DEPRECATED, GSEAL_ENABLE switches, no additional changes will be required to build and run an application on Gtk+-3.0.</p>
<p> <!--- paragraph break --></p>
<p align="left"> At the end of the day, there was the boat trip through the Bosporous which provided a beautiful sight along the coast line.</p>
<p> <!--- paragraph break --></p>
<p align="center"><a href="http://testbit.eu/~timj/blogstuff/guadec2008boat.png"> <img src="http://testbit.eu/~timj/blogstuff/guadec2008boat.png" class="doxercss-frame" border="1" /> </a></p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Friday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> I managed to attend the latter half of the lightning talks which was as always quite interesting. I should probably ignore my laziness and actually prepare short lightning talks for next year about Rapicorn and possibly Doxer&#8230; ;)</p>
<p> <!--- paragraph break --></p>
<p align="left"> I took particular interest in Transifex, an online translation platform that can work together with multiple VCSes and that we&#8217;d ideally move all Gnome translations to in the future. There are two things I&#8217;d like to see fixed in a future translation workflow from a developer perspective:</p>
<ul type="square">
<li> The .po templates should really be generated by the developers of the upstream project by automatic means, e.g.:<br />
<code>make update-po -C po/</code><br />
So the upstream version of intltool and po/Makefile.* are used instead of possibly broken or outdated intltool/gettext versions on the translators system.</li>
<li> Developers should be able to determine merge points for translations, and also review related non-po file changes, rather than having translators wildly commit into upstream repositories (which may conflict with other VCS workflows like branch merges or commits around release phases).</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> Later on, Federico presented his ideas for timeline tabs for the desktop. This should make it rather easy to find documents or URLs from previous days or weeks, because out of natural necessity, humans generally have good chronological associations. So the new and nice part about this approach is that it can provide good visual access to the chronologic dimension, something a file system doesn&#8217;t usually reveal easily, and that&#8217;s not easily made accessible by the most prominent desktop metaphors either.</p>
<p> <!--- paragraph break --></p>
<p align="left"> I feel very tempted to start an implementation of the desktop tabs with Rapicorn, however with a few refinements of Federico&#8217;s proposal:</p>
<ul type="square">
<li> The view should provide a &#8220;chronological zoom&#8221; slider to switch the view between years/months/weeks/days/hours.</li>
<li> To be most useful, we&#8217;ll need a crawler that tries to (re-)construct past file modification history without relying on programs pushing journal entries about file edits. This will be needed anyway unless every program on this planet provides file editing journal information.</li>
<li> I think the journaling hooks need to be implemented via DBus and not rely on Nautilus, so they&#8217;re usable by all cross-desktop applications and non-GUI programs.</li>
<li> Various filters by file extensions, magic and possibly more will also be needed in the tab view (this was partly raised during the discussion phase at the end of the presentation).</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> <strong>Saturday</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> About half of the Imendians headed home on Saturday, we had some early leaves on Friday already and left some others in Istanbul for additional vacations.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Oh, and since I&#8217;ve been asked about my nickname here and there, I decided to add tabs to my hackergotchi for clarification:</p>
<p align="center"><a href="http://testbit.eu/~timj/blogstuff/gotchitabs.png"> <img src="http://testbit.eu/~timj/blogstuff/gotchitabs.png" class="doxercss-frame" border="1" /> </a></p>
<p> <!--- paragraph break --></p>
<p align="left"> <strong>Aftermath</strong></p>
<p> <!--- paragraph break --></p>
<p align="left"> There have been quite some discussions on the Gtk+-3.0 plan after Kris&#8217; keynote. One thing that was brought up is that releasing an ABI incompatible but featureless new version of Gtk+ and calling it 3.0 is rather unconventional. An alternative scheme could involve releasing the ABI incompatible cleaned up version as 2.99.0, make 2.99.x the new development branch and release 3.0 with cleaned up ABI and new features (would have been 3.2 in the original plan).</p>
<p> <!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/07/16/16072008-guadec-2008-wrapup/feed/</wfw:commentRss>
		</item>
		<item>
		<title>23.06.2008 Writing Unit Tests with GLib</title>
		<link>http://blogs.gnome.org/timj/2008/06/24/23062008-writing-unit-tests-with-glib/</link>
		<comments>http://blogs.gnome.org/timj/2008/06/24/23062008-writing-unit-tests-with-glib/#comments</comments>
		<pubDate>Tue, 24 Jun 2008 15:14:04 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[GLib]]></category>

		<category><![CDATA[Gtk+]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/06/24/23062008-writing-unit-tests-with-glib/</guid>
		<description><![CDATA[
 Every other week, someone asks how to use the new unit testing framework in GLib (released with GLib-2.16.0) and Gtk+ (to be released with the next stable). First, here is a write-up from last December that summarizes all important aspects:  Test Framework Mini Tutorial.
 
 For people building packages that use the new [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break --></p>
<p align="left"> Every other week, someone asks how to use the new <a href="http://library.gnome.org/devel/glib/stable/glib-Testing.html">unit testing framework in GLib</a> (released with <a href="http://mail.gnome.org/archives/gtk-devel-list/2008-March/msg00022.html">GLib-2.16.0</a>) and <a href="http://www.gtk.org">Gtk+</a> (to be released with the next stable). First, here is a write-up from last December that summarizes all important aspects: <a href="http://mail.gnome.org/archives/gtk-devel-list/2007-December/msg00181.html"> Test Framework Mini Tutorial</a>.</p>
<p> <!--- paragraph break --></p>
<p align="left"> For people building packages that use the new framework, the following new Makefile rules will be of interest:</p>
<ul type="square">
<li> <strong><code>make test</code></strong><br />
Run all tests recursively from $(TEST_PROGS), abort on first error.</li>
<li> <strong><code>make test-report</code></strong><br />
Run all tests recursively, continue on errors and generate <code>test-report.xml</code>.</li>
<li> <strong><code>make perf-report</code></strong><br />
Run all tests recursively, enable performance tests (this usually takes significantly longer), continue on errors, generate <code>perf-report.xml</code>.</li>
<li> <strong><code>make full-report</code></strong><br />
Run all tests recursively, enable performance tests, enable slow (thorough) tests, continue on errors, generate <code><a href="http://people.imendio.com/timj/examples/gtk+-full-report.html"> full-report.xml</a></code>.</li>
<li> <strong><code>make check</code></strong><br />
Run make test in addition to automake checks.</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> After GUADEC, we will be looking into getting build machines setup that&#8217;ll regularly build GLib, Gtk+ and friends, run the unit testing suites and provide reports online.</p>
<p> <!--- paragraph break --></p>
<p align="left"> For those pondering to write unit tests, but too lazy to look at the tutorial:</p>
<ul type="square">
<li> Implementing a test program is very easy, the only things needed are:
<pre>  // initialize test program
  gtk_test_init (&amp;argc, &amp;argv);
  // hook up your test functions
  g_test_add_func ("/Simple Test Case", simple_test_case);
  // run tests from the suite
  return g_test_run();</pre>
</li>
<li> In most cases, a test function can be as simple as:
<pre>  static void
  simple_test_case (void)
  {
    // a suitable test
    g_assert (g_bit_storage (1) == 1);
    // a test with verbose error message
    g_assert_cmpint (g_bit_storage (1), ==, 1);
  }</pre>
<p>Tests that abort, e.g. via <a href="http://library.gnome.org/devel/glib/unstable/glib-Testing.html#g-assert">g_assert()</a> or <a href="http://library.gnome.org/devel/glib/unstable/glib-Message-Logging.html#g-error">g_error()</a>, are registered as failing tests with the framework. Also, the <a href="http://library.gnome.org/devel/glib/unstable/gtester.html">gtester</a> utility used to implement the above Makefile rules will restart a test binary after a test function failed and continue to run remaining tests if <a href="http://library.gnome.org/devel/glib/stable/glib-Testing.html#g-test-add-func">g_test_add_func()</a> has been used multiple times.</li>
<li> Checks in tests can be written with if() and g_error() or exit(1), or simply by using variants of g_assert(). For unit tests in particular, an extended set of assertions has been added, the benefit of using these are the printouts of the involved values when an assertion doesn&#8217;t hold:
<pre>  g_assert_cmpstr   (stringa, cmpop, stringb);
  g_assert_cmpint   (int64a,  cmpop, int64b);
  g_assert_cmpuint  (uint64a, cmpop, uint64b);
  g_assert_cmphex   (uint64a, cmpop, uint64b);
  g_assert_cmpfloat (doublea, cmpop, doubleb);</pre>
<p>For instance:<br />
<strong><code>char *string = "foo"; g_assert_cmpstr (string, ==, "bar");</code></strong><br />
yields:<br />
<strong><code>ERROR: assertion failed (string == "bar"): ("foo" == "bar")</code></strong></li>
<li> The framework makes it easy to test program output in unit tests:
<pre>  static void
  test_program_output (void)
  {
    if (g_test_trap_fork (0, G_TEST_TRAP_SILENCE_STDOUT |
                             G_TEST_TRAP_SILENCE_STDERR))
      {
        g_print ("some stdout text: somagic17\n");
        g_printerr ("some stderr text: semagic43\n");
        exit (0);
      }
    g_test_trap_assert_passed();
    g_test_trap_assert_stdout ("*somagic17*");
    g_test_trap_assert_stderr ("*semagic43*");
  }</pre>
</li>
<li> And it is similarly easy to test and verify intentional program abortion:
<pre>  static void
  test_fork_fail (void)
  {
    if (g_test_trap_fork (0, G_TEST_TRAP_SILENCE_STDERR))
      {
        g_assert_not_reached();
      }
    g_test_trap_assert_failed();
    g_test_trap_assert_stderr ("*ERROR*test_fork_fail*not*reached*");
  }</pre>
</li>
<li> The above and more tests are showcased in GLib: <a href="http://svn.gnome.org/viewvc/glib/trunk/glib/tests/testing.c?revision=6955&amp;view=markup">glib/tests/testing.c</a>.</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> There&#8217;s of course lots of room left to improve GLib and Gtk+ unit tests, and also to improve the current framework. For a speculative, non-comprehensive list, here are some ideas from the unit testing section of my personal TODO:</p>
<p> <!--- paragraph break --></p>
<ul type="square">
<li> Introduce 2D marker recognition for graphical unit testing of Gtk+ layouts (prototyped in <a href="http://rapicorn.org">Rapicorn</a>).</li>
<li> Provide functionality to determine image similarities to allow for pixel image based unit tests (port this from Rapicorn).</li>
<li> Implement state dumps to automate result specification and verification in unit tests. (This will allow us to avoid adding lots of abusable testing hooks to our API.)</li>
<li> Integrate performance statistics (like <a href="http://bugzilla.gnome.org/show_bug.cgi?id=354457">#354457</a>) and other related information into test reports.</li>
<li> Publically install a variant of the <a href="http://svn.gnome.org/viewvc/gtk%2B/trunk/Makefile.decl?view=markup">Makefile.decl</a> file used in Gtk+ to implement the test framework rules and <a href="http://en.wikipedia.org/wiki/Xvfb">Xvfb</a> swallowing of test programs. This is needed by other projects to run unit tests the way Gtk+ does.</li>
<li> Implement the unit test ideas that are outlined at the end of this email: <a href="http://mail.gnome.org/archives/gtk-devel-list/2006-October/msg00093.html">Gtk+ unit tests (brainstorming)</a>.</li>
</ul>
<p><!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/06/24/23062008-writing-unit-tests-with-glib/feed/</wfw:commentRss>
		</item>
		<item>
		<title>16.06.2008 Sinfex - Simple Infix Expression Evaluator</title>
		<link>http://blogs.gnome.org/timj/2008/06/16/16062008-sinfex-simple-infix-expression-evaluator/</link>
		<comments>http://blogs.gnome.org/timj/2008/06/16/16062008-sinfex-simple-infix-expression-evaluator/#comments</comments>
		<pubDate>Mon, 16 Jun 2008 22:10:35 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[Rapicorn]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/06/16/16062008-sinfex-simple-infix-expression-evaluator/</guid>
		<description><![CDATA[
 The XML GUI definition files used in Rapicorn and also in Beast (described briefly in an  earlier blog post) supported a simple $(function,arguments...) evaluation syntax, similar to GNU Make. I&#8217;ve never been very happy with this syntax, but it was fairly easy to implement at the start and followed naturally from early $VARIABLE [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break -->
<p align="left"> The XML GUI definition files used in <a href="http://rapicorn.org">Rapicorn</a> and also in <a href="http://beast.gtk.org">Beast</a> (described briefly in an <a href="http://blogs.gnome.org/timj/2005/07/31/31072005-rapicorn/"> earlier blog post</a>) supported a simple <code>$(function,arguments...)</code> evaluation syntax, similar to GNU Make. I&#8217;ve never been very happy with this syntax, but it was fairly easy to implement at the start and followed naturally from early <code>$VARIABLE</code> expansion features. At some point last year I considered various alternative syntax variants and discussed the ideas with <a href="http://blogs.gnome.org/stw/">Stefan Westerfeld</a>. Over the course of the last two months, I finally got around to implement them. </p>
<p> <!--- paragraph break -->
<p align="left"> I&#8217;ve never grown familiar with <a href="http://en.wikipedia.org/wiki/Reverse_Polish_notation"> reverse polish notation</a>, and although <a href="http://beast.gtk.org/bsescm.1.html">Guile is the canonical scripting language for Beast</a>, I&#8217;ve always found myself very inefficient with expressing my thoughts in lisp expressions. So the new syntax definitely had to support <a href="http://en.wikipedia.org/wiki/Infix_notation">infix expressions</a> - despite the more complex parsing logic required to parse them. <a href="http://www.gnu.org/software/bison/">Bison</a> already ships with an example calculator that parses infix expressions, so that&#8217;s a quick start as far as the syntax rules go. Integration is quite a different story though, more on that later. </p>
<p> <!--- paragraph break -->
<p align="left"> Since in Rapicorn the expressions are used to compute widget property values, they are likely to be executed <strong>very often</strong>, i.e. each time a widget is created from an XML file description. Consequently, I wanted to use a pre-parsed <a href="http://en.wikipedia.org/wiki/Abstract_syntax_tree">AST</a> to carry out the evaluation and avoid mixing evaluation logic with parser logic, which would have forced reparsing expressions upon each evaluation. At first I quickly threw together some C++ classes for the arithmetic operators and used those as nodes for the AST, similar to: </p>
<pre>  class ASTNodeNot : virtual public ASTNode {
    ASTNode &amp;m_operand;
  public:
    explicit ASTNodeNot (ASTNode &amp;operand) :
      m_operand (a)
    {}
    virtual Value
    eval (Env *env) const
    {
      Value a = m_operand.eval();
      return Value (!a.asbool());
    }
  };
</pre>
<p> <!--- paragraph break -->
<p align="left"> The supported syntax is quickly summarized: </p>
<pre>  Operators: ( + - * / ** &lt; > &lt;= >= == != or and not )
  Functions: name ( args... )
  Inputs:    FloatingPoint 'SingleQuotedString' "DoubleQuotedString"
</pre>
<p align="left"> In this notation, <code>FloatingPoint</code> includes hexadecimal numbers and of course integers and the quoted strings support C style escape sequences like octal numbers, &#8216;<code>&#92;n</code>&#8216;, &#8216;<code>&#92;t</code>&#8216; and so on. The functions can be implemented by the parser API user, but a good set of standard arithmetic functions is already supported like ceil(), floor(), min(), max(), log(), etc. So it&#8217;s a very basic parser, but covers the vast majority of expressions needed to position widgets or configure packing properties. </p>
<p> <!--- paragraph break -->
<p align="left"> One thing that turned out to be tricky is the binary operator semantics for strings. At the very least, I wanted support for <code>"string" + "string"</code> and <code>"string" == "string"</code>. Since both operators are supported for numbers as well, the exact behavior of <code>"string" + FloatingPoint</code> and <code>"string" == FloatingPoint</code> had to be defined. I managed to find a few programming language precedents here in Perl, Python, and ECMAScript (Javascript). They of course all handle the cases differently. In the end I settled with <a href="http://en.wikipedia.org/wiki/Ecmascript">ECMAScript</a> semantics: </p>
<pre>  Value1 == Value2  # does string comparisons if both values are strings
  Value1 + Value2   # does string conversion if either value is a string
</pre>
<p> <!--- paragraph break -->
<p align="left"> Unit testing for the parser turned out to be particularly easy to implement. All that&#8217;s needed is a small utility that reads expressions and prints/verifies the evaluation results. Throwing in some additional shell code allowed a normal text file to drive unit testing. It simply contains expressions and expected results on alternating lines. Btw, <a href="http://tiswww.case.edu/php/chet/readline/rltop.html">libreadline</a> can be really handy in cases like this. Using it takes a mere 5-10 lines of additional code to support a nice interactive command line interface including history for the evaluator test shell. </p>
<p> <!--- paragraph break -->
<p align="left"> After some initial testing, the C++ AST node classes seemed like an awful lot of pointers, fragmentation and <a href="http://en.wikipedia.org/wiki/Vtable"> VTable</a> calls for a supposedly straight forward expression evaluation. Also, adding the missing destruction semantics would have significantly increased the existing class logic. So I tried to come up with a leaner and foremost flat memory presentation. In the end, I settled with a single array that grows in 4 byte (integer) steps, embeds strings literally (padded to 4 byte alignment) and uses array offsets instead of pointers for references. A single multiplication operator is encoded with 3 integers that way: <code>MUL_opcode factor1_index factor2_index</code>. That&#8217;s essentially 12 bytes per binary operator, still significantly more than the parser input, but also significantly smaller than allocating an equivalent C++ class. Evaluation of the expression stored in the array doesn&#8217;t need any VTable calls, and a single straight forward evaluation function can be used, that implements the different operators as switch statement cases. Also release semantics are persuasively trivial for a single consecutive array. </p>
<p> <!--- paragraph break -->
<p align="left"> What&#8217;s left was to figure a way to embed expression evaluation in XML values or text blocks. Previously, <code>$(expression)</code> was substituted everywhere, but with the new syntax, variables (or rather <em>constants</em> defined within the Rapicorn core or via the &#8216;<code>&lt;arg:ArgName default="5"/></code>&#8216; syntax supported by Rapicorn XML files) didn&#8217;t use a <code>$</code>-prefix anymore. So sticking with <code>$()</code> seemed to make little sense. As it&#8217;s implemented now, backticks are used to cause expression evaluation, with the empty expression evaluating to a single backtick: </p>
<pre>  XML Value/Text         Parser Result
    Foo  5 + 5      ->     Foo  5 + 5
    Foo `5 + 5`     ->     Foo 10
    ``Foo``         ->     `Foo`
</pre>
<p> <!--- paragraph break -->
<p align="left"> We will see how useful the current expression style turns out to be. I don&#8217;t consider every implementation bit outlined here solidly engraved into stone yet. So as always, I&#8217;m open to constructive feedback. </p>
<p> <!--- paragraph break -->
<p align="left"> As forewarned, I have a few more words on integrating <a href="http://flex.sourceforge.net/">Flex</a> and Bison with each other and into one&#8217;s own library. First, Flex and Bison turned out not to be exactly simple to configure, especially if none of the generated symbols should be exported from a library or clash with a possible second parser linked into the same library or program. Also some fiddling is required to pass on proper line count information from the lexer to the parser, getting character counts as well is non-trivial but lucky wasn&#8217;t strictly needed for Rapicorn expressions. The simplest setup I managed to come up with works as follows: </p>
<pre>  sinfex.hh     # public API
  sinfeximpl.hh # internal structure definitions
  sinfex.cc     # evaluator implementation
  sinfex.l      # scanner rules for Flex
  sinfex.y      # parser rules for Bison
  sinfex.lgen   # generated by Flex
  sinfex.ygen   # generated by Bison
</pre>
<p align="left"> The only compiled file in this list is <code>sinfex.cc</code> which includes <code>sinfex.lgen</code> and <code>sinfex.ygen</code> as part of an anonymous C++ namespace. A linker script <code><a href="http://git.testbit.eu/Rapicorn/tree/rapicorn/ldscript.map">ldscript.map</a></code> used when finally linking the library prevents anonymous symbols from being exported. The anonymous namespacing of everything declared in <code>sinfex.lgen</code> and <code>sinfex.ygen</code> is what prevents clashes with a possible second parser linked into the library. This isn&#8217;t as elegant as i was hoping for, but at least effective in a practical sense. There unfortunately is <strong>no way</strong> to configure Flex or Bison to generate only <em>static</em> functions and variables. And yes, I have also looked into variants like flex++, bison++, bisonc++, byacc, etc, but they usually show much of the same problems and also tend to make matters worse by generating more files or more complex code. </p>
<p> <!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/06/16/16062008-sinfex-simple-infix-expression-evaluator/feed/</wfw:commentRss>
		</item>
		<item>
		<title>02.06.2008 LinuxTag 2008</title>
		<link>http://blogs.gnome.org/timj/2008/06/02/02062008-linuxtag-2008/</link>
		<comments>http://blogs.gnome.org/timj/2008/06/02/02062008-linuxtag-2008/#comments</comments>
		<pubDate>Mon, 02 Jun 2008 14:54:13 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[Events]]></category>

		<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/06/02/02062008-linuxtag-2008/</guid>
		<description><![CDATA[
 Just like  LinuxTag last year, I went to Berlin the past week to help running the Gnome booth for  LinuxTag 2008.
 
 Due to a sports accident, our booth bunny  Sven Herzberg unfortunately couldn&#8217;t make it, so on Tuesday I took over booth management and merchandise from him and hurried to [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break --></p>
<p align="left"> Just like <a href="http://blogs.gnome.org/timj/2007/06/04/04062007-linuxtag/"> LinuxTag last year</a>, I went to Berlin the past week to help running the Gnome booth for <a href="http://www.linuxtag.org/2008/"> LinuxTag 2008</a>.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Due to a sports accident, our booth bunny <a href="http://herzi.eu/"> Sven Herzberg</a> unfortunately couldn&#8217;t make it, so on Tuesday I took over booth management and merchandise from him and hurried to Berlin in an ICE instead of a car as was originally planned. In Berlin, I met up with <a href="http://taschenorakel.de/mathias/"> Mathias Hasselmann</a> who brought the European Gnome event box and together we set up the booth until late in the night.</p>
<p> <!--- paragraph break --></p>
<p align="center"><a href="http://testbit.eu/%7Etimj/galleries/Linuxtag2008/booth-small.jpg" title="http://testbit.eu/~timj/galleries/Linuxtag2008/ |"> <img src="http://testbit.eu/%7Etimj/galleries/Linuxtag2008/booth-small.jpg" alt="http://testbit.eu/~timj/galleries/Linuxtag2008/ |" /> </a></p>
<p> <!--- paragraph break --></p>
<p align="left"> On Wednesday morning, <a href="http://www.michael-koechling.info/"> Michael Köchling</a> and <a href="http://software.twotoasts.de/"> Christian Dywan</a> arrived, so we had enough people to properly man the booth. Michael seems to be an early riser, since he managed to show up at 09:00 for all days, so i passed the booth keys on to him.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Around lunch time, I was dragged away for an interview about business involvement in free software and Gnome in particular by <a href="http://www.cbs.dk/staff/mc"> Malgorzata Ciesielska</a>, a business school student from Copenhagen. She also interviewed other people like <a href="http://0pointer.de/blog"> Lennart Poettering</a> who also sporadically hung around our booth.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Later that day, Lennart and i went over the new libcanberra API in a lengthy discussion. Libcanberra is a new library for playback or activation of sound events in response to desktop actions that Lennart currently works on. We talked about the needs of timing information for some usage cases, possibly also dispatching forced feedback controls via the library and implementation of a Gtk+ module to hook canberra functionality up with GUI events. What turned out to be a bit tricky is to derive actual semantic information from the low level X event notification that Gtk+ signals proxy, such as dialog-confirmed, dialog-cancelled, menu-item-selected, menu-item-cancelled, combobox-popup, combobox-selected, combobox-cancelled, etc. This extraction requires significantly more logic and special casing of event notification than Lennart apparently had originally hoped for.</p>
<p> <!--- paragraph break --></p>
<p align="left"> On Thursday I attended the <a href="http://www.linuxtag.org/2008/de/conf/events/vp-donnerstag/vortragsdetails.html?talkid=74"> Linux Kernel - Quo vadis?</a> talk by Thomas Gleixner which was quite interesting. I managed to catch him afterwards to talk about the prospects of having a memory pressure signal in the Linux kernel. For GLib and Gtk+, this&#8217;d be quite useful to voluntarily release pixmap or GSlice caches, particularly desired on embedded platforms.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Friday I sat down with Vincent Untz for a very productive discussion about Gnome/Gtk+ release prospects, autotools, intltool features and more. Later I had a chance to chat with <a href="http://behindkde.org/people/neundorf/"> Alexander Neundorf</a> about KDE&#8217;s recent <a href="http://www.cmake.org/HTML/About.html"> CMake</a> migration process. Overall, they seem to be pretty happy with the results. Major benefits from migrating from autotools to CMake seem to be:</p>
<ul type="square">
<li> Build process speedups due to getting rid of libtool.</li>
<li> Simplicity; the build setup is back to a manageable level again. For KDE, the previous combinatoric mess of autotools was hardly fully understood by any single person.</li>
<li> Unification/merging of build files for Unixes and Windows. (Duplication of build logic between auto* files, <a href="http://msdn.microsoft.com/en-us/library/dd9y37ha.aspx"> nmake</a> and MS project files is currently a major annoyance for Gtk+&#8217;s Win32 maintainers.)</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> On Saturday the last day of the conference, I attended <a href="http://easterbridge.com/"> Anne Østergaard</a>&#8217;s presentation about Gnome Foundation structures and achievements, the slides of which are available here: <a href="http://easterbridge.com/files/presentation-LinuxTag-2008.pdf"> The GNOME Foundation (PDF)</a>.</p>
<p> <!--- paragraph break --></p>
<p align="left"> After that, I went to <a href="http://www.jonobacon.org/"> Jono Bacon</a>&#8217;s talk in which he explained how the free software community is a creative and productive community, which sets it apart from other common community types in our society (usually fan communities). He went on pointing out how this collaborative and open community as a whole (and thus every significant contribution to it) impacts and gradually changes the really big IT companies from within in an unprecedented manner. Come to think of it, this is an incredible achievement that we should rejoice in, especially because it is a morally correct change in that it strives towards openness.</p>
<p> <!--- paragraph break --></p>
<p align="left"> All in all, it was a nice conference again. Personally, I particularly enjoy meeting up with other hackers for productive face to face sync ups. So I&#8217;d like to thank Christian and especially Michael for their great efforts in patiently answering bypasser&#8217;s Gnome questions at the booth, while I wandered off to talks or had technical discussions in its back.</p>
<p> <!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/06/02/02062008-linuxtag-2008/feed/</wfw:commentRss>
		</item>
		<item>
		<title>16.05.2008 Becoming a Gtk+ maintainer</title>
		<link>http://blogs.gnome.org/timj/2008/05/16/16052008-becoming-a-gtk-maintainer/</link>
		<comments>http://blogs.gnome.org/timj/2008/05/16/16052008-becoming-a-gtk-maintainer/#comments</comments>
		<pubDate>Fri, 16 May 2008 11:50:19 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[GLib]]></category>

		<category><![CDATA[Gtk+]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/05/16/16052008-becoming-a-gtk-maintainer/</guid>
		<description><![CDATA[
 Amongst many other things during the  Gtk+ Hackfest 2008, it was brought to my attention that Gtk+ maintainership is sometimes perceived as some kind of  leet circle, hard to join for newcomers. I can&#8217;t really imagine how &#8220;hard&#8221; it is for newcomers to join Gtk+ maintenance these days. The learning curve probably [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break --></p>
<p align="left"> Amongst many other things during the <a href="http://live.gnome.org/GTK%2B/Hackfest2008"> Gtk+ Hackfest 2008</a>, it was brought to my attention that Gtk+ maintainership is sometimes perceived as some kind of <a href="http://en.wikipedia.org/wiki/Leet"> leet</a> circle, hard to join for newcomers. I can&#8217;t really imagine how &#8220;<em>hard</em>&#8221; it is for newcomers to join Gtk+ maintenance these days. The learning curve probably is steeper now than it was in the last decade, but then, we do have documentation now and didn&#8217;t have any back then&#8230; ;-)</p>
<p> <!--- paragraph break --></p>
<p align="left"> In any case, I think that definitely none of the Gtk+/GLib core maintainers would want to bar someone else from contributions or helping out with maintenance tasks. So to aid that process, I&#8217;ve written down what I keep telling people who approach me about this in person. A lot of it might seem overly obvious to veterans, but for newcomers or contributors looking into extending their activities on the project I hope to provide helpful starting points.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Much of Gtk+ is still maintained as a huge monolithic whole. That is, a very few people are taking care of a wide variety of components. I think ultimately we would all be much better off, if we had more people being responsible for individual components like particular widgets (e.g. <a href="http://library.gnome.org/devel/gtk/unstable/GtkNotebook.html"> GtkNotebook</a>) or widget families (e.g. <a href="http://library.gnome.org/devel/gtk/unstable/GtkBox.html">GtkBox</a>, <a href="http://library.gnome.org/devel/gtk/unstable/GtkHBox.html">GtkHBox</a>, <a href="http://library.gnome.org/devel/gtk/unstable/GtkVBox.html">GtkVBox</a>). So the following are steps and tasks useful for anyone wanting to get into Gtk+ component maintenance.</p>
<p> <!--- paragraph break --></p>
<p align="left"> First of all, we have the <a href="http://live.gnome.org/GtkTasks">GtkTasks wiki page</a>, a task list with various ways in which people can contribute to the Gtk+ project and start getting involved. In particular for the following positions, no one has signed up so far to volunteer on a regular basis:</p>
<p> <!--- paragraph break --></p>
<ul type="disc">
<li> <strong>Patch/Bug Monitoring &amp; Filing</strong> - collect bugs from mailing lists and IRC to make sure they are being filed.</li>
<li> <strong>FAQ Maintainer</strong> - this involves monitoring the mailing list(s), taking CC:-mails from other people on possible FAQ material and regularly updating the FAQ accordingly.</li>
<li> <strong>Build Monitoring</strong> - run and maintain Gtk+ tool-chain builds on various platforms.</li>
<li> <strong>Making Releases</strong> - we are looking for someone assisting in the release process and to take over release building during some periods in the future.</li>
<li> <strong>Implementing Test Programs</strong> - there&#8217;s much work needed in our unit test coverage, so we&#8217;re always looking for people willing to implement more unit tests.</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> For general information about the maintenance situation, the <a href="http://mail.gnome.org/archives/gtk-devel-list/2006-December/msg00074.html">State of the Gtk+ Maintenance</a> write-up is still fairly valid. However many good things have been suggested by the community since, such as the GtkTasks page and the Hackfest. At the end, the write-up addresses how occasional contributors or developers at different experience levels can help out the project. For instance with activities such as: <em>Bug triage and verification</em>, <em>Review and clarify documentation</em>, <em>Revision hunting for regressions</em>, <em>Refactor code areas</em>, <em>Work on optimizations</em>, and the list goes on.</p>
<p> <!--- paragraph break --></p>
<p align="left"> If none of this sounds interesting to potential new maintainers, be warned that regular maintenance means having to put up with pretty much all of these at some point. ;-)<br />
However, probably the most straight forward way to take on maintenance for a particular code portion (usually a particular widget) is to start becoming familiar with it and work on improving it right away:</p>
<p><!--- paragraph break --></p>
<ul type="disc">
<li> <strong>Cleanup indentation</strong> - lots of contributions to Gtk+ in the past have weakened coding style in various areas. In general we use <a href="http://www.gnu.org/prep/standards/standards.html"> GNU coding style</a> plus a few extra rules similar to the <a href="http://developer.gimp.org/faq.html#id2467385"> Gimp coding style</a>.</li>
<li> <strong>Perform code cleanups</strong> - look for outstanding migrations/refactorings in the code or if the implementation could be simplified/streamlined in areas.</li>
<li> <strong>Check documentation and examples</strong> - contributing by improving the existing documentation, testing existing examples and providing new ones is a very straight forward way to learn about a new component. Also, documentation patches are usually easily and quickly approved.</li>
<li> <strong>Provide unit tests</strong> - writing new unit tests for existing component APIs is even better than providing documentation examples. You get immediate feedback and they should in general be easy to approve to go into upstream. Also, it is definitely an area where Gtk+ and GLib still need lots of work.</li>
<li> <strong>Review bug reports and patches</strong> - go through the <a href="http://bugzilla.gnome.org/browse.cgi?product=gtk+"> Gtk+ bug load</a> of a particular component, see what issues could be closed or need info. Find patches that could be applied or need work and provide/fix patches along the way. Also, feel free to provide review for existing patches where you feel confident to provide reasonable input. For existing maintainers, looking at other people&#8217;s review is one of the best ways to figure if another person is up to the task of taking over component maintenance.</li>
<li> <strong>Actively nag existing maintainers</strong> or people with SVN accounts for trivial patches (like Cody and Mathias who signed up for <a href="http://live.gnome.org/GtkTasks#P2">Patch testing &amp; committing</a>) to review, approve and apply your changes.</li>
<li> <strong>Participate in the project forums</strong> like <a href="http://mail.gnome.org/archives/gtk-devel-list/">gtk-devel-list</a> and #gtk+ (needed to nag people from the <a href="http://www.gtk.org/development.html#Team">core team</a> and other developers), and read and reply in other <a href="http://www.gtk.org/mailing-lists.html">related mailing lists</a>.</li>
</ul>
<p><!--- paragraph break --></p>
<p align="left"> The first few points actually mean working with the code by providing patches, and filing new bug reports with those patches attached. While this may at first increase our bug load, if someone shows sincere interest in taking over component maintenance, sticks to the coding style and provides useful patches, there&#8217;s nothing stopping us from granting new SVN accounts so contributors can commit their own patches after approval.</p>
<p> <!--- paragraph break --></p>
<p align="left"> Finally, the project is welcoming every new contributor. But be reminded that no approval is needed from anyone to start your work. In actuality, asking for it will most probably get you a reserved or negative answer, because improving the project is all about working on it, not making or requesting promises. So, everyone is invited to read through the task lists/descriptions and get their hands dirty immediately. A fair bit of self incentive is needed to take on maintenance of a component anyway, so you&#8217;ll have to get yourself motivated on your own there won&#8217;t be anyone else doing it for you.</p>
<p> <!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/05/16/16052008-becoming-a-gtk-maintainer/feed/</wfw:commentRss>
		</item>
		<item>
		<title>24.04.2008 Announcing Rapicorn 8.4.0</title>
		<link>http://blogs.gnome.org/timj/2008/04/24/24042008-announcing-rapicorn-840/</link>
		<comments>http://blogs.gnome.org/timj/2008/04/24/24042008-announcing-rapicorn-840/#comments</comments>
		<pubDate>Thu, 24 Apr 2008 22:24:38 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[Rapicorn]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/04/24/24042008-announcing-rapicorn-840/</guid>
		<description><![CDATA[
  Rapicorn 8.4.0 has just been released to the world:  Rapicorn v8.4.0 Announcement
 
 Lots of things have happened since the last snapshot over a year ago, some of which kept me from making releases or snapshots earlier. ;-)
Others actually took place in the code base as interesting developments, summarized below.

 There&#8217;s quite [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break --></p>
<p align="left"> <a href="http://rapicorn.org/files/2008/rapicorn-8.4.0.tar.bz2"> Rapicorn 8.4.0</a> has just been released to the world: <a href="http://rapicorn.org/pipermail/rapicorn-list/2008-April/000002.html"> Rapicorn v8.4.0 Announcement</a></p>
<p> <!--- paragraph break --></p>
<p align="left"> Lots of things have happened since the last snapshot over a year ago, some of which kept me from making releases or snapshots earlier. ;-)<br />
Others actually took place in the code base as interesting developments, summarized below.</p>
<p><!--- paragraph break --></p>
<p align="left"> There&#8217;s quite some more stuff in my development queue, but at some point one just has to draw a line and throw out what&#8217;s vaguely ready so far, so this is it for today:</p>
<p> <!--- paragraph break --></p>
<pre>  Overview of changes in Rapicorn 8.4.0:</pre>
<p><!--- paragraph break --></p>
<pre>  * Changed versioning scheme to YEAR.WEEK.REVISION.
  * License update to GNU LGPL 2.1.
  * Added a publically installed tool: rapidrun
  * Support println() and close() commands in GUI files.
  * Introduce simple Application and Window object APIs.
  * Merged libbirnet into Rapicorn as librapicorncore.
  * Implemented expose region merging/comprssion.
  * Reiimplemented rectangle gradient shader.
  * Switched to autogenerated ChangeLogs.
  * Improved feedback on parser errors.
  * Fixed Gtk+ version checks.
  * Added PNG saving support.
  * Removed PERL build dependency.
  * Rewrote asyncronous main loops.
  * Many improvements to text editing areas.
  * Speed up blitting logic for local displays.
  * Added SIMD optimized rendering functions for MMX CPUs.
  * Fixed some reference counting issues and child removal.
  * Improved vertical text ellipsization to line granularity.
  * Removed error prone default values from property mechanism.
  * Install tutorial under ${prefix}/doc/rapicornXXXX/tutorial/.
  * Misc compiler and threading fixes, depend on g++-3.4.6.
  * Lots of bug fixes, cleanups and improved test coverage.</pre>
<p><!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/04/24/24042008-announcing-rapicorn-840/feed/</wfw:commentRss>
		</item>
		<item>
		<title>07.04.2008 On Moving Gtk+ to Git</title>
		<link>http://blogs.gnome.org/timj/2008/04/07/07042008-on-moving-gtk-to-git/</link>
		<comments>http://blogs.gnome.org/timj/2008/04/07/07042008-on-moving-gtk-to-git/#comments</comments>
		<pubDate>Mon, 07 Apr 2008 22:20:46 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[GLib]]></category>

		<category><![CDATA[Gtk+]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/04/07/07042008-on-moving-gtk-to-git/</guid>
		<description><![CDATA[
 There have been several requests about hosting Gtk+ (and GLib) as a  Git repository recently and since that topic has come up more and more often, I meant to write about this for quite some time. 
 
 Let&#8217;s first take a look at the actual motivation for such a move. There are [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break -->
<p align="left"> There have been several requests about hosting Gtk+ (and GLib) as a <a href="http://git.or.cz/"> Git</a> repository recently and since that topic has come up more and more often, I meant to write about this for quite some time. </p>
<p> <!--- paragraph break -->
<p align="left"> Let&#8217;s first take a look at the actual motivation for such a move. There are a good number of advantages we would get out of using Git as a source code repository for Gtk+ and GLib: </p>
<p> <!--- paragraph break -->
<ul type="disc">
<li> We can work offline with the Gtk+ history and source code. </li>
<li> We can work much faster on Gtk+ even when online with tools such as <a href="http://www.kernel.org/pub/software/scm/git/docs/git-log.html"> git-log</a> and <a href="http://www.kernel.org/pub/software/scm/git/docs/git-blame.html"> git-blame</a>. </li>
<li> It will be much easier for people to branch off and do development on their own local branches for a while, exchange their code easily with pulling branches between private repositories, etc. I.e. get all the advantages of a truly distributed versioning system. </li>
<li> With Git it&#8217;s much easier to carry along <a href="http://bugzilla.gnome.org/show_bug.cgi?id=318807"> big Gtk+ changes</a> including history by using <a href="http://www.kernel.org/pub/software/scm/git/docs/git-cherry-pick.html"> cherry picking</a> and <a href="http://www.kernel.org/pub/software/scm/git/docs/git-rebase.html"> (interactive) rebasing</a>. </li>
<li> We can make proper <strong>public</strong> backups of the source code repositories. This ought to be possible already via <a href="http://svnbook.red-bean.com/en/1.4/svn.ref.svnsync.html"> svnsync</a>, but isn&#8217;t for <a href="http://svn.gnome.org/viewvc/"> svn.gnome.org</a> because we run an svn 1.3.x server instead of an svn 1.4.x server that is required by svnsync. (Yes, this issue has been raised with the sysadmins already.) </li>
</ul>
<p> <!--- paragraph break -->
<p align="left"> A quick poll on IRC has shown that all affected core maintainers are pretty much favoring Git over SVN as a source code repository for GLib/Gtk+. </p>
<p> <!--- paragraph break -->
<p align="left"> However, here are the points to be considered for not moving the repositories to Git (just yet): </p>
<p> <!--- paragraph break -->
<ul type="disc">
<li> Complexity; Git is often perceived to be harder to use than SVN, there are several attempts to mitigate this problem though: <a href="http://www.gnome.org/~newren/eg/"> Easy Git</a> <a href="http://developer.imendio.com/projects/giggle/"> Giggle</a> <a href="http://blogs.gnome.org/timj/2007/10/30/30102007-yummyyummysourcecontrol-version-09/"> yyhelp</a>. <br /> With some of the above, Git is as easy to use as SVN is, so Git complexity doesn&#8217;t need to be holding anyone off at this point. </li>
<li> Git may be stable and mature these days, but <a href="http://www.kernel.org/pub/software/scm/git/docs/git-svn.html"> git-svn</a> is not there yet. It is generally good enough to create local Git mirrors of SVN repositories and work from those to have most of the Git convenience on top of an SVN project. <br /> But git-svn has seen structural changes recently, quite some rewriting and bug fixing that indicate it&#8217;s still too much in flux for the one-and-only SVN->Git migration for projects at the scale of Gtk+. This is not meant as criticism on git-svn, fairly the opposite actually. It&#8217;s good to see such an important component be alive and vivid. All issues I&#8217;ve raised with the maintainer so far have been addressed, but it seems advisable to wait for some stabilization before trusting all the Gtk+ history to it. </li>
<li> <a href="http://git.or.cz/gitwiki/Gitweb"> Gitweb</a> interfaces already exist for GLib/Gtk+ mirrors, for example on testbit: <a href="http://git.testbit.eu"> Testbit Git Browser</a>. <br /> These can be used for cloning which is much faster than a full git-svn import. Alternatively, shallow git-svn imports can be created like this:
<pre>  git-svn clone -T trunk -b branches -t tags -r 19001 svn://svn.gnome.org/svn/gtk+
</pre>
<p> This will create a repository with a mere ~1000 revisions, including all changes since we branched for 2.12. We&#8217;re using such a shallow repository for faster cloning of our <a href="http://micke.hallendal.net/blog/gtk-30-enabling-incrementalism/"> GSEAL()</a> development at Imendio: <a href="http://git.imendio.com/?p=projects/gtk%2B.git"> view gtk+.git</a>. </li>
<li> In summer 2006, we&#8217;ve had the first test migration of all of GNOME CVS to SVN, in December 2006 we&#8217;ve had the final migration. During that period, the <a href="http://beast.gtk.org"> Beast</a> project stayed migrated to SVN to work out the quirks from the CVS->SVN migration before we migrate all other GNOME modules and have to fix up everyones converted modules. There were quite some issues that needed fixing after the initial test migration and in the end we had to <a href="http://mail.gnome.org/archives/beast/2007-January/msg00001.html"> rebuild the Beast development history from pieces</a>. Preventing the other GNOME modules from such hassle was the entire point in migrating Beast early on, so I&#8217;m not complaining. <br /> However, given the size and importance of GLib/Gtk+, the development history of those projects shouldn&#8217;t be put at a similar risk. That is, GLib/Gtk+ shouldn&#8217;t be pioneering our next source repository migration, let some other small project do this and work out the quirks first. </li>
<li> git-svn already provides a good part of the Git advantages to developers while Gtk+ stays hosted in SVN. Albeit due to mismatching hashes, syncing branches between distinct git-svn checkouts of different people is tedious. Setting up an &#8220;official&#8221; git-svn mirror on <a href="http://gtk.org"> git.gtk.org</a> could probably help here. Also, to ease integration, <a href="http://www.gnome.org/~jamesh/jhbuild.html"> jhbuild</a> could be extended to use git-svn instead of svn commandos to update SVN modules, if the current module has a .git/ subdirectory instead of a .svn/ subdirectory. </li>
</ul>
<p> <!--- paragraph break -->
<p align="left"> The bottom line is, there&#8217;s a good number of advantages that Git already can (or <em>could</em>) provide for our development even without migrating the repositories to Git right away. When exactly will be a good point for migrating GLib/Gtk+ and possibly other GNOME modules might not be an easy call, but right now is definitely too early. </p>
<p> <!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/04/07/07042008-on-moving-gtk-to-git/feed/</wfw:commentRss>
		</item>
		<item>
		<title>05.02.2008 Thread-safe class initializers</title>
		<link>http://blogs.gnome.org/timj/2008/02/05/05022008-thread-safe-class-initializers/</link>
		<comments>http://blogs.gnome.org/timj/2008/02/05/05022008-thread-safe-class-initializers/#comments</comments>
		<pubDate>Tue, 05 Feb 2008 18:17:43 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[GLib]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2008/02/05/05022008-thread-safe-class-initializers/</guid>
		<description><![CDATA[
 I finally got around to fix a long-standing and tricky bug report: Bug 64764 - Class initialization isn&#8217;t thread safe.  Thread safety problems in class initializers and _get_type() functions caused nasty problems in other components that depend on parallel type creation, in particular GStreamer (Dependency Graph for bug 64764). With both being fixed [...]]]></description>
			<content:encoded><![CDATA[<p><!--- paragraph break -->
<p align="left"> I finally got around to fix a long-standing and tricky bug report: <code><a href="http://bugzilla.gnome.org/show_bug.cgi?id=64764">Bug 64764 - Class initialization isn&#8217;t thread safe</a></code>. <br /> Thread safety problems in class initializers and <a href="http://bugzilla.gnome.org/show_bug.cgi?id=65041">_get_type() functions</a> caused nasty problems in other components that depend on parallel type creation, in particular GStreamer (<a href="http://bugzilla.gnome.org/showdependencygraph.cgi?id=64764">Dependency Graph for bug 64764</a>). With both being fixed now, testing feedback about GType/GObject threading problems using GLib trunk is appreciated. </p>
<p> <!--- paragraph break --></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2008/02/05/05022008-thread-safe-class-initializers/feed/</wfw:commentRss>
		</item>
		<item>
		<title>30.10.2007 YummyYummySourceControl Version 0.9</title>
		<link>http://blogs.gnome.org/timj/2007/10/30/30102007-yummyyummysourcecontrol-version-09/</link>
		<comments>http://blogs.gnome.org/timj/2007/10/30/30102007-yummyyummysourcecontrol-version-09/#comments</comments>
		<pubDate>Tue, 30 Oct 2007 09:54:04 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2007/10/30/30102007-yummyyummysourcecontrol-version-09/</guid>
		<description><![CDATA[ A couple people have reported minor and major bugs in the last yyhelp version, particularly after yycommit got reimplemented to operate on top of git-commit(1) instead of cg-commit(1). Besides some others, this new release fixes all known yycommit issues and also (re-)introduces some new features: yyhelp (v0.9)
 
	Overview of Changes in YummyYummySourceControl-0.9:

	* use plain [...]]]></description>
			<content:encoded><![CDATA[<p> A couple people have reported minor and major bugs in the last yyhelp version, particularly after yycommit got reimplemented to operate on top of <a href="http://www.kernel.org/pub/software/scm/git/docs/git-commit.html">git-commit(1)</a> instead of <a href="http://www.kernel.org/pub/software/scm/cogito/docs/cg-commit.1.html">cg-commit(1)</a>. Besides some others, this new release fixes all known yycommit issues and also (re-)introduces some new features: <a href="http://testbit.eu/~timj/tools/yyhelp">yyhelp</a> (v0.9)<br />
<code> </code></p>
<pre>	Overview of Changes in YummyYummySourceControl-0.9:

	* use plain "git-commit" with temporary index file to stage
	  commit files, this works around git-commit-1.5.2.5 not
          handling deleted files as command line args correctly.
	* also list remote branches for yylsbranches.
	* fix leading dot getting stripped from modified files if $gitprefix=.
	* require and use gawk for time formatting, which mawk doesn't support.
	* properly honor the [FILES...] arguments to yycommit.
	* terminate sed command blocks with semicolon (needed on BSD).
	* resurrected yyhelp.auto-push-commits functionality of yycommit.</pre>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2007/10/30/30102007-yummyyummysourcecontrol-version-09/feed/</wfw:commentRss>
		</item>
		<item>
		<title>13.10.2007 Yummy-Yummy Porcelain Version 0.8</title>
		<link>http://blogs.gnome.org/timj/2007/10/13/13102007-yummy-yummy-porcelain-version-08/</link>
		<comments>http://blogs.gnome.org/timj/2007/10/13/13102007-yummy-yummy-porcelain-version-08/#comments</comments>
		<pubDate>Sat, 13 Oct 2007 22:02:55 +0000</pubDate>
		<dc:creator>Tim Janik</dc:creator>
		
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://blogs.gnome.org/timj/2007/10/13/13102007-yummy-yummy-porcelain-version-08/</guid>
		<description><![CDATA[ Here is a new release of YummyYummySourceControl, a shallow porcelain script around common git(7) command variants: yyhelp (v0.8)
This version supports a new command to grep and match an extended regular expression on the full project history by invoking git-grep(1) on all existing commits, displaying matches by commit hash and file name. Also, a CVS/SVN/Cogito [...]]]></description>
			<content:encoded><![CDATA[<p> Here is a new release of YummyYummySourceControl, a shallow porcelain script around common <a href="http://www.kernel.org/pub/software/scm/git/docs/">git(7)</a> command variants: <a href="http://testbit.eu/~timj/tools/yyhelp">yyhelp</a> (v0.8)</p>
<p>This version supports a new command to grep and match an extended regular expression on the full project history by invoking <a href="http://www.kernel.org/pub/software/scm/git/docs/git-grep.html">git-grep(1)</a> on all existing commits, displaying matches by commit hash and file name. Also, a CVS/SVN/Cogito style version of yycommit has now been implemented on top of <a href="http://www.kernel.org/pub/software/scm/git/docs/git-commit.html">git-commit(1)</a>. So YummyYummySourceControl-0.8 finally gets rid of the last remaining <a href="http://www.kernel.org/pub/software/scm/cogito/docs/cg-commit.1.html">cogito dependency</a>, making it a free standing <em>Git Porcelain Suite</em>. ;-)<br />
Of course there have also been some other miscellaneous changes and docu updates. <code> </code></p>
<pre>	Overview of Changes in YummyYummySourceControl-0.8:

	* removed cogito(7) dependency.
	* made yyview start gitk in the background.
	* suppress yydiff outputs of non-checked-out files (ignored by yycommit).
	* implemented yycommit SVN/CVS/CG-alike on top of git-commit.
	* added '-s' option to yyChangeLog to skip SVN revisions.
	* implemented yyHistoryGrep.</pre>
<p>I have been asked some of the purpose of YummyYummySourceControl, so i will extend a bit on that here:</p>
<p>- On <a href="http://mail.gnome.org/archives/beast/2007-January/msg00001.html">some occasions</a> i had to dig quite deeply into the nitty-gritty details of git (and cogito). However i can simply not be bothered to deal with the complexity of its command set for everyday use. I need my source control interface to be <strong>really simple</strong> when i concentrate on the various projects i&#8217;m involved in.</p>
<p>- I refuse to bother with the state (or existence) of git&#8217;s index file for anything but the correct implementation of yyhelp. SVN and CVS don&#8217;t force me to deal with an intermediate cache state between repository and working tree, YummyYummySourceControl keeps me from seeing it in git.</p>
<p>- I might be using yydiff and yyview up to a dozen or so times per hour while working. Passing options along here or piping the output to a pager or starting stuff in the background really becomes unaffordable at that rate. These commands do all the necessary stuff out of the box, all i have to type is &#8220;yyd&#8221;+Tab+Return and &#8220;yyv&#8221;+Tab+Return for each of them now.</p>
<p>- I&#8217;m too old and stupid to remember to pull after i&#8217;ve pushed and what the <a href="http://www.kernel.org/pub/software/scm/git/docs/git-svn.html">git-svn(1)</a> command variants look like. yypull and yypushpull handle that for me.</p>
<p>- Personally, i find ChangeLog style logs much more parsable than <a href="http://www.kernel.org/pub/software/scm/git/docs/git-log.html">git-log(1)</a> output. yyChangeLog gives me that for the git commit history.</p>
<p>- To allow proper git merging, cherry picking, rebasing, etc, i&#8217;ve switched to commit my ChangeLog entries as commit message only (with introductionary one-liner instead of the date + email header) and for <a href="http://rapicorn.org">Rapicorn</a> auto-generate the project ChangeLog for tarballs. Even if the ChangeLog is not auto generated as with <a href="http://beast.gtk.rg">Beast</a> or <a href="http://gtk.rg">Gtk+</a>, i can still use this commit message scheme for git-svn checkouts, as long as i update the project&#8217;s SVN ChangeLog before yypushpull-ing the changes from my local tree to SVN. yyChangeLog -s will generate the remaining ChangeLog portion missing from SVN.</p>
<p>- To help my utter laziness, yystatus -c can preformat file name change lists for my ChangeLog-style commit messages, i&#8217;ve always missed that with CVS and SVN.</p>
<p>- To help against sudden confusion and lengthy URL searches, yyinfo tells me all i want to know about a repository (git URL + revision, SVN URL + revision, etc).</p>
<p>And i love to have grep-able access to all the data involved in my day to day activities, yyHistoryGrep now gives me that for my project histories.</p>
<p>Given git&#8217;s speed, the possibility for light-weight local repositories, and using yyhelp&#8217;s ease, revision control has become so available for me, that i could very comfortably apply it to portions of my home directory and /etc/ on a remote server (e.g. i&#8217;ve created a ~/.git/ a couple months ago where i checked in a handful selected files like TODO, my blog diary, .emacs and a few other frequently changing TODO-style files and i&#8217;m happily committing to it multiple times a day).</p>
<p>I&#8217;m not claiming that yyhelp solves anyone else&#8217;s problems, but it certainly has helped my SCM usage a great deal, and for me serves as a key to make a frequently used subset of the git machinery accessible at very few finger tips.</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.gnome.org/timj/2007/10/13/13102007-yummy-yummy-porcelain-version-08/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>

<!-- Dynamic Page Served (once) in 1.778 seconds -->
<!-- Cached page served by WP-Cache -->
