// Generated by gtkmmproc -- DO NOT MODIFY! #include #include // -*- c++ -*- /* $Id$ */ /* Copyright 1998-2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public * License along with this library; if not, write to the Free * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include #include #include namespace Gtk { /* Design notes: Okay these are my notes on how a GtkStyle works. They are not meant to be taken as documentation as I didn't write the code. styles keeps a copy of itself for each color depth. Thus changing a style after it has been attached wont work! At allocation time a Gtk Style has - all GC set to 0 as they will be allocated later - has all color values set to default values. - a ref count of 1 and an attach count of 0 (floating?) - a properly referenced font. - colormap and depth are invalid. - The style list and rcstyle are 0. (??? styles wasn't set explicitly!) It returns to this state if the style is detatched from all widgets. Attach acts to sink the object removing it from the floating state. attaching a style for the first time initializes it. Initializing a style - sets the colormap and depth. - sets the mid colors. (thus allowing user to set these would be pointless) - gets black and white from the colormap. - allocates all the colors. - uses gtk_gc_get to share a gc if there is a matching one. Conclusions, we need to rework the concept of Gdk to allow for const objects. */ void Style::set_font(const Pango::FontDescription& font_desc) { g_return_if_fail(font_desc.gobj() != 0); // It will be freed when it goes out of scope. const Pango::FontDescription fontBefore (gobj()->font_desc, false); gobj()->font_desc = font_desc.gobj_copy(); } Pango::FontDescription Style::get_font() const { // Direct struct access seems the only way. return Pango::FontDescription(gobj()->font_desc, true); // true = make a copy. } Glib::RefPtr Style::get_fg_gc(StateType state_type) { return Glib::wrap(gobj()->fg_gc[state_type], true); } Glib::RefPtr Style::get_fg_gc(StateType state_type) const { return Glib::wrap(gobj()->fg_gc[state_type], true); } Glib::RefPtr Style::get_bg_gc(StateType state_type) { return Glib::wrap(gobj()->bg_gc[state_type], true); } Glib::RefPtr Style::get_bg_gc(StateType state_type) const { return Glib::wrap(gobj()->bg_gc[state_type], true); } Glib::RefPtr Style::get_light_gc(StateType state_type) { return Glib::wrap(gobj()->light_gc[state_type], true); } Glib::RefPtr Style::get_light_gc(StateType state_type) const { return Glib::wrap(gobj()->light_gc[state_type], true); } Glib::RefPtr Style::get_dark_gc(StateType state_type) { return Glib::wrap(gobj()->dark_gc[state_type], true); } Glib::RefPtr Style::get_dark_gc(StateType state_type) const { return Glib::wrap(gobj()->dark_gc[state_type], true); } Glib::RefPtr Style::get_mid_gc(StateType state_type) { return Glib::wrap(gobj()->mid_gc[state_type], true); } Glib::RefPtr Style::get_mid_gc(StateType state_type) const { return Glib::wrap(gobj()->mid_gc[state_type], true); } Glib::RefPtr Style::get_text_gc(StateType state_type) { return Glib::wrap(gobj()->text_gc[state_type], true); } Glib::RefPtr Style::get_text_gc(StateType state_type) const { return Glib::wrap(gobj()->text_gc[state_type], true); } Glib::RefPtr Style::get_base_gc(StateType state_type) { return Glib::wrap(gobj()->base_gc[state_type], true); } Glib::RefPtr Style::get_base_gc(StateType state_type) const { return Glib::wrap(gobj()->base_gc[state_type], true); } #ifndef GTKMM_DISABLE_DEPRECATED Gdk::Color Style::get_background(StateType state_type) const { GdkColor* pGdkColor = const_cast(&(gobj()->bg[state_type])); return Glib::wrap(pGdkColor, true); //true = take_copy. } Glib::RefPtr Style::get_background_pixmap(StateType state_type) { return Glib::wrap((GdkPixmapObject*) (gobj()->bg_pixmap[state_type]), true); //true = take_copy. } void Style::set_bg_pixmap(StateType state_type, const Glib::RefPtr& pixmap) { GdkPixmap *const old_pixmap = gobj()->bg_pixmap[state_type]; gobj()->bg_pixmap[state_type] = Glib::unwrap_copy(pixmap); if(old_pixmap) g_object_unref(old_pixmap); } #endif // GTKMM_DISABLE_DEPRECATED void Style::set_bg_pixmap(StateType state_type, const Glib::RefPtr& pixmap) { GdkPixmap *const old_pixmap = gobj()->bg_pixmap[state_type]; Glib::RefPtr pixmap_unconst = Glib::RefPtr::cast_const(pixmap); gobj()->bg_pixmap[state_type] = Glib::unwrap_copy(pixmap_unconst); //unwrap_copy() needs a non-const. if(old_pixmap) g_object_unref(old_pixmap); } Glib::RefPtr Style::get_bg_pixmap(StateType state_type) { return Glib::wrap((GdkPixmapObject*) (gobj()->bg_pixmap[state_type]), true); // true = take_copy } Glib::RefPtr Style::get_bg_pixmap(StateType state_type) const { return Glib::wrap((GdkPixmapObject*) (gobj()->bg_pixmap[state_type]), true); // true = take_copy } void Style::set_xthickness(int xthickness) { gobj()->xthickness = xthickness; } void Style::set_ythickness(int ythickness) { gobj()->ythickness = ythickness; } void Style::paint_polygon(const Glib::RefPtr& window, StateType state_type, ShadowType shadow_type, const Gdk::Rectangle& area, Widget& widget, const Glib::ustring& detail, const Glib::ArrayHandle& points, bool fill) const { gtk_paint_polygon( const_cast(gobj()), Glib::unwrap(window), (GtkStateType) state_type, (GtkShadowType) shadow_type, const_cast(area.gobj()), widget.gobj(), detail.c_str(), reinterpret_cast(const_cast(points.data())), points.size(), fill); } IconSet Style::lookup_icon_set(const Gtk::StockID& stock_id) { GtkIconSet* pIconSet = gtk_style_lookup_icon_set(gobj(), stock_id.get_c_str()); return IconSet(pIconSet, true); //true = take_copy. } } // namespace Gtk namespace { static const Glib::SignalProxyInfo Style_signal_realize_info = { "realize", (GCallback) &Glib::SignalProxyNormal::slot0_void_callback, (GCallback) &Glib::SignalProxyNormal::slot0_void_callback }; static const Glib::SignalProxyInfo Style_signal_unrealize_info = { "unrealize", (GCallback) &Glib::SignalProxyNormal::slot0_void_callback, (GCallback) &Glib::SignalProxyNormal::slot0_void_callback }; } // anonymous namespace namespace Glib { Glib::RefPtr wrap(GtkStyle* object, bool take_copy) { return Glib::RefPtr( dynamic_cast (Glib::wrap_auto ((GObject*)(object), take_copy)) ); //We use dynamic_cast<> in case of multiple inheritance. } } /* namespace Glib */ namespace Gtk { /* The *_Class implementation: */ const Glib::Class& Style_Class::init() { if(!gtype_) // create the GType if necessary { // Glib::Class has to know the class init function to clone custom types. class_init_func_ = &Style_Class::class_init_function; // This is actually just optimized away, apparently with no harm. // Make sure that the parent type has been created. //CppClassParent::CppObjectType::get_type(); // Create the wrapper type, with the same class/instance size as the base type. register_derived_type(gtk_style_get_type()); // Add derived versions of interfaces, if the C type implements any interfaces: } return *this; } void Style_Class::class_init_function(void* g_class, void* class_data) { BaseClassType *const klass = static_cast(g_class); CppClassParent::class_init_function(klass, class_data); #ifdef GLIBMM_VFUNCS_ENABLED klass->realize = &realize_vfunc_callback; klass->unrealize = &unrealize_vfunc_callback; klass->copy = ©_vfunc_callback; klass->clone = &clone_vfunc_callback; klass->init_from_rc = &init_from_rc_vfunc_callback; klass->set_background = &set_background_vfunc_callback; klass->render_icon = &render_icon_vfunc_callback; klass->draw_hline = &draw_hline_vfunc_callback; klass->draw_vline = &draw_vline_vfunc_callback; klass->draw_shadow = &draw_shadow_vfunc_callback; klass->draw_polygon = &draw_polygon_vfunc_callback; klass->draw_arrow = &draw_arrow_vfunc_callback; klass->draw_diamond = &draw_diamond_vfunc_callback; klass->draw_string = &draw_string_vfunc_callback; klass->draw_box = &draw_box_vfunc_callback; klass->draw_flat_box = &draw_flat_box_vfunc_callback; klass->draw_check = &draw_check_vfunc_callback; klass->draw_option = &draw_option_vfunc_callback; klass->draw_tab = &draw_tab_vfunc_callback; klass->draw_shadow_gap = &draw_shadow_gap_vfunc_callback; klass->draw_box_gap = &draw_box_gap_vfunc_callback; klass->draw_extension = &draw_extension_vfunc_callback; klass->draw_focus = &draw_focus_vfunc_callback; klass->draw_slider = &draw_slider_vfunc_callback; klass->draw_handle = &draw_handle_vfunc_callback; klass->draw_expander = &draw_expander_vfunc_callback; klass->draw_layout = &draw_layout_vfunc_callback; klass->draw_resize_grip = &draw_resize_grip_vfunc_callback; #endif //GLIBMM_VFUNCS_ENABLED #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED klass->realize = &realize_callback; klass->unrealize = &unrealize_callback; #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED } #ifdef GLIBMM_VFUNCS_ENABLED void Style_Class::realize_vfunc_callback(GtkStyle* self) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->realize_vfunc(); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->realize) (*base->realize)(self); } } void Style_Class::unrealize_vfunc_callback(GtkStyle* self) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->unrealize_vfunc(); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->unrealize) (*base->unrealize)(self); } } void Style_Class::copy_vfunc_callback(GtkStyle* self, GtkStyle* src) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->copy_vfunc(Glib::wrap(src, true) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->copy) (*base->copy)(self, src); } } GtkStyle* Style_Class::clone_vfunc_callback(GtkStyle* self) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. return Glib::unwrap(obj->clone_vfunc()); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->clone) return (*base->clone)(self); } typedef GtkStyle* RType; return RType(); } void Style_Class::init_from_rc_vfunc_callback(GtkStyle* self, GtkRcStyle* rc_style) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->init_from_rc_vfunc(Glib::wrap(rc_style) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->init_from_rc) (*base->init_from_rc)(self, rc_style); } } void Style_Class::set_background_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->set_background_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->set_background) (*base->set_background)(self, window, state_type); } } GdkPixbuf* Style_Class::render_icon_vfunc_callback(GtkStyle* self, const GtkIconSource* source, GtkTextDirection direction, GtkStateType state, GtkIconSize size, GtkWidget* widget, const gchar* detail) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. return Glib::unwrap(obj->render_icon_vfunc(Glib::wrap(const_cast(source), true) , ((TextDirection)(direction)) , ((Gtk::StateType)(state)) , IconSize(static_cast(size)) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) )); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->render_icon) return (*base->render_icon)(self, source, direction, state, size, widget, detail); } typedef GdkPixbuf* RType; return RType(); } void Style_Class::draw_hline_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x1, gint x2, gint y) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_hline_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x1 , x2 , y ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_hline) (*base->draw_hline)(self, window, state_type, area, widget, detail, x1, x2, y); } } void Style_Class::draw_vline_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint y1, gint y2, gint x) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_vline_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , y1 , y2 , x ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_vline) (*base->draw_vline)(self, window, state_type, area, widget, detail, y1, y2, x); } } void Style_Class::draw_shadow_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_shadow_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_shadow) (*base->draw_shadow)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_polygon_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, GdkPoint* point, gint npoints, gboolean fill) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_polygon_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , point, npoints , fill ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_polygon) (*base->draw_polygon)(self, window, state_type, shadow_type, area, widget, detail, point, npoints, fill); } } void Style_Class::draw_arrow_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, GtkArrowType arrow_type, gboolean fill, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_arrow_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , ((Gtk::ArrowType)(arrow_type)) , fill , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_arrow) (*base->draw_arrow)(self, window, state_type, shadow_type, area, widget, detail, arrow_type, fill, x, y, width, height); } } void Style_Class::draw_diamond_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_diamond_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_diamond) (*base->draw_diamond)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_string_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, const gchar* string) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_string_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , Glib::convert_const_gchar_ptr_to_ustring(string) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_string) (*base->draw_string)(self, window, state_type, area, widget, detail, x, y, string); } } void Style_Class::draw_box_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_box_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_box) (*base->draw_box)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_flat_box_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_flat_box_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_flat_box) (*base->draw_flat_box)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_check_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_check_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_check) (*base->draw_check)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_option_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_option_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_option) (*base->draw_option)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_tab_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_tab_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_tab) (*base->draw_tab)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_shadow_gap_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height, GtkPositionType gap_side, gint gap_x, gint gap_width) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_shadow_gap_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height , ((Gtk::PositionType)(gap_side)) , gap_x , gap_width ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_shadow_gap) (*base->draw_shadow_gap)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height, gap_side, gap_x, gap_width); } } void Style_Class::draw_box_gap_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height, GtkPositionType gap_side, gint gap_x, gint gap_width) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_box_gap_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height , ((Gtk::PositionType)(gap_side)) , gap_x , gap_width ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_box_gap) (*base->draw_box_gap)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height, gap_side, gap_x, gap_width); } } void Style_Class::draw_extension_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height, GtkPositionType gap_side) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_extension_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height , ((PositionType)(gap_side)) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_extension) (*base->draw_extension)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height, gap_side); } } void Style_Class::draw_focus_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_focus_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_focus) (*base->draw_focus)(self, window, state_type, area, widget, detail, x, y, width, height); } } void Style_Class::draw_slider_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height, GtkOrientation orientation) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_slider_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height , ((Orientation)(orientation)) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_slider) (*base->draw_slider)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height, orientation); } } void Style_Class::draw_handle_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GtkShadowType shadow_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, gint width, gint height, GtkOrientation orientation) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_handle_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , ((ShadowType)(shadow_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , width , height , ((Orientation)(orientation)) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_handle) (*base->draw_handle)(self, window, state_type, shadow_type, area, widget, detail, x, y, width, height, orientation); } } void Style_Class::draw_expander_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, GtkExpanderStyle expander_style) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_expander_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , ((ExpanderStyle)(expander_style)) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_expander) (*base->draw_expander)(self, window, state_type, area, widget, detail, x, y, expander_style); } } void Style_Class::draw_layout_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, gboolean use_text, GdkRectangle* area, GtkWidget* widget, const gchar* detail, gint x, gint y, PangoLayout* layout) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_layout_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , use_text , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , x , y , Glib::wrap(layout) ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_layout) (*base->draw_layout)(self, window, state_type, use_text, area, widget, detail, x, y, layout); } } void Style_Class::draw_resize_grip_vfunc_callback(GtkStyle* self, GdkWindow* window, GtkStateType state_type, GdkRectangle* area, GtkWidget* widget, const gchar* detail, GdkWindowEdge edge, gint x, gint y, gint width, gint height) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->draw_resize_grip_vfunc(Glib::wrap((GdkWindowObject*)(window), true) , ((Gtk::StateType)(state_type)) , Glib::wrap(area) , Glib::wrap(widget) , Glib::convert_const_gchar_ptr_to_ustring(detail) , ((Gdk::WindowEdge)(edge)) , x , y , width , height ); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->draw_resize_grip) (*base->draw_resize_grip)(self, window, state_type, area, widget, detail, edge, x, y, width, height); } } #endif //GLIBMM_VFUNCS_ENABLED #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED void Style_Class::realize_callback(GtkStyle* self) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->on_realize(); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->realize) (*base->realize)(self); } } void Style_Class::unrealize_callback(GtkStyle* self) { CppObjectType *const obj = dynamic_cast( Glib::ObjectBase::_get_current_wrapper((GObject*)self)); // Non-gtkmmproc-generated custom classes implicitly call the default // Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc- // generated classes can use this optimisation, which avoids the unnecessary // parameter conversions if there is no possibility of the virtual function // being overridden: if(obj && obj->is_derived_()) { #ifdef GLIBMM_EXCEPTIONS_ENABLED try // Trap C++ exceptions which would normally be lost because this is a C callback. { #endif //GLIBMM_EXCEPTIONS_ENABLED // Call the virtual member method, which derived classes might override. obj->on_unrealize(); #ifdef GLIBMM_EXCEPTIONS_ENABLED } catch(...) { Glib::exception_handlers_invoke(); } #endif //GLIBMM_EXCEPTIONS_ENABLED } else { BaseClassType *const base = static_cast( g_type_class_peek_parent(G_OBJECT_GET_CLASS(self)) // Get the parent class of the object class (The original underlying C class). ); // Call the original underlying C function: if(base && base->unrealize) (*base->unrealize)(self); } } #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED Glib::ObjectBase* Style_Class::wrap_new(GObject* object) { return new Style((GtkStyle*)object); } /* The implementation: */ GtkStyle* Style::gobj_copy() { reference(); return gobj(); } Style::Style(const Glib::ConstructParams& construct_params) : Glib::Object(construct_params) {} Style::Style(GtkStyle* castitem) : Glib::Object((GObject*)(castitem)) {} Style::~Style() {} Style::CppClassType Style::style_class_; // initialize static member GType Style::get_type() { return style_class_.init().get_type(); } GType Style::get_base_type() { return gtk_style_get_type(); } Style::Style() : Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations. Glib::Object(Glib::ConstructParams(style_class_.init())) { } Glib::RefPtr