pub trait PixbufAnimationExt: IsA<PixbufAnimation> + 'static {
// Provided methods
fn height(&self) -> i32 { ... }
fn static_image(&self) -> Option<Pixbuf> { ... }
fn width(&self) -> i32 { ... }
fn is_static_image(&self) -> bool { ... }
}Expand description
Trait containing all PixbufAnimation methods.
§Implementors
Provided Methods§
Sourcefn static_image(&self) -> Option<Pixbuf>
👎Deprecated: Since 2.44
fn static_image(&self) -> Option<Pixbuf>
Retrieves a static image for the animation.
If an animation is really just a plain image (has only one frame), this function returns that image.
If the animation is an animation, this function returns a reasonable image to use as a static unanimated image, which might be the first frame, or something more sophisticated depending on the file format.
If an animation hasn’t loaded any frames yet, this function will
return NULL.
§Deprecated since 2.44
Use a different image loading library for animatable assets
§Returns
unanimated image representing the animation
Sourcefn is_static_image(&self) -> bool
👎Deprecated: Since 2.44
fn is_static_image(&self) -> bool
Checks whether the animation is a static image.
If you load a file with gdk_pixbuf_animation_new_from_file() and it
turns out to be a plain, unanimated image, then this function will
return TRUE. Use gdk_pixbuf_animation_get_static_image() to retrieve
the image.
§Deprecated since 2.44
Use a different image loading library for animatable assets
§Returns
TRUE if the “animation” was really just an image
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.