On Mon, Oct 4, 2010 at 23:52, Robert Park <[email protected]> wrote:
> Since nobody's replied and Google doesn't even really know, I emailed
> John Palmieri directly, who kindly explained that the file
> /usr/share/gir-1.0/Gtk-2.0.gir holds all the answers. It's the
> introspection data in XML format, so it's mostly human readable.
>
> For example, I needed to know the new name for the constant
> Gtk.TREE_VIEW_COLUMN_AUTOSIZE, so I searched through the .gir file,
> and eventually found this:
>
>    <enumeration name="TreeViewColumnSizing"
>                 glib:type-name="GtkTreeViewColumnSizing"
>                 glib:get-type="gtk_tree_view_column_sizing_get_type"
>                 c:type="GtkTreeViewColumnSizing">
>      <member name="grow_only"
>              value="0"
>              c:identifier="GTK_TREE_VIEW_COLUMN_GROW_ONLY"
>              glib:nick="grow-only"/>
>      <member name="autosize"
>              value="1"
>              c:identifier="GTK_TREE_VIEW_COLUMN_AUTOSIZE"
>              glib:nick="autosize"/>
>      <member name="fixed"
>              value="2"
>              c:identifier="GTK_TREE_VIEW_COLUMN_FIXED"
>              glib:nick="fixed"/>
>    </enumeration>
>
> The new name of the constant is going to be "Gtk" plus the enumeration
> name "TreeViewColumnSizing", plus the member name "autosize" in ALL
> CAPS, separated by periods. So: Gtk.TreeViewColumnSizing.AUTOSIZE
>
> I hope Google picks this up for the sake of other people like myself
> who've struggled with this.

Hi,

this is kind of mentioned in
http://live.gnome.org/PyGObject/IntrospectionPorting , see the
pygi-convert.sh script.

It would be great if you could help making that page more useful (and
maybe easier to find), right now the number of contributors is
ridiculously small compared with the number of people who will have to
port their apps to introspection.

Thanks,

Tomeu

> On Fri, Oct 1, 2010 at 3:16 PM, Robert Park <[email protected]> wrote:
>> Hi everybody,
>>
>> I'm trying to port a medium sized app to use the new
>> introspection-based PyGObject stuff, and a big stumbling block I've
>> come up against is that all the constants have changed their names
>> (the irony! it burns!). For example, gtk.WINDOW_TOPLEVEL is now
>> Gtk.WindowType.TOPLEVEL.
>
> --
> http://exolucere.ca
> _______________________________________________
> pygtk mailing list   [email protected]
> http://www.daa.com.au/mailman/listinfo/pygtk
> Read the PyGTK FAQ: http://faq.pygtk.org/
>
_______________________________________________
pygtk mailing list   [email protected]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/

Reply via email to