pub trait Composition<B: Backend> {
    // Required methods
    fn new(background_color: Color) -> Self;
    fn clear(&mut self);
    fn insert(&mut self, order: Order, layer: Layer<B>);
    fn remove(&mut self, order: Order);
}
Expand description

A group of ordered layers.

Required Methods§

source

fn new(background_color: Color) -> Self

Creates a composition of ordered layers where the layers with lower index appear on top.

source

fn clear(&mut self)

Resets composition by removing all layers.

source

fn insert(&mut self, order: Order, layer: Layer<B>)

Inserts layer into the composition.

source

fn remove(&mut self, order: Order)

Removes layer from the composition.

Object Safety§

This trait is not object safe.

Implementors§