diff options
| author | Laurenz <laurmaedje@gmail.com> | 2020-11-20 16:36:22 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2020-11-20 16:36:22 +0100 |
| commit | f105663037c44740b5aa02dea72a9b368bc003e0 (patch) | |
| tree | ee97638bfba2be3cfba8c1191919447262f181d0 /src/geom | |
| parent | 2e6e6244ccf73795d7d74cbc286fb0b43b404315 (diff) | |
Basic image support 🖼
- [image] function
- Image rendering in tests
- Supports JPEG and PNG
- No PDF export so far
Diffstat (limited to 'src/geom')
| -rw-r--r-- | src/geom/length.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/geom/length.rs b/src/geom/length.rs index 60ccce2b..061510a1 100644 --- a/src/geom/length.rs +++ b/src/geom/length.rs @@ -142,6 +142,14 @@ impl Div<f64> for Length { } } +impl Div for Length { + type Output = f64; + + fn div(self, other: Self) -> f64 { + self.raw / other.raw + } +} + assign_impl!(Length += Length); assign_impl!(Length -= Length); assign_impl!(Length *= f64); |
