gdk4 0.8.2

Rust bindings of the GDK 4 library
Documentation
// This file was generated by gir (https://github.com/gtk-rs/gir)
// from gir-files (https://github.com/gtk-rs/gir-files)
// DO NOT EDIT

use crate::DrawContext;
use glib::translate::*;

glib::wrapper! {
    #[doc(alias = "GdkCairoContext")]
    pub struct CairoContext(Object<ffi::GdkCairoContext>) @extends DrawContext;

    match fn {
        type_ => || ffi::gdk_cairo_context_get_type(),
    }
}

impl CairoContext {
    #[doc(alias = "gdk_cairo_context_cairo_create")]
    pub fn cairo_create(&self) -> Option<cairo::Context> {
        unsafe { from_glib_full(ffi::gdk_cairo_context_cairo_create(self.to_glib_none().0)) }
    }
}