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


#include <glibmm.h>

#include <gdkmm/memorytexturebuilder.h>
#include <gdkmm/private/memorytexturebuilder_p.h>


/* Copyright (C) 2024 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, see <http://www.gnu.org/licenses/>.
 */

#include <gdkmm/cairoutils.h>
#include <gdkmm/value_cairo.h>
#include <gdkmm/colorstate.h>
#include <gdkmm/texture.h>
#include <gdk/gdk.h>

namespace
{
} // anonymous namespace


namespace Glib
{

Glib::RefPtr<Gdk::MemoryTextureBuilder> wrap(GdkMemoryTextureBuilder* object, bool take_copy)
{
  return Glib::make_refptr_for_instance<Gdk::MemoryTextureBuilder>( dynamic_cast<Gdk::MemoryTextureBuilder*> (Glib::wrap_auto ((GObject*)(object), take_copy)) );
  //We use dynamic_cast<> in case of multiple inheritance.
}

} /* namespace Glib */


namespace Gdk
{


/* The *_Class implementation: */

const Glib::Class& MemoryTextureBuilder_Class::init()
{
  if(!gtype_) // create the GType if necessary
  {
    // Do not derive a GType, or use a derived class:
    gtype_ = gdk_memory_texture_builder_get_type();

  }

  return *this;
}


Glib::ObjectBase* MemoryTextureBuilder_Class::wrap_new(GObject* object)
{
  return new MemoryTextureBuilder((GdkMemoryTextureBuilder*)object);
}


/* The implementation: */

GdkMemoryTextureBuilder* MemoryTextureBuilder::gobj_copy()
{
  reference();
  return gobj();
}

MemoryTextureBuilder::MemoryTextureBuilder(const Glib::ConstructParams& construct_params)
:
  Glib::Object(construct_params)
{

}

MemoryTextureBuilder::MemoryTextureBuilder(GdkMemoryTextureBuilder* castitem)
:
  Glib::Object((GObject*)(castitem))
{}


MemoryTextureBuilder::MemoryTextureBuilder(MemoryTextureBuilder&& src) noexcept
: Glib::Object(std::move(src))
{}

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


MemoryTextureBuilder::~MemoryTextureBuilder() noexcept
{}


MemoryTextureBuilder::CppClassType MemoryTextureBuilder::memorytexturebuilder_class_; // initialize static member

GType MemoryTextureBuilder::get_type()
{
  return memorytexturebuilder_class_.init().get_type();
}


GType MemoryTextureBuilder::get_base_type()
{
  return gdk_memory_texture_builder_get_type();
}


MemoryTextureBuilder::MemoryTextureBuilder()
:
  // Mark this class as non-derived to allow C++ vfuncs to be skipped.
  Glib::ObjectBase(nullptr),
  Glib::Object(Glib::ConstructParams(memorytexturebuilder_class_.init()))
{
  

}

Glib::RefPtr<MemoryTextureBuilder> MemoryTextureBuilder::create()
{
  return Glib::make_refptr_for_instance<MemoryTextureBuilder>( new MemoryTextureBuilder() );
}

Glib::RefPtr<Glib::Bytes> MemoryTextureBuilder::get_bytes() const
{
  auto retvalue = Glib::wrap(gdk_memory_texture_builder_get_bytes(const_cast<GdkMemoryTextureBuilder*>(gobj())));
  if(retvalue)
    retvalue->reference(); //The function does not do a ref for us.
  return retvalue;
}

void MemoryTextureBuilder::set_bytes(const Glib::RefPtr<const Glib::Bytes>& context)
{
  gdk_memory_texture_builder_set_bytes(gobj(), const_cast<GBytes*>(Glib::unwrap<Glib::Bytes>(context)));
}

gsize MemoryTextureBuilder::get_stride() const
{
  return gdk_memory_texture_builder_get_stride(const_cast<GdkMemoryTextureBuilder*>(gobj()));
}

void MemoryTextureBuilder::set_stride(gsize stride)
{
  gdk_memory_texture_builder_set_stride(gobj(), stride);
}

gsize MemoryTextureBuilder::get_stride_for_plane(unsigned int plane) const
{
  return gdk_memory_texture_builder_get_stride_for_plane(const_cast<GdkMemoryTextureBuilder*>(gobj()), plane);
}

void MemoryTextureBuilder::set_stride_for_plane(unsigned int plane, gsize stride)
{
  gdk_memory_texture_builder_set_stride_for_plane(gobj(), plane, stride);
}

gsize MemoryTextureBuilder::get_offset(unsigned int plane) const
{
  return gdk_memory_texture_builder_get_offset(const_cast<GdkMemoryTextureBuilder*>(gobj()), plane);
}

void MemoryTextureBuilder::set_offset(unsigned int plane, gsize offset)
{
  gdk_memory_texture_builder_set_offset(gobj(), plane, offset);
}

int MemoryTextureBuilder::get_width() const
{
  return gdk_memory_texture_builder_get_width(const_cast<GdkMemoryTextureBuilder*>(gobj()));
}

void MemoryTextureBuilder::set_width(int width)
{
  gdk_memory_texture_builder_set_width(gobj(), width);
}

int MemoryTextureBuilder::get_height() const
{
  return gdk_memory_texture_builder_get_height(const_cast<GdkMemoryTextureBuilder*>(gobj()));
}

void MemoryTextureBuilder::set_height(int height)
{
  gdk_memory_texture_builder_set_height(gobj(), height);
}

MemoryFormat MemoryTextureBuilder::get_format() const
{
  return static_cast<MemoryFormat>(gdk_memory_texture_builder_get_format(const_cast<GdkMemoryTextureBuilder*>(gobj())));
}

void MemoryTextureBuilder::set_format(MemoryFormat format)
{
  gdk_memory_texture_builder_set_format(gobj(), static_cast<GdkMemoryFormat>(format));
}

Glib::RefPtr<ColorState> MemoryTextureBuilder::get_color_state() const
{
  auto retvalue = Glib::wrap(gdk_memory_texture_builder_get_color_state(const_cast<GdkMemoryTextureBuilder*>(gobj())));
  if(retvalue)
    retvalue->reference(); //The function does not do a ref for us.
  return retvalue;
}

void MemoryTextureBuilder::set_color_state(const Glib::RefPtr<const ColorState>& color_state)
{
  gdk_memory_texture_builder_set_color_state(gobj(), const_cast<GdkColorState*>(Glib::unwrap(color_state)));
}

Glib::RefPtr<Texture> MemoryTextureBuilder::get_update_texture()
{
  auto retvalue = Glib::wrap(gdk_memory_texture_builder_get_update_texture(gobj()));
  if(retvalue)
    retvalue->reference(); //The function does not do a ref for us.
  return retvalue;
}

Glib::RefPtr<const Texture> MemoryTextureBuilder::get_update_texture() const
{
  return const_cast<MemoryTextureBuilder*>(this)->get_update_texture();
}

void MemoryTextureBuilder::set_update_texture(const Glib::RefPtr<Texture>& texture)
{
  gdk_memory_texture_builder_set_update_texture(gobj(), Glib::unwrap(texture));
}

::Cairo::RefPtr< ::Cairo::Region> MemoryTextureBuilder::get_update_region()
{
  auto retvalue = Gdk::Cairo::wrap(gdk_memory_texture_builder_get_update_region(gobj()));
  if(retvalue)
    retvalue->reference(); //The function does not do a ref for us.
  return retvalue;
}

::Cairo::RefPtr<const ::Cairo::Region> MemoryTextureBuilder::get_update_region() const
{
  return const_cast<MemoryTextureBuilder*>(this)->get_update_region();
}

void MemoryTextureBuilder::set_update_region(const ::Cairo::RefPtr< ::Cairo::Region>& region)
{
  gdk_memory_texture_builder_set_update_region(gobj(), ((region) ? (region)->cobj() : nullptr));
}

Glib::RefPtr<Texture> MemoryTextureBuilder::build()
{
  return Glib::wrap(gdk_memory_texture_builder_build(gobj()));
}


static_assert(Glib::Traits::ValueCompatibleWithWrapProperty<Glib::RefPtr<Glib::Bytes>>::value,
  "Type Glib::RefPtr<Glib::Bytes> cannot be used in _WRAP_PROPERTY. "
  "There is no suitable template specialization of Glib::Value<>.");

Glib::PropertyProxy< Glib::RefPtr<Glib::Bytes> > MemoryTextureBuilder::property_bytes() 
{
  return Glib::PropertyProxy< Glib::RefPtr<Glib::Bytes> >(this, "bytes");
}

Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Glib::Bytes> > MemoryTextureBuilder::property_bytes() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Glib::Bytes> >(this, "bytes");
}

static_assert(Glib::Traits::ValueCompatibleWithWrapProperty<Glib::RefPtr<ColorState>>::value,
  "Type Glib::RefPtr<ColorState> cannot be used in _WRAP_PROPERTY. "
  "There is no suitable template specialization of Glib::Value<>.");

Glib::PropertyProxy< Glib::RefPtr<ColorState> > MemoryTextureBuilder::property_color_state() 
{
  return Glib::PropertyProxy< Glib::RefPtr<ColorState> >(this, "color-state");
}

Glib::PropertyProxy_ReadOnly< Glib::RefPtr<ColorState> > MemoryTextureBuilder::property_color_state() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::RefPtr<ColorState> >(this, "color-state");
}

static_assert(Glib::Traits::ValueCompatibleWithWrapProperty<MemoryFormat>::value,
  "Type MemoryFormat cannot be used in _WRAP_PROPERTY. "
  "There is no suitable template specialization of Glib::Value<>.");

Glib::PropertyProxy< MemoryFormat > MemoryTextureBuilder::property_format() 
{
  return Glib::PropertyProxy< MemoryFormat >(this, "format");
}

Glib::PropertyProxy_ReadOnly< MemoryFormat > MemoryTextureBuilder::property_format() const
{
  return Glib::PropertyProxy_ReadOnly< MemoryFormat >(this, "format");
}

Glib::PropertyProxy< int > MemoryTextureBuilder::property_height() 
{
  return Glib::PropertyProxy< int >(this, "height");
}

Glib::PropertyProxy_ReadOnly< int > MemoryTextureBuilder::property_height() const
{
  return Glib::PropertyProxy_ReadOnly< int >(this, "height");
}

static_assert(Glib::Traits::ValueCompatibleWithWrapProperty<gsize>::value,
  "Type gsize cannot be used in _WRAP_PROPERTY. "
  "There is no suitable template specialization of Glib::Value<>.");

Glib::PropertyProxy< gsize > MemoryTextureBuilder::property_stride() 
{
  return Glib::PropertyProxy< gsize >(this, "stride");
}

Glib::PropertyProxy_ReadOnly< gsize > MemoryTextureBuilder::property_stride() const
{
  return Glib::PropertyProxy_ReadOnly< gsize >(this, "stride");
}

static_assert(Glib::Traits::ValueCompatibleWithWrapProperty<::Cairo::RefPtr< ::Cairo::Region>>::value,
  "Type ::Cairo::RefPtr< ::Cairo::Region> cannot be used in _WRAP_PROPERTY. "
  "There is no suitable template specialization of Glib::Value<>.");

Glib::PropertyProxy< ::Cairo::RefPtr< ::Cairo::Region> > MemoryTextureBuilder::property_update_region() 
{
  return Glib::PropertyProxy< ::Cairo::RefPtr< ::Cairo::Region> >(this, "update-region");
}

Glib::PropertyProxy_ReadOnly< ::Cairo::RefPtr< ::Cairo::Region> > MemoryTextureBuilder::property_update_region() const
{
  return Glib::PropertyProxy_ReadOnly< ::Cairo::RefPtr< ::Cairo::Region> >(this, "update-region");
}

static_assert(Glib::Traits::ValueCompatibleWithWrapProperty<Glib::RefPtr<Texture>>::value,
  "Type Glib::RefPtr<Texture> cannot be used in _WRAP_PROPERTY. "
  "There is no suitable template specialization of Glib::Value<>.");

Glib::PropertyProxy< Glib::RefPtr<Texture> > MemoryTextureBuilder::property_update_texture() 
{
  return Glib::PropertyProxy< Glib::RefPtr<Texture> >(this, "update-texture");
}

Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Texture> > MemoryTextureBuilder::property_update_texture() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Texture> >(this, "update-texture");
}

Glib::PropertyProxy< int > MemoryTextureBuilder::property_width() 
{
  return Glib::PropertyProxy< int >(this, "width");
}

Glib::PropertyProxy_ReadOnly< int > MemoryTextureBuilder::property_width() const
{
  return Glib::PropertyProxy_ReadOnly< int >(this, "width");
}


} // namespace Gdk


