Skip to content

Commit

Permalink
Cattpuccin Macchiato Re-theme
Browse files Browse the repository at this point in the history
  • Loading branch information
AdalynBlack committed Jul 24, 2024
1 parent d4d0f10 commit 8be11cf
Show file tree
Hide file tree
Showing 4 changed files with 196 additions and 195 deletions.
11 changes: 6 additions & 5 deletions src/overlays/keyboard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,12 @@ where
data,
)?;

canvas.bg_color = color_parse("#101010").unwrap(); //safe
canvas.panel(0., 0., size.x, size.y, 5.);
canvas.bg_color = color_parse("#181926").unwrap(); //safe
canvas.panel(0., 0., size.x, size.y, 12.);

canvas.font_size = 18;
canvas.bg_color = color_parse("#202020").unwrap(); //safe
canvas.fg_color = color_parse("#cad3f5").unwrap(); //safe
canvas.bg_color = color_parse("#1e2030").unwrap(); //safe

let has_altgr = keymap.as_ref().map_or(false, |k| k.has_altgr());

Expand Down Expand Up @@ -146,7 +147,7 @@ where
if label.is_empty() {
label = LAYOUT.label_for_key(key);
}
let button = canvas.key_button(x, y, w, h, 0., cap_type, &label);
let button = canvas.key_button(x, y, w, h, 12., cap_type, &label);
button.state = Some(state);
button.on_press = Some(key_press);
button.on_release = Some(key_release);
Expand Down Expand Up @@ -268,7 +269,7 @@ fn key_release(
}
}

static PRESS_COLOR: Vec4 = Vec4::new(1.0, 1.0, 1.0, 0.5);
static PRESS_COLOR: Vec4 = Vec4::new(198./255., 160./255., 246./255., 0.5);

fn test_highlight(
control: &Control<KeyboardData, KeyButtonData>,
Expand Down
16 changes: 8 additions & 8 deletions src/overlays/toast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -178,19 +178,19 @@ fn new_toast(toast: Toast, app: &mut AppState) -> Option<(OverlayState, Box<dyn
.ok()?;

canvas.font_size = FONT_SIZE;
canvas.fg_color = color_parse("#aaaaaa").unwrap(); // want panic
canvas.bg_color = color_parse("#333333").unwrap(); // want panic
canvas.panel(0., 0., size.0, size.1, 3.);
canvas.fg_color = color_parse("#cad3f5").unwrap(); // want panic
canvas.bg_color = color_parse("#1e2030").unwrap(); // want panic
canvas.panel(0., 0., size.0, size.1, 16.);

if toast.body.len() > 0 {
canvas.label(PADDING.0, 54., og_width, size.1 - 54., 3., toast.body);

canvas.fg_color = color_parse("#101010").unwrap(); // want panic
canvas.bg_color = color_parse("#666666").unwrap(); // want panic
canvas.panel(0., 0., size.0, 30., 3.);
canvas.label_centered(PADDING.0, 16., og_width, FONT_SIZE as f32 + 2., 3., title);
canvas.fg_color = color_parse("#b8c0e0").unwrap(); // want panic
canvas.bg_color = color_parse("#24273a").unwrap(); // want panic
canvas.panel(0., 0., size.0, 30., 16.);
canvas.label_centered(PADDING.0, 16., og_width, FONT_SIZE as f32 + 2., 16., title);
} else {
canvas.label_centered(PADDING.0, 0., og_width, size.1, 3., title);
canvas.label_centered(PADDING.0, 0., og_width, size.1, 16., title);
}

let state = OverlayState {
Expand Down
Loading

0 comments on commit 8be11cf

Please sign in to comment.