mirror of
https://codeberg.org/unspeaker/tengri.git
synced 2026-01-11 10:36:41 +01:00
15 lines
465 B
Rust
15 lines
465 B
Rust
#[allow(unused)] use crate::*;
|
|
|
|
pub struct Foreground<Color, Item>(pub Color, pub Item);
|
|
impl<O: Out, Color, Item: Layout<O>> Layout<O> for Foreground<Color, Item> {
|
|
fn layout (&self, to: O::Area) -> O::Area {
|
|
self.1.layout(to)
|
|
}
|
|
}
|
|
|
|
pub struct Background<Color, Item>(pub Color, pub Item);
|
|
impl<O: Out, Color, Item: Layout<O>> Layout<O> for Background<Color, Item> {
|
|
fn layout (&self, to: O::Area) -> O::Area {
|
|
self.1.layout(to)
|
|
}
|
|
}
|