Re: GType stuff again!
- From: Johannes Schmid <johannes schmid gmx de>
- To: gtkmm-list gnome org
- Subject: Re: GType stuff again!
- Date: Tue, 19 Sep 2006 11:43:55 +0200
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi!
I tried out the examples in gtkmm to find out if they are able to handle
their GTypenames correclty. Unfortunately they do not:
std::cout << g_type_name(get_type()) << std::endl;
in the cellrenderercustom example just gives me
"gtkmm__GtkCellRenderer". But of course g_object_new(type) will give not
give me a custom but a standart CellRenderer.
Anyway, I still need something that gives me a custom type that
g_object_new can handle.
Thanks for any ideas,
Johannes
Johannes Schmid wrote:
> Hi!
>
> So, I came around a bit more with debugging the GType things for
> libanjutamm and found out what I need.
>
> Anjuta calls a function in the plugin to find out the GType of the base
> class which has to be derived from AnjutaPlugin. In C++ this means I
> somehow call MyPlugin::type() to get the correct type. Anyway, this does
> not give me a custom type but just gtkmm_AnjutaPlugin.
>
> As the next step, Anjuta creates an object of the type determined by the
> call above with g_object_new(). My problem is now, that I need the to
> get a unique GType of my plugin class to be able to create such a class
> with g_object_new(). Would be nice if anyone would now how to do this.
>
> Calling Glib::ObjectBase("sometype") in the constructor did not help, btw.
>
> Regards,
> Johannes
_______________________________________________
gtkmm-list mailing list
gtkmm-list gnome org
http://mail.gnome.org/mailman/listinfo/gtkmm-list
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFD7vb7Dsf+G5b/WsRAqjPAJ9LdkqS9DGo5Y2z/9tJzMF0E8vkPQCgwDXv
jeq675bYGIl5bZ41gH/CsvU=
=GnNZ
-----END PGP SIGNATURE-----
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]