stack & padding fix sorta, preparing for scroll areas

This commit is contained in:
iris committed 2025-09-25 19:59:18 -04:00
1 parent 273a92d1f7
commit 6d829dbe81
10 files changed
+151 -45

No files matched your search

+3 -3
View File
@@ -100,9 +100,7 @@ impl UiVec2 {
self.rel * size + self.abs
}
pub const fn max_size() -> Self {
Self::rel(Vec2::ONE)
}
pub const MAX_SIZE: Self = Self::rel(Vec2::ONE);
pub const fn from_axis(axis: Axis, aligned: UiScalar, ortho: UiScalar) -> Self {
Self {
@@ -134,6 +132,8 @@ impl_op!(UiScalar Add add; rel abs);
impl_op!(UiScalar Sub sub; rel abs);
impl UiScalar {
pub const ZERO: Self = Self { rel: 0.0, abs: 0.0 };
pub fn new(rel: f32, abs: f32) -> Self {
Self { rel, abs }
}