summaryrefslogtreecommitdiffstats
path: root/native/src/layout/limits.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--native/src/layout/limits.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/native/src/layout/limits.rs b/native/src/layout/limits.rs
index 137a054c..5d3c1556 100644
--- a/native/src/layout/limits.rs
+++ b/native/src/layout/limits.rs
@@ -114,10 +114,7 @@ impl Limits {
/// Shrinks the current [`Limits`] to account for the given padding.
pub fn pad(&self, padding: Padding) -> Limits {
- self.shrink(Size::new(
- padding.horizontal() as f32,
- padding.vertical() as f32,
- ))
+ self.shrink(Size::new(padding.horizontal(), padding.vertical()))
}
/// Shrinks the current [`Limits`] by the given [`Size`].