summaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-02-03 17:19:48 +0700
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-02-03 17:19:48 +0700
commitbace264bfe5e3cb5046867bd411e54969a637c79 (patch)
tree6022a8950db589b14eebd8d0242cd802a4b2fa72 /graphics
parentf56c8a7361ceb215bce68e88bd6ce402e2694693 (diff)
downloadiced-bace264bfe5e3cb5046867bd411e54969a637c79.tar.gz
iced-bace264bfe5e3cb5046867bd411e54969a637c79.tar.bz2
iced-bace264bfe5e3cb5046867bd411e54969a637c79.zip
Access `lyon_algorithms` indirectly through `lyon`
Diffstat (limited to 'graphics')
-rw-r--r--graphics/Cargo.toml6
-rw-r--r--graphics/src/widget/canvas/path.rs4
2 files changed, 3 insertions, 7 deletions
diff --git a/graphics/Cargo.toml b/graphics/Cargo.toml
index 07a19807..12f38cce 100644
--- a/graphics/Cargo.toml
+++ b/graphics/Cargo.toml
@@ -11,7 +11,7 @@ keywords = ["gui", "ui", "graphics", "interface", "widgets"]
categories = ["gui"]
[features]
-canvas = ["lyon", "lyon_algorithms"]
+canvas = ["lyon"]
qr_code = ["qrcode", "canvas"]
font-source = ["font-kit"]
font-fallback = []
@@ -39,10 +39,6 @@ path = "../style"
version = "0.17"
optional = true
-[dependencies.lyon_algorithms]
-version = "0.17"
-optional = true
-
[dependencies.qrcode]
version = "0.12"
optional = true
diff --git a/graphics/src/widget/canvas/path.rs b/graphics/src/widget/canvas/path.rs
index cb7e5035..1728f060 100644
--- a/graphics/src/widget/canvas/path.rs
+++ b/graphics/src/widget/canvas/path.rs
@@ -10,8 +10,8 @@ pub use builder::Builder;
use crate::canvas::LineDash;
use iced_native::{Point, Size};
+use lyon::algorithms::walk::{walk_along_path, RepeatedPattern};
use lyon::path::iterator::PathIterator;
-use lyon_algorithms::walk::{walk_along_path, RepeatedPattern};
/// An immutable set of points that may or may not be connected.
///
@@ -83,7 +83,7 @@ pub(super) fn dashed(path: &Path, line_dash: LineDash<'_>) -> Path {
path.raw().iter().flattened(0.01),
0.0,
&mut RepeatedPattern {
- callback: |position: lyon_algorithms::math::Point,
+ callback: |position: lyon::algorithms::math::Point,
_tangent,
_distance| {
let point = Point {