// This file was generated by the Gtk# code generator.
// Any changes made will be lost if regenerated.

namespace Gtk {

	using System;
	using System.Collections;
	using System.Collections.Generic;
	using System.Runtime.InteropServices;
	using static GLib.AbiStructExtension;

#region Autogenerated code
	public partial class CellAreaBox : Gtk.CellArea, Gtk.ICellLayout, Gtk.IOrientable {

		public CellAreaBox (IntPtr raw) : base(raw) {}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr d_gtk_cell_area_box_new();
		static d_gtk_cell_area_box_new gtk_cell_area_box_new = FuncLoader.LoadFunction<d_gtk_cell_area_box_new>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_area_box_new"));

		public CellAreaBox () : base (IntPtr.Zero)
		{
			if (GetType () != typeof (CellAreaBox)) {
				CreateNativeObject (Array.Empty<string> (), Array.Empty<GLib.Value> ());
				return;
			}
			Raw = gtk_cell_area_box_new();
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int d_gtk_cell_area_box_get_spacing(IntPtr raw);
		static d_gtk_cell_area_box_get_spacing gtk_cell_area_box_get_spacing = FuncLoader.LoadFunction<d_gtk_cell_area_box_get_spacing>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_area_box_get_spacing"));

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_area_box_set_spacing(IntPtr raw, int spacing);
		static d_gtk_cell_area_box_set_spacing gtk_cell_area_box_set_spacing = FuncLoader.LoadFunction<d_gtk_cell_area_box_set_spacing>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_area_box_set_spacing"));

		[GLib.Property ("spacing")]
		public int Spacing {
			get  {
				int raw_ret = gtk_cell_area_box_get_spacing(Handle);
				int ret = raw_ret;
				return ret;
			}
			set  {
				gtk_cell_area_box_set_spacing(Handle, value);
			}
		}

		[GLib.Property ("expand")]
		public bool Expand {
			get {
				GLib.Value val = GetProperty ("expand");
				bool ret = (bool) val;
				val.Dispose ();
				return ret;
			}
			set {
				GLib.Value val = new GLib.Value(value);
				SetProperty("expand", val);
				val.Dispose ();
			}
		}

		[GLib.Property ("align")]
		public bool Align {
			get {
				GLib.Value val = GetProperty ("align");
				bool ret = (bool) val;
				val.Dispose ();
				return ret;
			}
			set {
				GLib.Value val = new GLib.Value(value);
				SetProperty("align", val);
				val.Dispose ();
			}
		}

		[GLib.Property ("fixed-size")]
		public bool FixedSize {
			get {
				GLib.Value val = GetProperty ("fixed-size");
				bool ret = (bool) val;
				val.Dispose ();
				return ret;
			}
			set {
				GLib.Value val = new GLib.Value(value);
				SetProperty("fixed-size", val);
				val.Dispose ();
			}
		}

		[GLib.Property ("pack-type")]
		public Gtk.PackType PackType {
			get {
				GLib.Value val = GetProperty ("pack-type");
				Gtk.PackType ret = (Gtk.PackType) (Enum) val;
				val.Dispose ();
				return ret;
			}
			set {
				GLib.Value val = new GLib.Value((Enum) value);
				SetProperty("pack-type", val);
				val.Dispose ();
			}
		}


		// Internal representation of the wrapped structure ABI.
		static GLib.AbiStruct _class_abi = null;
		static public unsafe new GLib.AbiStruct class_abi {
			get {
				if (_class_abi == null)
					_class_abi = new GLib.AbiStruct (new List<GLib.AbiField>{ 
						new GLib.AbiField("_gtk_reserved1"
							, Gtk.CellArea.class_abi.Fields
							, (uint) sizeof( IntPtr ) // _gtk_reserved1
							, null
							, "_gtk_reserved2"
							, (uint) sizeof(IntPtr)
							, 0
							),
						new GLib.AbiField("_gtk_reserved2"
							, -1
							, (uint) sizeof( IntPtr ) // _gtk_reserved2
							, "_gtk_reserved1"
							, "_gtk_reserved3"
							, (uint) sizeof(IntPtr)
							, 0
							),
						new GLib.AbiField("_gtk_reserved3"
							, -1
							, (uint) sizeof( IntPtr ) // _gtk_reserved3
							, "_gtk_reserved2"
							, "_gtk_reserved4"
							, (uint) sizeof(IntPtr)
							, 0
							),
						new GLib.AbiField("_gtk_reserved4"
							, -1
							, (uint) sizeof( IntPtr ) // _gtk_reserved4
							, "_gtk_reserved3"
							, null
							, (uint) sizeof(IntPtr)
							, 0
							),
					});

				return _class_abi;
			}
		}


		// End of the ABI representation.

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr d_gtk_cell_area_box_get_type();
		static d_gtk_cell_area_box_get_type gtk_cell_area_box_get_type = FuncLoader.LoadFunction<d_gtk_cell_area_box_get_type>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_area_box_get_type"));

		public static new GLib.GType GType { 
			get {
				IntPtr raw_ret = gtk_cell_area_box_get_type();
				GLib.GType ret = new GLib.GType(raw_ret);
				return ret;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_area_box_pack_end(IntPtr raw, IntPtr renderer, bool expand, bool align, bool mfixed);
		static d_gtk_cell_area_box_pack_end gtk_cell_area_box_pack_end = FuncLoader.LoadFunction<d_gtk_cell_area_box_pack_end>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_area_box_pack_end"));

		public void PackEnd(Gtk.CellRenderer renderer, bool expand, bool align, bool mfixed) {
			gtk_cell_area_box_pack_end(Handle, renderer == null ? IntPtr.Zero : renderer.Handle, expand, align, mfixed);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_area_box_pack_start(IntPtr raw, IntPtr renderer, bool expand, bool align, bool mfixed);
		static d_gtk_cell_area_box_pack_start gtk_cell_area_box_pack_start = FuncLoader.LoadFunction<d_gtk_cell_area_box_pack_start>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_area_box_pack_start"));

		public void PackStart(Gtk.CellRenderer renderer, bool expand, bool align, bool mfixed) {
			gtk_cell_area_box_pack_start(Handle, renderer == null ? IntPtr.Zero : renderer.Handle, expand, align, mfixed);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_add_attribute(IntPtr raw, IntPtr cell, IntPtr attribute, int column);
		static d_gtk_cell_layout_add_attribute gtk_cell_layout_add_attribute = FuncLoader.LoadFunction<d_gtk_cell_layout_add_attribute>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_add_attribute"));

		public void AddAttribute(Gtk.CellRenderer cell, string attribute, int column) {
			IntPtr native_attribute = GLib.Marshaller.StringToPtrGStrdup (attribute);
			gtk_cell_layout_add_attribute(Handle, cell == null ? IntPtr.Zero : cell.Handle, native_attribute, column);
			GLib.Marshaller.Free (native_attribute);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_clear(IntPtr raw);
		static d_gtk_cell_layout_clear gtk_cell_layout_clear = FuncLoader.LoadFunction<d_gtk_cell_layout_clear>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_clear"));

		public void Clear() {
			gtk_cell_layout_clear(Handle);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_clear_attributes(IntPtr raw, IntPtr cell);
		static d_gtk_cell_layout_clear_attributes gtk_cell_layout_clear_attributes = FuncLoader.LoadFunction<d_gtk_cell_layout_clear_attributes>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_clear_attributes"));

		public void ClearAttributes(Gtk.CellRenderer cell) {
			gtk_cell_layout_clear_attributes(Handle, cell == null ? IntPtr.Zero : cell.Handle);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr d_gtk_cell_layout_get_area(IntPtr raw);
		static d_gtk_cell_layout_get_area gtk_cell_layout_get_area = FuncLoader.LoadFunction<d_gtk_cell_layout_get_area>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_get_area"));

		public Gtk.CellArea Area { 
			get {
				IntPtr raw_ret = gtk_cell_layout_get_area(Handle);
				Gtk.CellArea ret = GLib.Object.GetObject(raw_ret) as Gtk.CellArea;
				return ret;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr d_gtk_cell_layout_get_cells(IntPtr raw);
		static d_gtk_cell_layout_get_cells gtk_cell_layout_get_cells = FuncLoader.LoadFunction<d_gtk_cell_layout_get_cells>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_get_cells"));

		public Gtk.CellRenderer[] Cells { 
			get {
				IntPtr raw_ret = gtk_cell_layout_get_cells(Handle);
				Gtk.CellRenderer[] ret = GLib.Marshaller.ListPtrToArray<Gtk.CellRenderer, Gtk.CellRenderer> (raw_ret, true, false);
				return ret;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_pack_end(IntPtr raw, IntPtr cell, bool expand);
		static d_gtk_cell_layout_pack_end gtk_cell_layout_pack_end = FuncLoader.LoadFunction<d_gtk_cell_layout_pack_end>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_pack_end"));

		public void PackEnd(Gtk.CellRenderer cell, bool expand) {
			gtk_cell_layout_pack_end(Handle, cell == null ? IntPtr.Zero : cell.Handle, expand);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_pack_start(IntPtr raw, IntPtr cell, bool expand);
		static d_gtk_cell_layout_pack_start gtk_cell_layout_pack_start = FuncLoader.LoadFunction<d_gtk_cell_layout_pack_start>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_pack_start"));

		public void PackStart(Gtk.CellRenderer cell, bool expand) {
			gtk_cell_layout_pack_start(Handle, cell == null ? IntPtr.Zero : cell.Handle, expand);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_reorder(IntPtr raw, IntPtr cell, int position);
		static d_gtk_cell_layout_reorder gtk_cell_layout_reorder = FuncLoader.LoadFunction<d_gtk_cell_layout_reorder>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_reorder"));

		public void Reorder(Gtk.CellRenderer cell, int position) {
			gtk_cell_layout_reorder(Handle, cell == null ? IntPtr.Zero : cell.Handle, position);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_cell_layout_set_cell_data_func(IntPtr raw, IntPtr cell, GtkSharp.CellLayoutDataFuncNative func, IntPtr func_data, GLib.DestroyNotify destroy);
		static d_gtk_cell_layout_set_cell_data_func gtk_cell_layout_set_cell_data_func = FuncLoader.LoadFunction<d_gtk_cell_layout_set_cell_data_func>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_cell_layout_set_cell_data_func"));

		public void SetCellDataFunc(Gtk.CellRenderer cell, Gtk.CellLayoutDataFunc func) {
			GtkSharp.CellLayoutDataFuncWrapper func_wrapper = new GtkSharp.CellLayoutDataFuncWrapper (func);
			IntPtr func_data;
			GLib.DestroyNotify destroy;
			if (func == null) {
				func_data = IntPtr.Zero;
				destroy = null;
			} else {
				func_data = (IntPtr) GCHandle.Alloc (func_wrapper);
				destroy = GLib.DestroyHelper.NotifyHandler;
			}
			gtk_cell_layout_set_cell_data_func(Handle, cell == null ? IntPtr.Zero : cell.Handle, func_wrapper.NativeDelegate, func_data, destroy);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int d_gtk_orientable_get_orientation(IntPtr raw);
		static d_gtk_orientable_get_orientation gtk_orientable_get_orientation = FuncLoader.LoadFunction<d_gtk_orientable_get_orientation>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_orientable_get_orientation"));

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void d_gtk_orientable_set_orientation(IntPtr raw, int orientation);
		static d_gtk_orientable_set_orientation gtk_orientable_set_orientation = FuncLoader.LoadFunction<d_gtk_orientable_set_orientation>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_orientable_set_orientation"));

		[GLib.Property ("orientation")]
		public Gtk.Orientation Orientation {
			get  {
				int raw_ret = gtk_orientable_get_orientation(Handle);
				Gtk.Orientation ret = (Gtk.Orientation) raw_ret;
				return ret;
			}
			set  {
				gtk_orientable_set_orientation(Handle, (int) value);
			}
		}


		// Internal representation of the wrapped structure ABI.
		static GLib.AbiStruct _abi_info = null;
		static public unsafe new GLib.AbiStruct abi_info {
			get {
				if (_abi_info == null)
					_abi_info = new GLib.AbiStruct (new List<GLib.AbiField>{ 
						new GLib.AbiField("priv"
							, Gtk.CellArea.abi_info.Fields
							, (uint) sizeof( IntPtr ) // priv
							, null
							, null
							, (uint) sizeof(IntPtr)
							, 0
							),
					});

				return _abi_info;
			}
		}


		// End of the ABI representation.

#endregion
	}
}
