1 // Generated by gtkmmproc -- DO NOT MODIFY!
4 #include <gtkmm/scrollbar.h>
5 #include <gtkmm/private/scrollbar_p.h>
12 * Copyright 1998-2002 The gtkmm Development Team
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.
29 #include <gtkmm/adjustment.h>
31 #include <gtk/gtkscrollbar.h>
32 #include <gtk/gtkhscrollbar.h>
33 #include <gtk/gtkvscrollbar.h>
38 VScrollbar::VScrollbar(Adjustment& adjustment)
40 // Mark this class as non-derived to allow C++ vfuncs to be skipped.
42 Scrollbar(Glib::ConstructParams(vscrollbar_class_.init()))
44 set_adjustment(adjustment);
47 VScrollbar::VScrollbar()
49 // Mark this class as non-derived to allow C++ vfuncs to be skipped.
51 Scrollbar(Glib::ConstructParams(vscrollbar_class_.init()))
53 Adjustment* adjustment = manage(new Adjustment(0.0, 0.0, 0.0, 0.0, 0.0, 0.0));
55 // The adjustment will be destroyed along with the object
56 set_adjustment(*adjustment);
60 HScrollbar::HScrollbar()
62 // Mark this class as non-derived to allow C++ vfuncs to be skipped.
64 Scrollbar(Glib::ConstructParams(hscrollbar_class_.init()))
66 Adjustment* adjustment = manage(new Adjustment(0.0, 0.0, 0.0, 0.0, 0.0, 0.0));
68 // The adjustment will be destroyed along with the object
69 set_adjustment(*adjustment);
72 HScrollbar::HScrollbar(Adjustment& adjustment)
74 // Mark this class as non-derived to allow C++ vfuncs to be skipped.
76 Scrollbar(Glib::ConstructParams(hscrollbar_class_.init()))
78 set_adjustment(adjustment);
86 } // anonymous namespace
92 Gtk::Scrollbar* wrap(GtkScrollbar* object, bool take_copy)
94 return dynamic_cast<Gtk::Scrollbar *> (Glib::wrap_auto ((GObject*)(object), take_copy));
97 } /* namespace Glib */
103 /* The *_Class implementation: */
105 const Glib::Class& Scrollbar_Class::init()
107 if(!gtype_) // create the GType if necessary
109 // Glib::Class has to know the class init function to clone custom types.
110 class_init_func_ = &Scrollbar_Class::class_init_function;
112 // This is actually just optimized away, apparently with no harm.
113 // Make sure that the parent type has been created.
114 //CppClassParent::CppObjectType::get_type();
116 // Create the wrapper type, with the same class/instance size as the base type.
117 register_derived_type(gtk_scrollbar_get_type());
119 // Add derived versions of interfaces, if the C type implements any interfaces:
125 void Scrollbar_Class::class_init_function(void* g_class, void* class_data)
127 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
128 CppClassParent::class_init_function(klass, class_data);
130 #ifdef GLIBMM_VFUNCS_ENABLED
131 #endif //GLIBMM_VFUNCS_ENABLED
133 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
134 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
137 #ifdef GLIBMM_VFUNCS_ENABLED
138 #endif //GLIBMM_VFUNCS_ENABLED
140 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
141 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
144 Glib::ObjectBase* Scrollbar_Class::wrap_new(GObject* o)
146 return manage(new Scrollbar((GtkScrollbar*)(o)));
151 /* The implementation: */
153 Scrollbar::Scrollbar(const Glib::ConstructParams& construct_params)
155 Gtk::Range(construct_params)
159 Scrollbar::Scrollbar(GtkScrollbar* castitem)
161 Gtk::Range((GtkRange*)(castitem))
165 Scrollbar::~Scrollbar()
170 Scrollbar::CppClassType Scrollbar::scrollbar_class_; // initialize static member
172 GType Scrollbar::get_type()
174 return scrollbar_class_.init().get_type();
177 GType Scrollbar::get_base_type()
179 return gtk_scrollbar_get_type();
183 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
184 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
186 #ifdef GLIBMM_VFUNCS_ENABLED
187 #endif //GLIBMM_VFUNCS_ENABLED
196 Gtk::VScrollbar* wrap(GtkVScrollbar* object, bool take_copy)
198 return dynamic_cast<Gtk::VScrollbar *> (Glib::wrap_auto ((GObject*)(object), take_copy));
201 } /* namespace Glib */
207 /* The *_Class implementation: */
209 const Glib::Class& VScrollbar_Class::init()
211 if(!gtype_) // create the GType if necessary
213 // Glib::Class has to know the class init function to clone custom types.
214 class_init_func_ = &VScrollbar_Class::class_init_function;
216 // This is actually just optimized away, apparently with no harm.
217 // Make sure that the parent type has been created.
218 //CppClassParent::CppObjectType::get_type();
220 // Create the wrapper type, with the same class/instance size as the base type.
221 register_derived_type(gtk_vscrollbar_get_type());
223 // Add derived versions of interfaces, if the C type implements any interfaces:
229 void VScrollbar_Class::class_init_function(void* g_class, void* class_data)
231 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
232 CppClassParent::class_init_function(klass, class_data);
234 #ifdef GLIBMM_VFUNCS_ENABLED
235 #endif //GLIBMM_VFUNCS_ENABLED
237 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
238 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
241 #ifdef GLIBMM_VFUNCS_ENABLED
242 #endif //GLIBMM_VFUNCS_ENABLED
244 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
245 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
248 Glib::ObjectBase* VScrollbar_Class::wrap_new(GObject* o)
250 return manage(new VScrollbar((GtkVScrollbar*)(o)));
255 /* The implementation: */
257 VScrollbar::VScrollbar(const Glib::ConstructParams& construct_params)
259 Gtk::Scrollbar(construct_params)
263 VScrollbar::VScrollbar(GtkVScrollbar* castitem)
265 Gtk::Scrollbar((GtkScrollbar*)(castitem))
269 VScrollbar::~VScrollbar()
274 VScrollbar::CppClassType VScrollbar::vscrollbar_class_; // initialize static member
276 GType VScrollbar::get_type()
278 return vscrollbar_class_.init().get_type();
281 GType VScrollbar::get_base_type()
283 return gtk_vscrollbar_get_type();
287 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
288 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
290 #ifdef GLIBMM_VFUNCS_ENABLED
291 #endif //GLIBMM_VFUNCS_ENABLED
300 Gtk::HScrollbar* wrap(GtkHScrollbar* object, bool take_copy)
302 return dynamic_cast<Gtk::HScrollbar *> (Glib::wrap_auto ((GObject*)(object), take_copy));
305 } /* namespace Glib */
311 /* The *_Class implementation: */
313 const Glib::Class& HScrollbar_Class::init()
315 if(!gtype_) // create the GType if necessary
317 // Glib::Class has to know the class init function to clone custom types.
318 class_init_func_ = &HScrollbar_Class::class_init_function;
320 // This is actually just optimized away, apparently with no harm.
321 // Make sure that the parent type has been created.
322 //CppClassParent::CppObjectType::get_type();
324 // Create the wrapper type, with the same class/instance size as the base type.
325 register_derived_type(gtk_hscrollbar_get_type());
327 // Add derived versions of interfaces, if the C type implements any interfaces:
333 void HScrollbar_Class::class_init_function(void* g_class, void* class_data)
335 BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
336 CppClassParent::class_init_function(klass, class_data);
338 #ifdef GLIBMM_VFUNCS_ENABLED
339 #endif //GLIBMM_VFUNCS_ENABLED
341 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
342 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
345 #ifdef GLIBMM_VFUNCS_ENABLED
346 #endif //GLIBMM_VFUNCS_ENABLED
348 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
349 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
352 Glib::ObjectBase* HScrollbar_Class::wrap_new(GObject* o)
354 return manage(new HScrollbar((GtkHScrollbar*)(o)));
359 /* The implementation: */
361 HScrollbar::HScrollbar(const Glib::ConstructParams& construct_params)
363 Gtk::Scrollbar(construct_params)
367 HScrollbar::HScrollbar(GtkHScrollbar* castitem)
369 Gtk::Scrollbar((GtkScrollbar*)(castitem))
373 HScrollbar::~HScrollbar()
378 HScrollbar::CppClassType HScrollbar::hscrollbar_class_; // initialize static member
380 GType HScrollbar::get_type()
382 return hscrollbar_class_.init().get_type();
385 GType HScrollbar::get_base_type()
387 return gtk_hscrollbar_get_type();
391 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
392 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
394 #ifdef GLIBMM_VFUNCS_ENABLED
395 #endif //GLIBMM_VFUNCS_ENABLED