summaryrefslogtreecommitdiffstats
path: root/wgpu/src/defaults.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2019-12-30 12:14:26 +0100
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2019-12-30 12:14:26 +0100
commit8caa66be2708b1c83e20d905d69902c2567c4692 (patch)
treeee18296fc3d32f24bca90f97fc6845d97f3e4c21 /wgpu/src/defaults.rs
parent89a6b8a9a173e767753ec777fd83c912c1be5ea3 (diff)
downloadiced-8caa66be2708b1c83e20d905d69902c2567c4692.tar.gz
iced-8caa66be2708b1c83e20d905d69902c2567c4692.tar.bz2
iced-8caa66be2708b1c83e20d905d69902c2567c4692.zip
Add `Renderer::Defaults` and style inheritance
Diffstat (limited to '')
-rw-r--r--wgpu/src/defaults.rs27
1 files changed, 27 insertions, 0 deletions
diff --git a/wgpu/src/defaults.rs b/wgpu/src/defaults.rs
new file mode 100644
index 00000000..8de8258b
--- /dev/null
+++ b/wgpu/src/defaults.rs
@@ -0,0 +1,27 @@
+use iced_native::Color;
+
+#[derive(Debug, Clone, Copy)]
+pub struct Defaults {
+ pub text: Text,
+}
+
+impl Default for Defaults {
+ fn default() -> Defaults {
+ Defaults {
+ text: Text::default(),
+ }
+ }
+}
+
+#[derive(Debug, Clone, Copy)]
+pub struct Text {
+ pub color: Color,
+}
+
+impl Default for Text {
+ fn default() -> Text {
+ Text {
+ color: Color::BLACK,
+ }
+ }
+}