summaryrefslogtreecommitdiffstats
path: root/style/src/text_input.rs
diff options
context:
space:
mode:
Diffstat (limited to 'style/src/text_input.rs')
-rw-r--r--style/src/text_input.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/style/src/text_input.rs b/style/src/text_input.rs
index 75f427a7..269b28db 100644
--- a/style/src/text_input.rs
+++ b/style/src/text_input.rs
@@ -10,6 +10,17 @@ pub struct Style {
pub border_color: Color,
}
+impl std::default::Default for Style {
+ fn default() -> Self {
+ Self {
+ background: Background::Color(Color::WHITE),
+ border_radius: 0,
+ border_width: 0,
+ border_color: Color::TRANSPARENT,
+ }
+ }
+}
+
/// A set of rules that dictate the style of a text input.
pub trait StyleSheet {
/// Produces the style of an active text input.