Render colored quads

This commit is contained in:
Héctor Ramón Jiménez 2019-10-07 03:56:16 +02:00
parent 70c17b053b
commit c9510db551
13 changed files with 396 additions and 6 deletions

View file

@ -18,14 +18,16 @@ impl button::Renderer for Renderer {
layout: Layout<'_>,
_cursor_position: Point,
) -> Self::Primitive {
let bounds = layout.bounds();
Primitive::Group {
primitives: vec![
Primitive::Quad {
bounds: layout.bounds(),
bounds,
background: Background::Color(Color {
r: 0.0,
b: 1.0,
g: 0.0,
r: 0.8,
b: 0.8,
g: 0.8,
a: 1.0,
}),
},