1 // Generated by gtkmmproc -- DO NOT MODIFY!
3 #include <libgnomecanvasmm/group.h>
4 #include <libgnomecanvasmm/private/group_p.h>
11 * Copyright (C) 1998 EMC Capital Management Inc.
12 * Developed by Havoc Pennington <hp@pobox.com>
14 * This library is free software; you can redistribute it and/or
15 * modify it under the terms of the GNU Library General Public
16 * License as published by the Free Software Foundation; either
17 * version 2 of the License, or (at your option) any later version.
19 * This library is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
22 * Library General Public License for more details.
24 * You should have received a copy of the GNU Library General Public
25 * License along with this library; if not, write to the Free
26 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
35 Group::Group(Group& parentx, double x, double y)
36 : Item(GNOME_CANVAS_ITEM(g_object_new(get_type(), 0)))
38 item_construct(parentx);
39 set("x", x, "y", y, 0);
42 } /* namespace Canvas */
43 } /* namespace Gnome */
48 } // anonymous namespace
54 Gnome::Canvas::Group* wrap(GnomeCanvasGroup* object, bool take_copy)
56 return dynamic_cast<Gnome::Canvas::Group *> (Glib::wrap_auto ((GObject*)(object), take_copy));
59 } /* namespace Glib */
68 /* The *_Class implementation: */
70 const Glib::Class& Group_Class::init()
72 if(!gtype_) // create the GType if necessary
74 // Glib::Class has to know the class init function to clone custom types.
75 class_init_func_ = &Group_Class::class_init_function;
77 // This is actually just optimized away, apparently with no harm.
78 // Make sure that the parent type has been created.
79 //CppClassParent::CppObjectType::get_type();
81 // Create the wrapper type, with the same class/instance size as the base type.
82 register_derived_type(gnome_canvas_group_get_type());
84 // Add derived versions of interfaces, if the C type implements any interfaces:
90 void Group_Class::class_init_function(void* g_class, void* class_data)
92 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
93 CppClassParent::class_init_function(klass, class_data);
98 Glib::ObjectBase* Group_Class::wrap_new(GObject* o)
100 return manage(new Group((GnomeCanvasGroup*)(o)));
105 /* The implementation: */
107 Group::Group(const Glib::ConstructParams& construct_params)
109 Item(construct_params)
113 Group::Group(GnomeCanvasGroup* castitem)
115 Item((GnomeCanvasItem*)(castitem))
124 Group::CppClassType Group::group_class_; // initialize static member
126 GType Group::get_type()
128 return group_class_.init().get_type();
131 GType Group::get_base_type()
133 return gnome_canvas_group_get_type();
139 Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations.
140 Item(Glib::ConstructParams(group_class_.init()))
145 Glib::PropertyProxy<double> Group::property_x()
147 return Glib::PropertyProxy<double>(this, "x");
150 Glib::PropertyProxy_ReadOnly<double> Group::property_x() const
152 return Glib::PropertyProxy_ReadOnly<double>(this, "x");
155 Glib::PropertyProxy<double> Group::property_y()
157 return Glib::PropertyProxy<double>(this, "y");
160 Glib::PropertyProxy_ReadOnly<double> Group::property_y() const
162 return Glib::PropertyProxy_ReadOnly<double>(this, "y");
166 } // namespace Canvas