MCPcopy Create free account
hub / github.com/algoscienceacademy/RustUI / new

Method new

src/theme/mod.rs:20–30  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

18
19impl Theme {
20 pub fn new() -> Self {
21 Self {
22 is_dark: false,
23 colors: ThemeColors {
24 primary: crate::style::Color::rgb(0.0, 0.0, 0.0),
25 background: crate::style::Color::rgb(1.0, 1.0, 1.0),
26 text: crate::style::Color::rgb(0.0, 0.0, 0.0),
27 },
28 styles: HashMap::new(),
29 }
30 }
31
32 pub fn apply_to(&self, component: &mut dyn Component) {
33 if let Some(style) = self.styles.get("default") {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected