suggestion picker: a persistent layer to complement virtual keyboards like wvkbd
Diffstat (limited to 'main.c')
| -rw-r--r-- | main.c | 14 |
1 files changed, 4 insertions, 10 deletions
@@ -258,11 +258,6 @@ display_handle_geometry(void *data, struct wl_output *wl_output, int x, int y, return; // no changes } - enum layout_id layer; - layer = keyboard.layers[0]; - - keyboard.layout = &keyboard.layouts[layer]; - zwlr_layer_surface_v1_set_size(layer_surface, 0, height); zwlr_layer_surface_v1_set_exclusive_zone(layer_surface, height); wl_surface_commit(draw_surf.surf); @@ -317,7 +312,7 @@ layer_surface_configure(void *data, struct zwlr_layer_surface_v1 *surface, uint32_t serial, uint32_t w, uint32_t h) { keyboard.w = w + KBD_PIXEL_OVERSCAN_WIDTH; keyboard.h = h; - kbd_resize(&keyboard, layouts); + kbd_resize(&keyboard); zwlr_layer_surface_v1_ack_configure(surface, serial); } @@ -390,7 +385,8 @@ handle_input(FILE *fd) { line = malloc(1024); if (fgets(line, 1024, fd) != NULL) { - printf("Retrieved line: %s\n", line); + fprintf(stderr, "Retrieved line: %s", line); + } free(line); @@ -410,9 +406,7 @@ main(int argc, char **argv) { landscape_height = atoi(tmp); /* keyboard settings */ - keyboard.layers = (enum layout_id *)&layers; keyboard.scheme = scheme; - keyboard.layer_index = 0; bool starthidden = false; @@ -481,7 +475,7 @@ main(int argc, char **argv) { die("layer_shell not available\n"); } - kbd_init(&keyboard, (struct layout *)&layouts); + kbd_init(&keyboard); draw_ctx.font_description = pango_font_description_from_string(fc_font_pattern); |