idek stuff like stack

This commit is contained in:
2025-08-15 22:59:58 -04:00
parent a7dfacb83e
commit f4aef3a983
15 changed files with 138 additions and 42 deletions

View File

@@ -1,4 +1,4 @@
use crate::{Painter, UiColor, Widget, primitive::RoundedRectData};
use crate::{primitive::RoundedRectData, Painter, UiNum, UiColor, Widget};
#[derive(Clone, Copy)]
pub struct Rect {
@@ -21,6 +21,10 @@ impl Rect {
self.color = color;
self
}
pub fn radius(mut self, radius: impl UiNum) -> Self {
self.radius = radius.to_f32();
self
}
}
impl<Ctx> Widget<Ctx> for Rect {