diff options
| -rw-r--r-- | src/layout/tile.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/layout/tile.rs b/src/layout/tile.rs index 0fc64470..87c168b0 100644 --- a/src/layout/tile.rs +++ b/src/layout/tile.rs @@ -351,7 +351,9 @@ impl<W: LayoutElement> Tile<W> { let size_from = resize.size_from; size.w = (size_from.w as f64 + (size.w - size_from.w) as f64 * val).round() as i32; + size.w = max(1, size.w); size.h = (size_from.h as f64 + (size.h - size_from.h) as f64 * val).round() as i32; + size.h = max(1, size.h); } size |
