summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorLibravatar Cory Forsstrom <cforsstrom18@gmail.com>2024-07-23 13:36:40 -0700
committerLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-07-28 13:06:57 +0200
commitddcf02f9d0377afe6a35dbbb09a29b4bd52efe2e (patch)
tree146f552a26ca1a41d53a006c570b1ff46b674554 /examples
parent23a7e9f981728e8a95039db8eb8e9f3d8c6ba3d7 (diff)
downloadiced-ddcf02f9d0377afe6a35dbbb09a29b4bd52efe2e.tar.gz
iced-ddcf02f9d0377afe6a35dbbb09a29b4bd52efe2e.tar.bz2
iced-ddcf02f9d0377afe6a35dbbb09a29b4bd52efe2e.zip
Add background styling to span / rich text
Diffstat (limited to 'examples')
-rw-r--r--examples/markdown/src/main.rs9
1 files changed, 6 insertions, 3 deletions
diff --git a/examples/markdown/src/main.rs b/examples/markdown/src/main.rs
index 173cb389..db40d0b9 100644
--- a/examples/markdown/src/main.rs
+++ b/examples/markdown/src/main.rs
@@ -28,8 +28,11 @@ impl Markdown {
(
Self {
content: text_editor::Content::with_text(INITIAL_CONTENT),
- items: markdown::parse(INITIAL_CONTENT, theme.palette())
- .collect(),
+ items: markdown::parse(
+ INITIAL_CONTENT,
+ theme.extended_palette(),
+ )
+ .collect(),
theme,
},
widget::focus_next(),
@@ -46,7 +49,7 @@ impl Markdown {
if is_edit {
self.items = markdown::parse(
&self.content.text(),
- self.theme.palette(),
+ self.theme.extended_palette(),
)
.collect();
}