add Measure::of

This commit is contained in:
🪞👃🪞 2025-01-02 14:11:32 +01:00
parent 6b073988c2
commit 5b57f2b998
4 changed files with 21 additions and 54 deletions

View file

@ -65,6 +65,9 @@ impl<E: Engine> Measure<E> {
y: Arc::new(0.into()),
}
}
pub fn of <T: Content<E>> (&self, item: T) -> Bsp<E, Fill<E, &Self>, T> {
Bsp::b(Fill::xy(&self), item)
}
}
///// A scrollable area.