gdk/gdk.go
func PixbufNew(colorspace Colorspace, hasAlpha bool, bitsPerSample, width, height int) (*Pixbuf, error) {
	c := C.gdk_pixbuf_new(C.GdkColorspace(colorspace), gbool(hasAlpha),
		C.int(bitsPerSample), C.int(width), C.int(height))
	if c == nil {
		return nil, nilPtrErr
	}

	obj := &glib.Object{glib.ToGObject(unsafe.Pointer(c))}
	p := &Pixbuf{obj}
	//obj.Ref()
	runtime.SetFinalizer(p, func(_ interface{}) { obj.Unref() })
	return p, nil
}
func PixbufNew(colorspace Colorspace, hasAlpha bool, bitsPerSample, width, height int) (*Pixbuf, error) {
	c := C.gdk_pixbuf_new(C.GdkColorspace(colorspace), gbool(hasAlpha),
		C.int(bitsPerSample), C.int(width), C.int(height))
	if c == nil {
		return nil, nilPtrErr
	}

	obj := &glib.Object{glib.ToGObject(unsafe.Pointer(c))}
	p := &Pixbuf{obj}
	//obj.Ref()
	runtime.SetFinalizer(p, func(_ interface{}) { obj.Unref() })
	return p, nil
}
func PixbufNew ( colorspace Colorspace , hasAlpha bool , bitsPerSample , width , height int ) ( * Pixbuf , error ) { c := C . gdk_pixbuf_new ( C . GdkColorspace ( colorspace ) , gbool ( hasAlpha ) , C . int ( bitsPerSample ) , C . int ( width ) , C . int ( height ) ) if c == nil { return nil , nilPtrErr } obj := & glib . Object { glib . ToGObject ( unsafe . Pointer ( c ) ) } p := & Pixbuf { obj } //obj.Ref() runtime . SetFinalizer ( p , func ( _ interface { } ) { obj . Unref ( ) } ) return p , nil }
// PixbufNew is a wrapper around gdk_pixbuf_new().
PixbufNew is a wrapper around gdk_pixbuf_new () .