diff options
author | 2024-01-20 13:29:25 +0100 | |
---|---|---|
committer | 2024-01-20 13:29:25 +0100 | |
commit | 25f182f933ea6b7c112c8f9a450a98dc9b9eebdd (patch) | |
tree | fdc498d705f033d3c432e6a06b8cd223dfd82633 /widget/src/scrollable.rs | |
parent | 4d502012b3e3ed9d9ef80f21078d53d182cdaa1b (diff) | |
download | iced-25f182f933ea6b7c112c8f9a450a98dc9b9eebdd.tar.gz iced-25f182f933ea6b7c112c8f9a450a98dc9b9eebdd.tar.bz2 iced-25f182f933ea6b7c112c8f9a450a98dc9b9eebdd.zip |
Introduce `Border` struct analogous to `Shadow`
Diffstat (limited to 'widget/src/scrollable.rs')
-rw-r--r-- | widget/src/scrollable.rs | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/widget/src/scrollable.rs b/widget/src/scrollable.rs index beaad704..b7b6c3d2 100644 --- a/widget/src/scrollable.rs +++ b/widget/src/scrollable.rs @@ -903,15 +903,13 @@ pub fn draw<Renderer>( if scrollbar.bounds.width > 0.0 && scrollbar.bounds.height > 0.0 && (style.background.is_some() - || (style.border_color != Color::TRANSPARENT - && style.border_width > 0.0)) + || (style.border.color != Color::TRANSPARENT + && style.border.width > 0.0)) { renderer.fill_quad( renderer::Quad { bounds: scrollbar.bounds, - border_radius: style.border_radius, - border_width: style.border_width, - border_color: style.border_color, + border: style.border, ..renderer::Quad::default() }, style @@ -924,15 +922,13 @@ pub fn draw<Renderer>( if scrollbar.scroller.bounds.width > 0.0 && scrollbar.scroller.bounds.height > 0.0 && (style.scroller.color != Color::TRANSPARENT - || (style.scroller.border_color != Color::TRANSPARENT - && style.scroller.border_width > 0.0)) + || (style.scroller.border.color != Color::TRANSPARENT + && style.scroller.border.width > 0.0)) { renderer.fill_quad( renderer::Quad { bounds: scrollbar.scroller.bounds, - border_radius: style.scroller.border_radius, - border_width: style.scroller.border_width, - border_color: style.scroller.border_color, + border: style.scroller.border, ..renderer::Quad::default() }, style.scroller.color, |