From bf9bbf4a3edf22f21c79901999cc104cb29fccce Mon Sep 17 00:00:00 2001 From: Richard Custodio Date: Mon, 18 Mar 2024 17:08:56 -0300 Subject: refactor: replace `text(format!(` with `text` macro --- examples/vectorial_text/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'examples/vectorial_text/src') diff --git a/examples/vectorial_text/src/main.rs b/examples/vectorial_text/src/main.rs index a7391e23..91740a37 100644 --- a/examples/vectorial_text/src/main.rs +++ b/examples/vectorial_text/src/main.rs @@ -55,7 +55,7 @@ impl VectorialText { row![ text(label), horizontal_space(), - text(format!("{:.2}", value)) + text!("{:.2}", value) ], slider(range, value, message).step(0.01) ] -- cgit From 8ed62541af8cd16760b59d8f0a49d619d78f592e Mon Sep 17 00:00:00 2001 From: Richard Custodio Date: Mon, 18 Mar 2024 18:24:57 -0300 Subject: fix: run `cargo fmt` --- examples/vectorial_text/src/main.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'examples/vectorial_text/src') diff --git a/examples/vectorial_text/src/main.rs b/examples/vectorial_text/src/main.rs index 91740a37..1ed7a2b1 100644 --- a/examples/vectorial_text/src/main.rs +++ b/examples/vectorial_text/src/main.rs @@ -52,11 +52,7 @@ impl VectorialText { fn view(&self) -> Element { let slider_with_label = |label, range, value, message: fn(f32) -> _| { column![ - row![ - text(label), - horizontal_space(), - text!("{:.2}", value) - ], + row![text(label), horizontal_space(), text!("{:.2}", value)], slider(range, value, message).step(0.01) ] .spacing(2) -- cgit