// Package gdkpixbuf was automatically generated by github.com/bnema/puregotk DO NOT EDIT package gdkpixbuf import ( "github.com/bnema/puregotk/v4/glib" "github.com/bnema/puregotk/v4/gobject/types" ) // A function of this type is responsible for freeing the pixel array // of a pixbuf. // // The gdk_pixbuf_new_from_data() function lets you pass in a pre-allocated // pixel array so that a pixbuf can be created from it; in this case you // will need to pass in a function of type `GdkPixbufDestroyNotify` so that // the pixel data can be freed when the pixbuf is finalized. type PixbufDestroyNotify func([]byte, uintptr) // Save functions used by [method@GdkPixbuf.Pixbuf.save_to_callback]. // // This function is called once for each block of bytes that is "written" // by `gdk_pixbuf_save_to_callback()`. // // If successful it should return `TRUE`; if an error occurs it should set // `error` and return `FALSE`, in which case `gdk_pixbuf_save_to_callback()` // will fail with the same error. type PixbufSaveFunc func([]byte, uint, **glib.Error, uintptr) bool // This enumeration defines the color spaces that are supported by // the gdk-pixbuf library. // // Currently only RGB is supported. type Colorspace int var xColorspaceGLibType func() types.GType func ColorspaceGLibType() types.GType { return xColorspaceGLibType() } const ( // Indicates a red/green/blue additive color space. GdkColorspaceRgbValue Colorspace = 0 ) // Control the alpha channel for drawables. // // These values can be passed to gdk_pixbuf_xlib_render_to_drawable_alpha() // in gdk-pixbuf-xlib to control how the alpha channel of an image should // be handled. // // This function can create a bilevel clipping mask (black and white) and use // it while painting the image. // // In the future, when the X Window System gets an alpha channel extension, // it will be possible to do full alpha compositing onto arbitrary drawables. // For now both cases fall back to a bilevel clipping mask. type PixbufAlphaMode int var xPixbufAlphaModeGLibType func() types.GType func PixbufAlphaModeGLibType() types.GType { return xPixbufAlphaModeGLibType() } const ( // A bilevel clipping mask (black and white) // will be created and used to draw the image. Pixels below 0.5 opacity // will be considered fully transparent, and all others will be // considered fully opaque. GdkPixbufAlphaBilevelValue PixbufAlphaMode = 0 // For now falls back to #GDK_PIXBUF_ALPHA_BILEVEL. // In the future it will do full alpha compositing. GdkPixbufAlphaFullValue PixbufAlphaMode = 1 ) // An error code in the `GDK_PIXBUF_ERROR` domain. // // Many gdk-pixbuf operations can cause errors in this domain, or in // the `G_FILE_ERROR` domain. type PixbufError int var xPixbufErrorGLibType func() types.GType func PixbufErrorGLibType() types.GType { return xPixbufErrorGLibType() } const ( // An image file was broken somehow. GdkPixbufErrorCorruptImageValue PixbufError = 0 // Not enough memory. GdkPixbufErrorInsufficientMemoryValue PixbufError = 1 // A bad option was passed to a pixbuf save module. GdkPixbufErrorBadOptionValue PixbufError = 2 // Unknown image type. GdkPixbufErrorUnknownTypeValue PixbufError = 3 // Don't know how to perform the // given operation on the type of image at hand. GdkPixbufErrorUnsupportedOperationValue PixbufError = 4 // Generic failure code, something went wrong. GdkPixbufErrorFailedValue PixbufError = 5 // Only part of the animation was loaded. GdkPixbufErrorIncompleteAnimationValue PixbufError = 6 )