summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-03-12 14:35:55 +0100
committerLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-03-12 14:35:55 +0100
commitaeb72d528fce58ac94df3c015c10d6fe05f81a01 (patch)
tree999b5dc601401a8a47e541aace4c060d6f1db35d /examples
parent66f81c3429c736c5ca17d022ed1d6cdcc15e4f94 (diff)
downloadiced-aeb72d528fce58ac94df3c015c10d6fe05f81a01.tar.gz
iced-aeb72d528fce58ac94df3c015c10d6fe05f81a01.tar.bz2
iced-aeb72d528fce58ac94df3c015c10d6fe05f81a01.zip
Use closures for `Text::style`
Diffstat (limited to 'examples')
-rw-r--r--examples/component/src/main.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/examples/component/src/main.rs b/examples/component/src/main.rs
index a1572b1d..d4f99798 100644
--- a/examples/component/src/main.rs
+++ b/examples/component/src/main.rs
@@ -83,7 +83,10 @@ mod numeric_input {
impl<Message, Theme> Component<Message, Theme> for NumericInput<Message>
where
- Theme: button::DefaultStyle + text_input::DefaultStyle + 'static,
+ Theme: text::DefaultStyle
+ + button::DefaultStyle
+ + text_input::DefaultStyle
+ + 'static,
{
type State = ();
type Event = Event;
@@ -158,7 +161,10 @@ mod numeric_input {
impl<'a, Message, Theme> From<NumericInput<Message>>
for Element<'a, Message, Theme>
where
- Theme: button::DefaultStyle + text_input::DefaultStyle + 'static,
+ Theme: text::DefaultStyle
+ + button::DefaultStyle
+ + text_input::DefaultStyle
+ + 'static,
Message: 'a,
{
fn from(numeric_input: NumericInput<Message>) -> Self {