Type Alias gemini_engine::elements::Box

source ·
pub type Box = Rect;
👎Deprecated: Please use Rect instead

Aliased Type§

struct Box {
    pub pos: Vector2<isize>,
    pub size: Vector2<isize>,
    pub fill_char: ColChar,
    /* private fields */
}

Fields§

§pos: Vector2<isize>§size: Vector2<isize>§fill_char: ColChar

Implementations§

source§

impl Rect

source

pub fn new(pos: Vec2D, size: Vec2D, fill_char: ColChar) -> Self

Trait Implementations§

source§

impl ViewElement for Rect

source§

fn active_pixels(&self) -> Vec<Point>

Return a vector of every coordinate where a pixel should be placed and its respective ColChar. If your whole object is a solid colour, consider using utils::points_to_pixels() which will add the same ColChar to every point and can then be used as this function’s output