Karl Felix Schewe
Karl Felix Schewe
Now, that I look at it in more detail I noticed that `Offset` could be reused, or not? The fields are named differently, but it would still be a resize...
Thanks, I'll try my luck with an implementation :)
Maybe: `Rect::offset` -> `Rect::shift` and `layout::Offset` -> `layout::ShiftOffset`?
what about: ```Rust let area = Rect::new(0, 0, 20, 30) .move_by(Offset { x: 0, y: 4 }) .resize_by(SizeAdjustment { width_delta: -5, height_delta: 5, }); ``` `resize_by` was also proposed in...
I think this approach is easier than the one using generics which may be a little bit confusing for beginners. To me it is not that intuitiv to add a...