summaryrefslogtreecommitdiffstats
path: root/widget/src/helpers.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-07-18 13:14:56 +0200
committerLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-07-18 13:14:56 +0200
commit904704d7c1b006c850654dcf3bf9e856e23cb317 (patch)
treef26c32d5769a184c72ca3dc4accacd1ac634d915 /widget/src/helpers.rs
parent910eb72a0620b34e5b3d7793bbd5ab7290e08dd6 (diff)
downloadiced-904704d7c1b006c850654dcf3bf9e856e23cb317.tar.gz
iced-904704d7c1b006c850654dcf3bf9e856e23cb317.tar.bz2
iced-904704d7c1b006c850654dcf3bf9e856e23cb317.zip
Flesh out the `markdown` example a bit more
Diffstat (limited to 'widget/src/helpers.rs')
-rw-r--r--widget/src/helpers.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/widget/src/helpers.rs b/widget/src/helpers.rs
index 66b37ccb..0390079f 100644
--- a/widget/src/helpers.rs
+++ b/widget/src/helpers.rs
@@ -24,7 +24,7 @@ use crate::tooltip::{self, Tooltip};
use crate::vertical_slider::{self, VerticalSlider};
use crate::{Column, MouseArea, Row, Space, Stack, Themer};
-use std::borrow::Borrow;
+use std::borrow::{Borrow, Cow};
use std::ops::RangeInclusive;
/// Creates a [`Column`] with the given children.
@@ -684,7 +684,7 @@ where
///
/// [`Rich`]: text::Rich
pub fn rich_text<'a, Theme, Renderer>(
- spans: impl IntoIterator<Item = text::Span<'a, Renderer::Font>>,
+ spans: impl Into<Cow<'a, [text::Span<'a, Renderer::Font>]>>,
) -> text::Rich<'a, Theme, Renderer>
where
Theme: text::Catalog + 'a,