// Generated by gmmproc 2.72.1 -- DO NOT MODIFY!


#include <glibmm.h>

#include <gtkmm/editable.h>
#include <gtkmm/private/editable_p.h>


/* 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 Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 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
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
 */

#include <gtk/gtk.h>


namespace
{


static void Editable_signal_insert_text_callback(GtkEditable* self, const char* text,int length,int* position,void* data)
{
  using namespace Gtk;
  using SlotType = sigc::slot<void(const Glib::ustring&, int*)>;

  auto obj = dynamic_cast<Editable*>(Glib::ObjectBase::_get_current_wrapper((GObject*) self));
  // Do not try to call a signal on a disassociated wrapper.
  if(obj)
  {
    try
    {
      if(const auto slot = Glib::SignalProxyNormal::data_to_slot(data))
        (*static_cast<SlotType*>(slot))(      Glib::ustring(text, text + length), position);
    }
    catch(...)
    {
       Glib::exception_handlers_invoke();
    }
  }
}

static const Glib::SignalProxyInfo Editable_signal_insert_text_info =
{
  "insert_text",
  (GCallback) &Editable_signal_insert_text_callback,
  (GCallback) &Editable_signal_insert_text_callback
};


static void Editable_signal_delete_text_callback(GtkEditable* self, gint p0,gint p1,void* data)
{
  using namespace Gtk;
  using SlotType = sigc::slot<void(int, int)>;

  auto obj = dynamic_cast<Editable*>(Glib::ObjectBase::_get_current_wrapper((GObject*) self));
  // Do not try to call a signal on a disassociated wrapper.
  if(obj)
  {
    try
    {
      if(const auto slot = Glib::SignalProxyNormal::data_to_slot(data))
        (*static_cast<SlotType*>(slot))(p0
, p1
);
    }
    catch(...)
    {
       Glib::exception_handlers_invoke();
    }
  }
}

static const Glib::SignalProxyInfo Editable_signal_delete_text_info =
{
  "delete_text",
  (GCallback) &Editable_signal_delete_text_callback,
  (GCallback) &Editable_signal_delete_text_callback
};


static const Glib::SignalProxyInfo Editable_signal_changed_info =
{
  "changed",
  (GCallback) &Glib::SignalProxyNormal::slot0_void_callback,
  (GCallback) &Glib::SignalProxyNormal::slot0_void_callback
};


} // anonymous namespace


namespace Glib
{

Glib::RefPtr<Gtk::Editable> wrap(GtkEditable* object, bool take_copy)
{
  return Glib::make_refptr_for_instance<Gtk::Editable>( dynamic_cast<Gtk::Editable*> (Glib::wrap_auto_interface<Gtk::Editable> ((GObject*)(object), take_copy)) );
  //We use dynamic_cast<> in case of multiple inheritance.
}

} // namespace Glib


namespace Gtk
{


/* The *_Class implementation: */

const Glib::Interface_Class& Editable_Class::init()
{
  if(!gtype_) // create the GType if necessary
  {
    // Glib::Interface_Class has to know the interface init function
    // in order to add interfaces to implementing types.
    class_init_func_ = &Editable_Class::iface_init_function;

    // We can not derive from another interface, and it is not necessary anyway.
    gtype_ = gtk_editable_get_type();
  }

  return *this;
}

void Editable_Class::iface_init_function(void* g_iface, void*)
{
  const auto klass = static_cast<BaseClassType*>(g_iface);

  //This is just to avoid an "unused variable" warning when there are no vfuncs or signal handlers to connect.
  //This is a temporary fix until I find out why I can not seem to derive a GtkFileChooser interface. murrayc
  g_assert(klass != nullptr);

  klass->do_insert_text = &do_insert_text_vfunc_callback;
  klass->do_delete_text = &do_delete_text_vfunc_callback;
  klass->get_text = &get_text_vfunc_callback;
  klass->set_selection_bounds = &set_selection_bounds_vfunc_callback;
  klass->get_selection_bounds = &get_selection_bounds_vfunc_callback;

  klass->insert_text = &insert_text_callback;
  klass->delete_text = &delete_text_callback;
  klass->changed = &changed_callback;
}

void Editable_Class::do_insert_text_vfunc_callback(GtkEditable* self, const char* text, int length, int* position)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        obj->insert_text_vfunc(      Glib::ustring(text, text + length), *position);
        return;
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  BaseClassType *const base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)  );

  // Call the original underlying C function:
  if(base && base->do_insert_text)
    (*base->do_insert_text)(      self, text, length, position);
}
void Editable_Class::do_delete_text_vfunc_callback(GtkEditable* self, int start_pos, int end_pos)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        obj->delete_text_vfunc(start_pos, end_pos);
        return;
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  BaseClassType *const base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)  );

  // Call the original underlying C function:
  if(base && base->do_delete_text)
    (*base->do_delete_text)(self, start_pos, end_pos);
}
const char* Editable_Class::get_text_vfunc_callback(GtkEditable* self)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        static auto quark_return_value = g_quark_from_static_string("Gtk::Editable::get_text_vfunc");

        auto return_value = static_cast<Glib::ustring*>(g_object_get_qdata(obj_base->gobj(), quark_return_value));
        if (!return_value)
        {
          return_value = new Glib::ustring();
          g_object_set_qdata_full(obj_base->gobj(), quark_return_value, return_value,
          &Glib::destroy_notify_delete<Glib::ustring>);
        }
        // Keep a copy of the return value. The caller is not expected
        // to free the object that the returned pointer points to.
        *return_value = obj->get_text_vfunc();
        return ((*return_value)).c_str();
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  BaseClassType *const base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)  );

  // Call the original underlying C function:
  if(base && base->get_text)
    return (*base->get_text)(self);

  using RType = const char*;
  return RType();
}
void Editable_Class::set_selection_bounds_vfunc_callback(GtkEditable* self, int start_pos, int end_pos)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        obj->select_region_vfunc(start_pos, end_pos);
        return;
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  BaseClassType *const base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)  );

  // Call the original underlying C function:
  if(base && base->set_selection_bounds)
    (*base->set_selection_bounds)(self, start_pos, end_pos);
}
gboolean Editable_Class::get_selection_bounds_vfunc_callback(GtkEditable* self, int* start_pos, int* end_pos)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        return static_cast<int>(obj->get_selection_bounds_vfunc(*(start_pos)
, *(end_pos)
));
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  BaseClassType *const base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)  );

  // Call the original underlying C function:
  if(base && base->get_selection_bounds)
    return (*base->get_selection_bounds)(self, start_pos, end_pos);

  using RType = gboolean;
  return RType();
}

void Editable_Class::insert_text_callback(GtkEditable* self, const char* text, int length, int* position)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        obj->on_insert_text(      Glib::ustring(text, text + length), position);
        return;
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  const auto base = static_cast<BaseClassType*>(
        g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)    );

  // Call the original underlying C function:
  if(base && base->insert_text)
    (*base->insert_text)(      self, text, length, position);
}
void Editable_Class::delete_text_callback(GtkEditable* self, gint p0, gint p1)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        obj->on_delete_text(p0
, p1
);
        return;
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  const auto base = static_cast<BaseClassType*>(
        g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)    );

  // Call the original underlying C function:
  if(base && base->delete_text)
    (*base->delete_text)(self, p0, p1);
}
void Editable_Class::changed_callback(GtkEditable* self)
{
  const auto obj_base = static_cast<Glib::ObjectBase*>(
      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_base && obj_base->is_derived_())
  {
    const auto obj = dynamic_cast<CppObjectType* const>(obj_base);
    if(obj) // This can be NULL during destruction.
    {
      try // Trap C++ exceptions which would normally be lost because this is a C callback.
      {
        // Call the virtual member method, which derived classes might override.
        obj->on_changed();
        return;
      }
      catch(...)
      {
        Glib::exception_handlers_invoke();
      }
    }
  }

  const auto base = static_cast<BaseClassType*>(
        g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(self), CppObjectType::get_type()) // Get the interface.
)    );

  // Call the original underlying C function:
  if(base && base->changed)
    (*base->changed)(self);
}


Glib::ObjectBase* Editable_Class::wrap_new(GObject* object)
{
  return new Editable((GtkEditable*)(object));
}


/* The implementation: */

Editable::Editable()
:
  Glib::Interface(editable_class_.init())
{}

Editable::Editable(GtkEditable* castitem)
:
  Glib::Interface((GObject*)(castitem))
{}

Editable::Editable(const Glib::Interface_Class& interface_class)
: Glib::Interface(interface_class)
{
}

Editable::Editable(Editable&& src) noexcept
: Glib::Interface(std::move(src))
{}

Editable& Editable::operator=(Editable&& src) noexcept
{
  Glib::Interface::operator=(std::move(src));
  return *this;
}

Editable::~Editable() noexcept
{}

// static
void Editable::add_interface(GType gtype_implementer)
{
  editable_class_.init().add_interface(gtype_implementer);
}

Editable::CppClassType Editable::editable_class_; // initialize static member

GType Editable::get_type()
{
  return editable_class_.init().get_type();
}


GType Editable::get_base_type()
{
  return gtk_editable_get_type();
}


Glib::ustring Editable::get_text() const
{
  return Glib::convert_const_gchar_ptr_to_ustring(gtk_editable_get_text(const_cast<GtkEditable*>(gobj())));
}

void Editable::set_text(const Glib::ustring& text)
{
  gtk_editable_set_text(gobj(), text.c_str());
}

void Editable::delete_selection()
{
  gtk_editable_delete_selection(gobj());
}

void Editable::set_editable(bool is_editable)
{
  gtk_editable_set_editable(gobj(), static_cast<int>(is_editable));
}

bool Editable::get_editable() const
{
  return gtk_editable_get_editable(const_cast<GtkEditable*>(gobj()));
}

void Editable::insert_text(const Glib::ustring& new_text, int new_text_length, int& position)
{
  gtk_editable_insert_text(gobj(), new_text.c_str(), new_text_length, &(position));
}

void Editable::delete_text(int start_pos, int end_pos)
{
  gtk_editable_delete_text(gobj(), start_pos, end_pos);
}

Glib::ustring Editable::get_chars(int start_pos, int end_pos) const
{
  return Glib::convert_return_gchar_ptr_to_ustring(gtk_editable_get_chars(const_cast<GtkEditable*>(gobj()), start_pos, end_pos));
}

void Editable::select_region(int start_pos, int end_pos)
{
  gtk_editable_select_region(gobj(), start_pos, end_pos);
}

bool Editable::get_selection_bounds(int& start_pos, int& end_pos) const
{
  return gtk_editable_get_selection_bounds(const_cast<GtkEditable*>(gobj()), &(start_pos), &(end_pos));
}

void Editable::set_position(int position)
{
  gtk_editable_set_position(gobj(), position);
}

int Editable::get_position() const
{
  return gtk_editable_get_position(const_cast<GtkEditable*>(gobj()));
}

float Editable::get_alignment() const
{
  return gtk_editable_get_alignment(const_cast<GtkEditable*>(gobj()));
}

void Editable::set_alignment(float xalign)
{
  gtk_editable_set_alignment(gobj(), xalign);
}

int Editable::get_width_chars() const
{
  return gtk_editable_get_width_chars(const_cast<GtkEditable*>(gobj()));
}

void Editable::set_width_chars(int n_chars)
{
  gtk_editable_set_width_chars(gobj(), n_chars);
}

int Editable::get_max_width_chars() const
{
  return gtk_editable_get_max_width_chars(const_cast<GtkEditable*>(gobj()));
}

void Editable::set_max_width_chars(int n_chars)
{
  gtk_editable_set_max_width_chars(gobj(), n_chars);
}

bool Editable::get_enable_undo() const
{
  return gtk_editable_get_enable_undo(const_cast<GtkEditable*>(gobj()));
}

void Editable::set_enable_undo(bool enable_undo)
{
  gtk_editable_set_enable_undo(gobj(), static_cast<int>(enable_undo));
}


Glib::SignalProxy<void(const Glib::ustring&, int*)> Editable::signal_insert_text()
{
  return Glib::SignalProxy<void(const Glib::ustring&, int*) >(this, &Editable_signal_insert_text_info);
}


Glib::SignalProxy<void(int, int)> Editable::signal_delete_text()
{
  return Glib::SignalProxy<void(int, int) >(this, &Editable_signal_delete_text_info);
}


Glib::SignalProxy<void()> Editable::signal_changed()
{
  return Glib::SignalProxy<void() >(this, &Editable_signal_changed_info);
}


Glib::PropertyProxy< Glib::ustring > Editable::property_text() 
{
  return Glib::PropertyProxy< Glib::ustring >(this, "text");
}

Glib::PropertyProxy_ReadOnly< Glib::ustring > Editable::property_text() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::ustring >(this, "text");
}

Glib::PropertyProxy_ReadOnly< int > Editable::property_cursor_position() const
{
  return Glib::PropertyProxy_ReadOnly< int >(this, "cursor-position");
}

Glib::PropertyProxy< bool > Editable::property_enable_undo() 
{
  return Glib::PropertyProxy< bool >(this, "enable-undo");
}

Glib::PropertyProxy_ReadOnly< bool > Editable::property_enable_undo() const
{
  return Glib::PropertyProxy_ReadOnly< bool >(this, "enable-undo");
}

Glib::PropertyProxy_ReadOnly< int > Editable::property_selection_bound() const
{
  return Glib::PropertyProxy_ReadOnly< int >(this, "selection-bound");
}

Glib::PropertyProxy< bool > Editable::property_editable() 
{
  return Glib::PropertyProxy< bool >(this, "editable");
}

Glib::PropertyProxy_ReadOnly< bool > Editable::property_editable() const
{
  return Glib::PropertyProxy_ReadOnly< bool >(this, "editable");
}

Glib::PropertyProxy< int > Editable::property_width_chars() 
{
  return Glib::PropertyProxy< int >(this, "width-chars");
}

Glib::PropertyProxy_ReadOnly< int > Editable::property_width_chars() const
{
  return Glib::PropertyProxy_ReadOnly< int >(this, "width-chars");
}

Glib::PropertyProxy< int > Editable::property_max_width_chars() 
{
  return Glib::PropertyProxy< int >(this, "max-width-chars");
}

Glib::PropertyProxy_ReadOnly< int > Editable::property_max_width_chars() const
{
  return Glib::PropertyProxy_ReadOnly< int >(this, "max-width-chars");
}

Glib::PropertyProxy< float > Editable::property_xalign() 
{
  return Glib::PropertyProxy< float >(this, "xalign");
}

Glib::PropertyProxy_ReadOnly< float > Editable::property_xalign() const
{
  return Glib::PropertyProxy_ReadOnly< float >(this, "xalign");
}


void Gtk::Editable::on_insert_text(const Glib::ustring& text, int* position)
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->insert_text)
    (*base->insert_text)(gobj(),text.data(),text.bytes(),position);
}
void Gtk::Editable::on_delete_text(int start_pos, int end_pos)
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->delete_text)
    (*base->delete_text)(gobj(),start_pos,end_pos);
}
void Gtk::Editable::on_changed()
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->changed)
    (*base->changed)(gobj());
}

void Gtk::Editable::insert_text_vfunc(const Glib::ustring& text, int& position) 
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->do_insert_text)
  {
    (*base->do_insert_text)(gobj(),text.data(),text.bytes(),&position);
  }
}
void Gtk::Editable::delete_text_vfunc(int start_pos, int end_pos) 
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->do_delete_text)
  {
    (*base->do_delete_text)(gobj(),start_pos,end_pos);
  }
}
Glib::ustring Gtk::Editable::get_text_vfunc() const
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->get_text)
  {
    Glib::ustring retval(Glib::convert_const_gchar_ptr_to_ustring((*base->get_text)(const_cast<GtkEditable*>(gobj()))));
    return retval;
  }

  using RType = Glib::ustring;
  return RType();
}
void Gtk::Editable::select_region_vfunc(int start_pos, int end_pos) 
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->set_selection_bounds)
  {
    (*base->set_selection_bounds)(gobj(),start_pos,end_pos);
  }
}
bool Gtk::Editable::get_selection_bounds_vfunc(int& start_pos, int& end_pos) const
{
  const auto base = static_cast<BaseClassType*>(
      g_type_interface_peek_parent( // Get the parent interface of the interface (The original underlying C interface).
g_type_interface_peek(G_OBJECT_GET_CLASS(gobject_), CppObjectType::get_type()) // Get the interface.
)  );

  if(base && base->get_selection_bounds)
  {
    bool retval((*base->get_selection_bounds)(const_cast<GtkEditable*>(gobj()),&(start_pos),&(end_pos)));
    return retval;
  }

  using RType = bool;
  return RType();
}


} // namespace Gtk


