diff options
author | 2022-09-30 10:27:00 -0700 | |
---|---|---|
committer | 2022-09-30 10:27:00 -0700 | |
commit | 5d0fffc626928177239336757507b986b081b878 (patch) | |
tree | 03c6d1c8ab957f3cb5115fe6c75df65110a0ad64 /examples | |
parent | e25f3d3dea2d2c1ba7d2778948443df2745084be (diff) | |
download | iced-5d0fffc626928177239336757507b986b081b878.tar.gz iced-5d0fffc626928177239336757507b986b081b878.tar.bz2 iced-5d0fffc626928177239336757507b986b081b878.zip |
Fixed some importing issues since you can use a Shader::Gradient outside a Canvas widget, where it was previously only accessible.
Diffstat (limited to 'examples')
-rw-r--r-- | examples/modern_art/Cargo.toml | 1 | ||||
-rw-r--r-- | examples/modern_art/src/main.rs | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/examples/modern_art/Cargo.toml b/examples/modern_art/Cargo.toml index 4995e9a7..8242f7e4 100644 --- a/examples/modern_art/Cargo.toml +++ b/examples/modern_art/Cargo.toml @@ -7,4 +7,5 @@ publish = false [dependencies] iced = { path = "../..", features = ["canvas", "tokio", "debug"] } +iced_graphics = { path = "../../graphics" } rand = "0.8.5"
\ No newline at end of file diff --git a/examples/modern_art/src/main.rs b/examples/modern_art/src/main.rs index 7b04b581..c7945012 100644 --- a/examples/modern_art/src/main.rs +++ b/examples/modern_art/src/main.rs @@ -1,5 +1,5 @@ use rand::{Rng, thread_rng}; -use crate::canvas::{Cursor, FillStyle, Geometry, Gradient}; +use crate::canvas::{Cursor, FillStyle, Geometry}; use iced::widget::canvas::{Cache, Fill, Frame}; use iced::widget::{canvas, Canvas}; use iced::Settings; @@ -7,6 +7,7 @@ use iced::{ executor, Application, Color, Command, Element, Length, Point, Rectangle, Renderer, Size, Theme, }; +use iced_graphics::gradient::Gradient; fn main() -> iced::Result { ModernArt::run(Settings { |