overlapped key output: highlight letters swiped through

This commit is contained in:
Zach DeCook
2021-12-03 11:57:19 -05:00
committed by John Sullivan
parent 2de12a90e4
commit 564eb4536a
5 changed files with 68 additions and 14 deletions

View File

@ -45,6 +45,7 @@ struct clr_scheme {
Color fg;
Color bg;
Color high;
Color swipe;
Color text;
};
@ -105,6 +106,8 @@ struct kbd {
void draw_inset(struct drwsurf *ds, uint32_t x, uint32_t y, uint32_t width,
uint32_t height, uint32_t border, Color color);
void draw_over_inset(struct drwsurf *ds, uint32_t x, uint32_t y, uint32_t width,
uint32_t height, uint32_t border, Color color);
void kbd_init(struct kbd *kb, struct layout *layouts, char *layer_names_list);
void kbd_init_layout(struct layout *l, uint32_t width, uint32_t height);
@ -114,7 +117,9 @@ void kbd_release_key(struct kbd *kb, uint32_t time);
void kbd_motion_key(struct kbd *kb, uint32_t time, uint32_t x, uint32_t y);
void kbd_press_key(struct kbd *kb, struct key *k, uint32_t time);
void kbd_print_key_stdout(struct kbd *kb, struct key *k);
void kbd_draw_key(struct kbd *kb, struct key *k, bool pressed);
void kbd_draw_key(struct kbd *kb, struct key *k, bool pressed, bool swiped);
void kbd_draw_press(struct kbd *kb, struct key *k, bool pressed);
void kbd_draw_swipe(struct kbd *kb, struct key *k);
void kbd_draw_layout(struct kbd *kb);
void kbd_resize(struct kbd *kb, struct layout *layouts, uint8_t layoutcount);
uint8_t kbd_get_rows(struct layout *l);