pinetime-lvgl 2.0.1

LVGL Bindings for Mynewt on PineTime Smart Watch
/* automatically generated by rust-bindgen */

use
super::*;

pub type lv_coord_t = i16;
#[doc = " Represents an area of the screen."]
#[repr(C)]
#[derive(Default, Copy, Clone)]
pub struct lv_area_t {
    pub x1: lv_coord_t,
    pub y1: lv_coord_t,
    pub x2: lv_coord_t,
    pub y2: lv_coord_t,
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Initialize an area"]
    #[doc = " - __`area_p`__: pointer to an area"]
    #[doc = " - __`x1`__: left coordinate of the area"]
    #[doc = " - __`y1`__: top coordinate of the area"]
    #[doc = " - __`x2`__: right coordinate of the area"]
    #[doc = " - __`y2`__: bottom coordinate of the area"]
    pub fn lv_area_set(
        area_p: *mut lv_area_t,
        x1: lv_coord_t,
        y1: lv_coord_t,
        x2: lv_coord_t,
        y2: lv_coord_t,
    );
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Copy an area"]
    #[doc = " - __`dest`__: pointer to the destination area"]
    #[doc = " - __`src`__: pointer to the source area"]
    pub fn lv_area_copy(dest: *mut lv_area_t, src: *const lv_area_t);
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Get the width of an area"]
    #[doc = " - __`area_p`__: pointer to an area"]
    #[doc = " Return: the width of the area (if x1 == x2 -> width = 1)"]
    pub fn lv_area_get_width(area_p: *const lv_area_t) -> lv_coord_t;
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Get the height of an area"]
    #[doc = " - __`area_p`__: pointer to an area"]
    #[doc = " Return: the height of the area (if y1 == y2 -> height = 1)"]
    pub fn lv_area_get_height(area_p: *const lv_area_t) -> lv_coord_t;
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Set the width of an area"]
    #[doc = " - __`area_p`__: pointer to an area"]
    #[doc = " - __`w`__: the new width of the area (w == 1 makes x1 == x2)"]
    pub fn lv_area_set_width(area_p: *mut lv_area_t, w: lv_coord_t);
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Set the height of an area"]
    #[doc = " - __`area_p`__: pointer to an area"]
    #[doc = " - __`h`__: the new height of the area (h == 1 makes y1 == y2)"]
    pub fn lv_area_set_height(area_p: *mut lv_area_t, h: lv_coord_t);
}
#[lvgl_macros::safe_wrap(attr)] extern "C" {
    #[doc = " Return with area of an area (x * y)"]
    #[doc = " - __`area_p`__: pointer to an area"]
    #[doc = " Return: size of area"]
    pub fn lv_area_get_size(area_p: *const lv_area_t) -> u32;
}