1 // Generated by gtkmmproc -- DO NOT MODIFY!
3 #include <gtkmm/buttonbox.h>
4 #include <gtkmm/private/buttonbox_p.h>
11 * Copyright 1998-2002 The gtkmm Development Team
13 * This library is free software; you can redistribute it and/or
14 * modify it under the terms of the GNU Library General Public
15 * License as published by the Free Software Foundation; either
16 * version 2 of the License, or (at your option) any later version.
18 * This library is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 * Library General Public License for more details.
23 * You should have received a copy of the GNU Library General Public
24 * License along with this library; if not, write to the Free
25 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
28 #include <gtk/gtkhbbox.h>
29 #include <gtk/gtkvbbox.h>
34 VButtonBox::VButtonBox(ButtonBoxStyle layout, int spacing)
36 Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations.
37 ButtonBox(Glib::ConstructParams(vbuttonbox_class_.init(), (char*) 0))
43 HButtonBox::HButtonBox(ButtonBoxStyle layout, int spacing)
45 Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations.
46 ButtonBox(Glib::ConstructParams(hbuttonbox_class_.init(), (char*) 0))
57 } // anonymous namespace
63 Gtk::ButtonBox* wrap(GtkButtonBox* object, bool take_copy)
65 return dynamic_cast<Gtk::ButtonBox *> (Glib::wrap_auto ((GObject*)(object), take_copy));
68 } /* namespace Glib */
74 /* The *_Class implementation: */
76 const Glib::Class& ButtonBox_Class::init()
78 if(!gtype_) // create the GType if necessary
80 // Glib::Class has to know the class init function to clone custom types.
81 class_init_func_ = &ButtonBox_Class::class_init_function;
83 // This is actually just optimized away, apparently with no harm.
84 // Make sure that the parent type has been created.
85 //CppClassParent::CppObjectType::get_type();
87 // Create the wrapper type, with the same class/instance size as the base type.
88 register_derived_type(gtk_button_box_get_type());
90 // Add derived versions of interfaces, if the C type implements any interfaces:
96 void ButtonBox_Class::class_init_function(void* g_class, void* class_data)
98 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
99 CppClassParent::class_init_function(klass, class_data);
104 Glib::ObjectBase* ButtonBox_Class::wrap_new(GObject* o)
106 return manage(new ButtonBox((GtkButtonBox*)(o)));
111 /* The implementation: */
113 ButtonBox::ButtonBox(const Glib::ConstructParams& construct_params)
115 Gtk::Box(construct_params)
119 ButtonBox::ButtonBox(GtkButtonBox* castitem)
121 Gtk::Box((GtkBox*)(castitem))
125 ButtonBox::~ButtonBox()
130 ButtonBox::CppClassType ButtonBox::buttonbox_class_; // initialize static member
132 GType ButtonBox::get_type()
134 return buttonbox_class_.init().get_type();
137 GType ButtonBox::get_base_type()
139 return gtk_button_box_get_type();
143 ButtonBoxStyle ButtonBox::get_layout() const
145 return ((ButtonBoxStyle)(gtk_button_box_get_layout(const_cast<GtkButtonBox*>(gobj()))));
148 void ButtonBox::set_layout(ButtonBoxStyle layout_style)
150 gtk_button_box_set_layout(gobj(), ((GtkButtonBoxStyle)(layout_style)));
153 void ButtonBox::set_child_secondary(Widget& child, bool is_secondary)
155 gtk_button_box_set_child_secondary(gobj(), (child).gobj(), static_cast<int>(is_secondary));
158 bool ButtonBox::get_child_secondary(const Gtk::Widget& child) const
160 return gtk_button_box_get_child_secondary(const_cast<GtkButtonBox*>(gobj()), const_cast<GtkWidget*>(child.gobj()));
163 int ButtonBox::get_child_min_width() const
165 return gobj()->child_min_width;
168 void ButtonBox::set_child_min_width(const int& value)
170 gobj()->child_min_width = value;
173 int ButtonBox::get_child_min_height() const
175 return gobj()->child_min_height;
178 void ButtonBox::set_child_min_height(const int& value)
180 gobj()->child_min_height = value;
183 int ButtonBox::get_child_ipadding_x() const
185 return gobj()->child_ipad_x;
188 void ButtonBox::set_child_ipadding_x(const int& value)
190 gobj()->child_ipad_x = value;
193 int ButtonBox::get_child_ipadding_y() const
195 return gobj()->child_ipad_y;
198 void ButtonBox::set_child_ipadding_y(const int& value)
200 gobj()->child_ipad_y = value;
204 Glib::PropertyProxy<ButtonBoxStyle> ButtonBox::property_layout_style()
206 return Glib::PropertyProxy<ButtonBoxStyle>(this, "layout-style");
209 Glib::PropertyProxy_ReadOnly<ButtonBoxStyle> ButtonBox::property_layout_style() const
211 return Glib::PropertyProxy_ReadOnly<ButtonBoxStyle>(this, "layout-style");
221 Gtk::VButtonBox* wrap(GtkVButtonBox* object, bool take_copy)
223 return dynamic_cast<Gtk::VButtonBox *> (Glib::wrap_auto ((GObject*)(object), take_copy));
226 } /* namespace Glib */
232 /* The *_Class implementation: */
234 const Glib::Class& VButtonBox_Class::init()
236 if(!gtype_) // create the GType if necessary
238 // Glib::Class has to know the class init function to clone custom types.
239 class_init_func_ = &VButtonBox_Class::class_init_function;
241 // This is actually just optimized away, apparently with no harm.
242 // Make sure that the parent type has been created.
243 //CppClassParent::CppObjectType::get_type();
245 // Create the wrapper type, with the same class/instance size as the base type.
246 register_derived_type(gtk_vbutton_box_get_type());
248 // Add derived versions of interfaces, if the C type implements any interfaces:
254 void VButtonBox_Class::class_init_function(void* g_class, void* class_data)
256 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
257 CppClassParent::class_init_function(klass, class_data);
262 Glib::ObjectBase* VButtonBox_Class::wrap_new(GObject* o)
264 return manage(new VButtonBox((GtkVButtonBox*)(o)));
269 /* The implementation: */
271 VButtonBox::VButtonBox(const Glib::ConstructParams& construct_params)
273 Gtk::ButtonBox(construct_params)
277 VButtonBox::VButtonBox(GtkVButtonBox* castitem)
279 Gtk::ButtonBox((GtkButtonBox*)(castitem))
283 VButtonBox::~VButtonBox()
288 VButtonBox::CppClassType VButtonBox::vbuttonbox_class_; // initialize static member
290 GType VButtonBox::get_type()
292 return vbuttonbox_class_.init().get_type();
295 GType VButtonBox::get_base_type()
297 return gtk_vbutton_box_get_type();
307 Gtk::HButtonBox* wrap(GtkHButtonBox* object, bool take_copy)
309 return dynamic_cast<Gtk::HButtonBox *> (Glib::wrap_auto ((GObject*)(object), take_copy));
312 } /* namespace Glib */
318 /* The *_Class implementation: */
320 const Glib::Class& HButtonBox_Class::init()
322 if(!gtype_) // create the GType if necessary
324 // Glib::Class has to know the class init function to clone custom types.
325 class_init_func_ = &HButtonBox_Class::class_init_function;
327 // This is actually just optimized away, apparently with no harm.
328 // Make sure that the parent type has been created.
329 //CppClassParent::CppObjectType::get_type();
331 // Create the wrapper type, with the same class/instance size as the base type.
332 register_derived_type(gtk_hbutton_box_get_type());
334 // Add derived versions of interfaces, if the C type implements any interfaces:
340 void HButtonBox_Class::class_init_function(void* g_class, void* class_data)
342 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
343 CppClassParent::class_init_function(klass, class_data);
348 Glib::ObjectBase* HButtonBox_Class::wrap_new(GObject* o)
350 return manage(new HButtonBox((GtkHButtonBox*)(o)));
355 /* The implementation: */
357 HButtonBox::HButtonBox(const Glib::ConstructParams& construct_params)
359 Gtk::ButtonBox(construct_params)
363 HButtonBox::HButtonBox(GtkHButtonBox* castitem)
365 Gtk::ButtonBox((GtkButtonBox*)(castitem))
369 HButtonBox::~HButtonBox()
374 HButtonBox::CppClassType HButtonBox::hbuttonbox_class_; // initialize static member
376 GType HButtonBox::get_type()
378 return hbuttonbox_class_.init().get_type();
381 GType HButtonBox::get_base_type()
383 return gtk_hbutton_box_get_type();