mirui 0.1.5

A lightweight, no_std ECS-driven UI framework for embedded, desktop, and WebAssembly
Documentation
use crate::types::{Color, Opa, Point, Rect};

pub enum DrawCommand<'a> {
    Fill {
        area: Rect,
        color: Color,
        radius: u16,
        opa: Opa,
    },
    Border {
        area: Rect,
        color: Color,
        width: u16,
        radius: u16,
        opa: Opa,
    },
    Label {
        pos: Point,
        text: &'a [u8],
        color: Color,
        opa: Opa,
    },
    Line {
        p1: Point,
        p2: Point,
        color: Color,
        width: u16,
        opa: Opa,
    },
    Arc {
        center: Point,
        radius: u16,
        start_angle: u16,
        end_angle: u16,
        color: Color,
        width: u16,
        opa: Opa,
    },
    Blit {
        pos: Point,
        data: &'a [u8], // RGBA
        width: u16,
        height: u16,
    },
}