aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/theme.rs31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/theme.rs b/src/theme.rs
new file mode 100644
index 0000000..f091358
--- /dev/null
+++ b/src/theme.rs
@@ -0,0 +1,31 @@
1use cursive::theme::Color::*;
2use cursive::theme::BaseColor::*;
3use cursive::theme::BorderStyle;
4use cursive::theme;
5
6pub fn palette_gen() -> theme::Palette {
7 let mut palette: theme::Palette = theme::Palette::default();
8
9 palette.set_color("background" , Dark(Black));
10 palette.set_color("shadow" , Dark(White));
11 palette.set_color("view" , Dark(Black));
12 palette.set_color("primary" , Dark(White));
13 palette.set_color("secondary" , Light(Black));
14 palette.set_color("teritary" , Dark(Green));
15 palette.set_color("title_primary" , Dark(Blue));
16 palette.set_color("title_secondary" , Dark(Green));
17 palette.set_color("highlight" , Dark(Blue));
18 palette.set_color("highlight_inactive" , Light(Black));
19
20 palette
21}
22
23pub fn theme_gen() -> theme::Theme {
24 let mut wikitheme = theme::load_default();
25
26 wikitheme.shadow = false;
27 wikitheme.borders = BorderStyle::Simple;
28 wikitheme.palette = palette_gen();
29
30 wikitheme
31}