Re: Installing properties for arbitrary structure?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2007-10-18 at 22:52 -0700, Lawrence Nolin wrote:
> To install a property for fundamental types such as integers, chars,
> etc, you can use g_param_spec_*() and g_object_class_install_property().
> My question is: how do I create a GParamSpec and install a property for
> an arbitrary non-GObject C structure? I'm worried that values stored in
> the properties won't be garbage collected. I could wrap the structures
> in GObject subclasses and use g_param_spec_gobject, but that seems
> overkill. Any help?

Use GBoxed[1] and g_param_spec_boxed().

1.
http://library.gnome.org/devel/gobject/stable/gobject-Boxed-Types.html

Ed

_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux