<?xml version="1.0" encoding="iso-8859-1"?>
<feed version="0.3"
  xmlns="http://purl.org/atom/ns#"
  xmlns:dc="http://purl.org/dc/elements/1.1/"
  xml:lang="eng">
  <title>Ramblings on Mike Kestner's Existence</title>
  <link rel="alternate" type="text/html" href="http://primates.ximian.com/~mkestner/weblog/index.php"/>
  <modified>2004-06-15T20:27:11-04:00</modified>
  <author>
    <name>Mike</name>
    <url>http://primates.ximian.com/~mkestner/weblog/index.php</url>
    <email>mkestner@ximian.com</email>
  </author>
  <tagline></tagline>
  <id>tag:pivotpowered,2004:ramblingsonmikekestnersexistence</id>
  <generator url="http://www.pivotlog.net" version="Pivot+-+1.10%3A+%27Soundwave%27">Pivot</generator>
  <copyright>Copyright (c) 2004, Authors of Ramblings on Mike Kestner's Existence</copyright>
<entry>
    <title>Time wasting</title>
    <link rel="alternate" type="text/html" href="http://primates.ximian.com/~mkestner/weblog/pivot/entry.php?id=1"/>
    <modified>2004-06-15T16:40:00-04:00</modified>
    <issued>2004-06-15T16:40:00-04:00</issued>
    <id>tag:pivotpowered,2004:ramblingsonmikekestnersexistence.1</id>

    <created>2004-06-15T16:40:00-04:00</created>
    <summary type="text/plain">Trying out pivot after Martin's glowing praise.  It's not too bad of a conversion, although I messed with the stylesheet and templates considerably. I don't think it looks too horrible now, but I'm sure many of my css-skilled readers will disagree.  ;-)  I liked the clean, boring look of the default MT templates.  

Here's a helpful page for anyone considering a move from MT to pivot.  The export/import of my MT entries worked like a charm.</summary>
    <dc:subject>Time wasting</dc:subject>
		<author>
		 <name>mkadmin</name>
	  </author>
    <content type="text/html" mode="escaped" xml:lang="en" xml:base="http://primates.ximian.com/~mkestner/weblog/pivot/entry.php?id=1">
      <![CDATA[Trying out <a href="http://pivotlog.net"  target='_blank'>pivot</a> after <a href="http://primates.ximian.com/~martin/blog/entry_60.html"  target='_blank'>Martin's glowing praise</a>.  It's not too bad of a conversion, although I messed with the stylesheet and templates considerably. I don't think it looks too horrible now, but I'm sure many of my css-skilled readers will disagree.  ;-)  I liked the clean, boring look of the default MT templates.  <br /><br />
<br /><br />
<a href="http://pivotlog.net/help/help_converting_movabletype.php"  title="" target='_blank'>Here's</a> a helpful page for anyone considering a move from MT to pivot.  The export/import of my MT entries worked like a charm.]]>
    </content>
  </entry>
<entry>
    <title>Timing</title>
    <link rel="alternate" type="text/html" href="http://primates.ximian.com/~mkestner/weblog/pivot/entry.php?id=37"/>
    <modified>2004-05-29T13:58:00-04:00</modified>
    <issued>2004-05-29T13:58:00-04:00</issued>
    <id>tag:pivotpowered,2004:ramblingsonmikekestnersexistence.37</id>

    <created>2004-05-29T13:58:00-04:00</created>
    <summary type="text/plain">My timing with a digital camera is impeccable...

</summary>
    <dc:subject>Timing</dc:subject>
		<author>
		 <name>mkestner</name>
	  </author>
    <content type="text/html" mode="escaped" xml:lang="en" xml:base="http://primates.ximian.com/~mkestner/weblog/pivot/entry.php?id=37">
      <![CDATA[My timing with a digital camera is impeccable...<br /><br />
<br /><br />
<img alt="JR_ucap.JPG" src="http://primates.ximian.com/~mkestner/blog/archives/JR_ucap.JPG" width="400" height="300" border="0" />]]>
    </content>
  </entry>
<entry>
    <title>Initialize this!</title>
    <link rel="alternate" type="text/html" href="http://primates.ximian.com/~mkestner/weblog/pivot/entry.php?id=36"/>
    <modified>2004-05-17T23:10:00-04:00</modified>
    <issued>2004-05-17T23:10:00-04:00</issued>
    <id>tag:pivotpowered,2004:ramblingsonmikekestnersexistence.36</id>

    <created>2004-05-17T23:10:00-04:00</created>
    <summary type="text/plain">One of the interesting unsolved challenges in Gtk# is the burden of calling init functions on the underlying libraries.  It would be nice if the framework had an easy mechanism to execute code when an assembly is loaded by the runtime. If I could write a class like:

[AssemblyInitialization]
public class MyInitializer : IAssemblyInitializer {
    public static void Initialize ()
    {
          do_some_stuff ();
    }
}

to cause an initialization method to run automatically when an assembly is loaded, I'd be a happy hacker.  A cleaner approach might be to have an attribute on the assembly itself that identified an IAssemblyInitializer implementor so that less reflection would need to be done at load time to identify whether an implementor exists.

I've been thinking about this problem because of the receipt of another bug report for crashes in a gtkhtml-sharp application because the app wasn't calling the ObjectManager.Initialize method to register the assembly's GType mappings.  In all fairness, it's completely unreasonable to expect anybody to know they would need to manually call that method.  I've been wanting to automate that registration ever since the ObjectManager functionality was added.

Lacking a nice clean mechanism like IAssemblyInitializer, I came up with a hack that generates .cctors which call the ObjectManager.Initialize method if an object's GType name is going to have to be registered with GLib.ObjectManager at runtime.  This solution will most likely work for most users of gtkhtml-sharp, since a &quot;new Gtk.HTML ()&quot; statement is likely to be used pretty early, but it doesn't take much thought to come up with scenarios that will break it. 

Generating a ton of .cctors also isn't a reasonable solution for scenarios like the automatic invocation of gtk_init.  We'd probably need something like the IAssemblyInitializer solution to correctly deal with that problem.</summary>
    <dc:subject>Initialize this!</dc:subject>
		<author>
		 <name>mkestner</name>
	  </author>
    <content type="text/html" mode="escaped" xml:lang="en" xml:base="http://primates.ximian.com/~mkestner/weblog/pivot/entry.php?id=36">
      <![CDATA[One of the interesting unsolved challenges in Gtk# is the burden of calling init functions on the underlying libraries.  It would be nice if the framework had an easy mechanism to execute code when an assembly is loaded by the runtime. If I could write a class like:<br /><br />
<pre><br /><br />
[AssemblyInitialization]<br /><br />
public class MyInitializer : IAssemblyInitializer {<br /><br />
    public static void Initialize ()<br /><br />
    {<br /><br />
          do_some_stuff ();<br /><br />
    }<br /><br />
}<br /><br />
</pre><br /><br />
to cause an initialization method to run automatically when an assembly is loaded, I'd be a happy hacker.  A cleaner approach might be to have an attribute on the assembly itself that identified an IAssemblyInitializer implementor so that less reflection would need to be done at load time to identify whether an implementor exists.<br /><br />
<br /><br />
I've been thinking about this problem because of the receipt of another bug report for crashes in a gtkhtml-sharp application because the app wasn't calling the ObjectManager.Initialize method to register the assembly's GType mappings.  In all fairness, it's completely unreasonable to expect anybody to know they would need to manually call that method.  I've been wanting to automate that registration ever since the ObjectManager functionality was added.<br /><br />
<br /><br />
Lacking a nice clean mechanism like IAssemblyInitializer, I came up with a hack that generates .cctors which call the ObjectManager.Initialize method if an object's GType name is going to have to be registered with GLib.ObjectManager at runtime.  This solution will most likely work for most users of gtkhtml-sharp, since a "new Gtk.HTML ()" statement is likely to be used pretty early, but it doesn't take much thought to come up with scenarios that will break it. <br /><br />
<br /><br />
Generating a ton of .cctors also isn't a reasonable solution for scenarios like the automatic invocation of gtk_init.  We'd probably need something like the IAssemblyInitializer solution to correctly deal with that problem.]]>
    </content>
  </entry>

</feed>
