summaryrefslogtreecommitdiffstats
path: root/graphics/src/widget/canvas/path/arc.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-03-01 21:34:26 +0100
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-03-01 21:34:26 +0100
commit5fd5d1cdf8e5354788dc40729c4565ef377d3bba (patch)
tree0921efc7dc13a3050e03482147a791f85515f1f2 /graphics/src/widget/canvas/path/arc.rs
parent3f6e28fa9b1b8d911f765c9efb5249a9e0c942d5 (diff)
downloadiced-5fd5d1cdf8e5354788dc40729c4565ef377d3bba.tar.gz
iced-5fd5d1cdf8e5354788dc40729c4565ef377d3bba.tar.bz2
iced-5fd5d1cdf8e5354788dc40729c4565ef377d3bba.zip
Implement `Canvas` support for `iced_tiny_skia`
Diffstat (limited to 'graphics/src/widget/canvas/path/arc.rs')
-rw-r--r--graphics/src/widget/canvas/path/arc.rs42
1 files changed, 0 insertions, 42 deletions
diff --git a/graphics/src/widget/canvas/path/arc.rs b/graphics/src/widget/canvas/path/arc.rs
deleted file mode 100644
index b8e72daf..00000000
--- a/graphics/src/widget/canvas/path/arc.rs
+++ /dev/null
@@ -1,42 +0,0 @@
-//! Build and draw curves.
-use iced_native::{Point, Vector};
-
-/// A segment of a differentiable curve.
-#[derive(Debug, Clone, Copy)]
-pub struct Arc {
- /// The center of the arc.
- pub center: Point,
- /// The radius of the arc.
- pub radius: f32,
- /// The start of the segment's angle, clockwise rotation.
- pub start_angle: f32,
- /// The end of the segment's angle, clockwise rotation.
- pub end_angle: f32,
-}
-
-/// An elliptical [`Arc`].
-#[derive(Debug, Clone, Copy)]
-pub struct Elliptical {
- /// The center of the arc.
- pub center: Point,
- /// The radii of the arc's ellipse, defining its axes.
- pub radii: Vector,
- /// The rotation of the arc's ellipse.
- pub rotation: f32,
- /// The start of the segment's angle, clockwise rotation.
- pub start_angle: f32,
- /// The end of the segment's angle, clockwise rotation.
- pub end_angle: f32,
-}
-
-impl From<Arc> for Elliptical {
- fn from(arc: Arc) -> Elliptical {
- Elliptical {
- center: arc.center,
- radii: Vector::new(arc.radius, arc.radius),
- rotation: 0.0,
- start_angle: arc.start_angle,
- end_angle: arc.end_angle,
- }
- }
-}