Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package wvkbd for openSUSE:Factory checked in at 2026-10-29 16:10:59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/wvkbd (Old) and /work/SRC/openSUSE:Factory/.wvkbd.new.1255 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "wvkbd" Thu Oct 29 16:10:59 2026 rev:6 rq:1393591 version:0.21 Changes: -------- --- /work/SRC/openSUSE:Factory/wvkbd/wvkbd.changes 2026-07-28 18:04:36.938610541 +0200 +++ /work/SRC/openSUSE:Factory/.wvkbd.new.1255/wvkbd.changes 2026-10-29 16:12:46.473251569 +0100 @@ -1,0 +2,11 @@ +Thu Oct 29 09:22:26 UTC 2026 - Michael Vetter <[email protected]> + +- Update to 0.21: + * Fix segmentation fault after hiding the keyboard + * Add one-handed docking, baseplate opacity + * Add CLI argument --wayland-layer for setting layer shell position + * Fix missing release on hide after key press + * Fix repeat cancel on minimal touch motions + * Added Shift+Insert for primary paste + +------------------------------------------------------------------- Old: ---- v0.20.tar.gz New: ---- v0.21.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ wvkbd.spec ++++++ --- /var/tmp/diff_new_pack.1cQjBb/_old 2026-10-29 16:12:47.222282982 +0100 +++ /var/tmp/diff_new_pack.1cQjBb/_new 2026-10-29 16:12:47.223283024 +0100 @@ -17,7 +17,7 @@ Name: wvkbd -Version: 0.20 +Version: 0.21 Release: 0 Summary: Wayland on-screen keyboard License: GPL-3.0-only ++++++ v0.20.tar.gz -> v0.21.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/.build.yml new/wvkbd-0.21/.build.yml --- old/wvkbd-0.20/.build.yml 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/.build.yml 2026-10-27 20:41:07.000000000 +0100 @@ -14,9 +14,6 @@ condition: failure to: "~mil/[email protected]" tasks: - - format: | - cd wvkbd - make format - build: | cd wvkbd make diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/CHANGELOG.md new/wvkbd-0.21/CHANGELOG.md --- old/wvkbd-0.20/CHANGELOG.md 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/CHANGELOG.md 2026-10-27 20:41:07.000000000 +0100 @@ -1,3 +1,19 @@ +# v0.21 - 2026-10-27 + +[Willow Barraco] +* Fix segmentation fault after hiding the keyboard + +[Johnny Guerra] +* add one-handed docking, baseplate opacity + +[Christian Duerr] +* Add CLI argument --wayland-layer for setting layer shell position +* Fix missing release on hide after key press +* Fix repeat cancel on minimal touch motions + +[Emeric Dupont] +* Added Shift+Insert for primary paste + # v0.20 - 2026-07-24 This release implements automatic focus-based visibility toggling, thanks to Christian Duerr. Start wvkbd with the `--auto` parameter to opt-in for this feature (it is not the default yet). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/Makefile new/wvkbd-0.21/Makefile --- old/wvkbd-0.20/Makefile 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/Makefile 2026-10-27 20:41:07.000000000 +0100 @@ -23,7 +23,8 @@ HDRS = $(WAYLAND_HEADERS:.xml=-client-protocol.h) WAYLAND_SRC = $(HDRS:.h=.c) SOURCES = $(WVKBD_SOURCES) $(WAYLAND_SRC) -OBJECTS = $(WVKBD_DIR_SOURCES:.c=.o) $(WAYLAND_SRC:.c=.o) +WAYLAND_OBJS = $(addprefix $(BUILDDIR)/, $(WAYLAND_SRC:.c=.o)) +OBJECTS = $(WVKBD_DIR_SOURCES:.c=.o) $(WAYLAND_OBJS) SCDOC=scdoc DOCS = wvkbd.1 @@ -36,14 +37,14 @@ cp config.$(LAYOUT).h $@ $(BUILDDIR)/%.o: %.c - mkdir -p $(BUILDDIR) + mkdir -p $(dir $@) $(CC) -I $(CURDIR) -I $(CURDIR)/$(BUILDDIR) -c $(CFLAGS) -o $@ $< proto/%-client-protocol.c: proto/%.xml - wayland-scanner code < $? > $@ + wayland-scanner private-code < $< > $@ proto/%-client-protocol.h: proto/%.xml - wayland-scanner client-header < $? > $@ + wayland-scanner client-header < $< > $@ $(OBJECTS): $(HDRS) $(WVKBD_HEADERS) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/config.mk new/wvkbd-0.21/config.mk --- old/wvkbd-0.20/config.mk 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/config.mk 2026-10-27 20:41:07.000000000 +0100 @@ -1,4 +1,4 @@ -VERSION = 0.20 +VERSION = 0.21 CFLAGS = -DVERSION=\"$(VERSION)\" -D_XOPEN_SOURCE=700 PREFIX = /usr/local MANPREFIX = ${PREFIX}/share/man diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/keyboard.c new/wvkbd-0.21/keyboard.c --- old/wvkbd-0.20/keyboard.c 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/keyboard.c 2026-10-27 20:41:07.000000000 +0100 @@ -4,7 +4,10 @@ #include <stdio.h> #include <sys/mman.h> #include <ctype.h> +#include <time.h> #include "keyboard.h" +#include <linux/input-event-codes.h> + #include "drw.h" #include "os-compatibility.h" @@ -318,7 +321,8 @@ WL_KEYBOARD_KEY_STATE_RELEASED); } else { zwp_virtual_keyboard_v1_key(kb->vkbd, time, - kb->last_press->code, + unlatch_shift && kb->last_press->shift_code ? + kb->last_press->shift_code : kb->last_press->code, WL_KEYBOARD_KEY_STATE_RELEASED); } } @@ -380,6 +384,14 @@ void kbd_motion_key(struct kbd *kb, uint32_t time, uint32_t x, uint32_t y) { + struct key *intersect_key; + intersect_key = kbd_get_key(kb, x, y); + + // Ignore keyboard motion until a new key is reached. + if (kb->last_press == intersect_key) { + return; + } + // Output intersecting keys // (for external 'swiping'-based accelerators). if (kb->print_intersect) { @@ -388,8 +400,7 @@ // Redraw last press as a swipe. kbd_draw_key(kb, kb->last_swipe, Swipe); } - struct key *intersect_key; - intersect_key = kbd_get_key(kb, x, y); + if (intersect_key && (!kb->last_swipe || intersect_key->label != kb->last_swipe->label)) { kbd_print_key_stdout(kb, intersect_key); @@ -441,6 +452,7 @@ zwp_virtual_keyboard_v1_modifiers(kb->vkbd, kb->mods, 0, 0, 0); } kb->last_swipe = kb->last_press = k; + kb->last_press_offset = time - monotime(); kbd_draw_key(kb, k, Press); if ((kb->shift_space_is_tab) && (k->code == KEY_SPACE) && (kb->mods & Shift)) { // shift space is tab @@ -449,7 +461,8 @@ zwp_virtual_keyboard_v1_key(kb->vkbd, time, KEY_TAB, WL_KEYBOARD_KEY_STATE_PRESSED); } else { - zwp_virtual_keyboard_v1_key(kb->vkbd, time, kb->last_press->code, + zwp_virtual_keyboard_v1_key(kb->vkbd, time, (kb->mods & Shift) && k->shift_code ? + k->shift_code : k->code, WL_KEYBOARD_KEY_STATE_PRESSED); } if (kb->print || kb->print_intersect) @@ -529,6 +542,7 @@ case Copy: // copy code as unicode chr by setting a temporary keymap kb->last_swipe = kb->last_press = k; + kb->last_press_offset = time - monotime(); kbd_draw_key(kb, k, Press); if (kb->mods & Shift) { if (kb->debug) @@ -694,7 +708,12 @@ if (kb->debug) fprintf(stderr, "Draw layout\n"); - drw_fill_rectangle(d, kb->schemes[0].bg, 0, 0, kb->w, kb->h, 0); + if (kb->corner_radius > 0) { + drw_do_clear(d, 0, 0, kb->w, kb->h); + drw_fill_rectangle(d, kb->schemes[0].bg, 0, 0, kb->w, kb->h, kb->corner_radius); + } else { + drw_fill_rectangle(d, kb->schemes[0].bg, 0, 0, kb->w, kb->h, 0); + } while (next_key->type != Last) { if ((next_key->type == Pad) || (next_key->type == EndRow)) { @@ -783,3 +802,13 @@ keymap_fd, keymap_size); free((void *)keymap_str); } + +// Get a monotonic millisecond timer. +int64_t +monotime() +{ + struct timespec spec; + clock_gettime(CLOCK_MONOTONIC, &spec); + + return (spec.tv_sec * 1000 + spec.tv_nsec / 1000000); +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/keyboard.h new/wvkbd-0.21/keyboard.h --- old/wvkbd-0.20/keyboard.h 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/keyboard.h 2026-10-27 20:41:07.000000000 +0100 @@ -75,6 +75,8 @@ struct layout *layout; // pointer back to the parent layout that holds this // key const uint32_t code_mod; /* modifier to force when this key is pressed */ + const uint32_t + shift_code; /* shift_code: secondary scancode */ uint8_t scheme; // index of the scheme to use bool reset_mod; /* reset modifiers when clicked */ @@ -102,6 +104,7 @@ bool print; bool print_intersect; uint32_t w, h; + int corner_radius; double scale; double preferred_scale, preferred_fractional_scale; bool landscape; @@ -115,6 +118,7 @@ size_t layer_index; struct layout *last_abc_layout; //the last alphabetical layout to fall back to (may be further away than prevlayout) size_t last_abc_index; //the layer index of the last alphabetical layout + int64_t last_press_offset; // Delta between processor and compositor time during `last_press` struct layout *layouts; struct Output *output; //only used to keep track of landscape flipping, never dereferenced @@ -152,8 +156,8 @@ double kbd_get_row_length(struct key *k); void kbd_next_layer(struct kbd *kb, struct key *k, bool invert); void kbd_switch_layout(struct kbd *kb, struct layout *l, size_t layer_index); - void create_and_upload_keymap(struct kbd *kb, const char *name, uint32_t comp_unichr); +int64_t monotime(); #ifndef LAYOUT #error "make sure to define LAYOUT" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/layout.mobintl.h new/wvkbd-0.21/layout.mobintl.h --- old/wvkbd-0.20/layout.mobintl.h 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/layout.mobintl.h 2026-10-27 20:41:07.000000000 +0100 @@ -182,7 +182,7 @@ {"'", "\"", 1.0, Code, KEY_APOSTROPHE, &layouts[ComposeBracket] }, {"-", "_", 1.0, Code, KEY_MINUS, &layouts[ComposeMath] }, {"/", ">", 1.0, Code, KEY_SLASH, &layouts[ComposePunctuation] }, - {"Tab", "Tab", 1.0, Code, KEY_TAB, .scheme = 1}, + {"Tab", "Ins", 1.0, Code, KEY_TAB, .shift_code = KEY_INSERT, .scheme = 1}, {"", "", 0.0, EndRow}, {"1", "!", 1.0, Code, KEY_1}, @@ -254,7 +254,7 @@ {"'", "\"", 1.0, Code, KEY_APOSTROPHE, &layouts[ComposeBracket] }, {";", ":", 1.0, Code, KEY_SEMICOLON, &layouts[ComposePunctuation] }, {"/", ">", 1.0, Code, KEY_SLASH, &layouts[ComposePunctuation] }, - {"Tab", "Tab", 1.0, Code, KEY_TAB, .scheme = 1}, + {"Tab", "Ins", 1.0, Code, KEY_TAB, .shift_code = KEY_INSERT, .scheme = 1}, {"", "", 0.0, EndRow}, {"1", "!", 1.0, Code, KEY_1}, @@ -1115,7 +1115,7 @@ {"o", "O", 1.0, Code, KEY_O, &layouts[ComposeO]}, {"p", "P", 1.0, Code, KEY_P, &layouts[ComposeP]}, {"", "", 0.5, Pad, .scheme = 1}, - {"Tab", "Tab", 1.0, Code, KEY_TAB, .scheme = 1}, + {"Tab", "Ins", 1.0, Code, KEY_TAB, .shift_code = KEY_INSERT, .scheme = 1}, {"", "", 0.0, EndRow}, {"↑", "↑", 0.75, Code, KEY_UP, .scheme = 1}, @@ -1175,7 +1175,7 @@ {"9", "(", 1.0, Code, KEY_9, &layouts[ComposeBracket]}, {"0", ")", 1.0, Code, KEY_0, &layouts[ComposeBracket]}, {"", "", 0.5, Pad, .scheme = 1}, - {"Tab", "Tab", 1.0, Code, KEY_TAB, .scheme = 1}, + {"Tab", "Ins", 1.0, Code, KEY_TAB, .shift_code = KEY_INSERT, .scheme = 1}, {"", "", 0.0, EndRow}, {"⇈", "⇈", 1.0, Code, KEY_PAGEUP, .scheme = 1}, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/main.c new/wvkbd-0.21/main.c --- old/wvkbd-0.20/main.c 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/main.c 2026-10-27 20:41:07.000000000 +0100 @@ -74,6 +74,14 @@ static int rounding = DEFAULT_ROUNDING; static bool hidden = false; static bool im_auto = false; +static uint32_t custom_width = 0; +static double width_ratio = 1.0; +static enum { DOCK_FULL = 0, DOCK_LEFT = 1, DOCK_RIGHT = 2 } dock_mode = DOCK_FULL; +static uint8_t bg_alpha = 0; +static bool bg_alpha_defined = false; +static int corner_radius = -1; + + /* event handler prototypes */ static void wl_pointer_enter(void *data, struct wl_pointer *wl_pointer, @@ -565,7 +573,13 @@ height = normal_height; } - keyboard.w = available_width; + if (custom_width > 0) { + keyboard.w = custom_width; + } else if (dock_mode != DOCK_FULL) { + keyboard.w = (uint32_t)((double)available_width * width_ratio); + } else { + keyboard.w = available_width; + } keyboard.h = height; keyboard.layout = &keyboard.layouts[layer]; keyboard.layer_index = 0; @@ -700,9 +714,17 @@ " -l - Comma separated list of layers\n"); fprintf(stderr, " --landscape-layers - Comma separated list of " "landscape layers\n"); - fprintf(stderr, " --non-exclusive - Allow the keyboard to overlap" - " windows. Do not request an exclusive zone from the" + fprintf(stderr, " --dock [left|right|full] - Dock keyboard to left or right edge\n"); + fprintf(stderr, " --ratio [0.3-1.0] - Screen width ratio for docked keyboard\n"); + fprintf(stderr, " --width [pixels] - Custom fixed width in pixels\n"); + fprintf(stderr, " --corner-radius [pixels] - Corner radius of keyboard window\n"); + fprintf(stderr, " --bg-alpha [0-255] - Independent opacity for keyboard baseplate\n"); + fprintf(stderr, " --double-space-period - Double tap space to insert period and space\n"); + fprintf(stderr, " --non-exclusive - Allow the keyboard to overlap " + "windows. Do not request an exclusive zone from the " "compositor\n"); + fprintf(stderr, " --wayland-layer [background|bottom|top|overlay]" + " - Wayland layer shell z index\n"); } void @@ -723,6 +745,10 @@ return; } + // Ensure active keys are released, so they're not repeated infinitely. + uint32_t time = (uint32_t) (monotime() + keyboard.last_press_offset); + kbd_unpress_key(&keyboard, time); + if (wfs_draw_surf) { wp_fractional_scale_v1_destroy(wfs_draw_surf); wfs_draw_surf = NULL; @@ -753,6 +779,10 @@ wl_callback_destroy(draw_surf.frame_cb); draw_surf.frame_cb = NULL; } + if (popup_draw_surf.frame_cb) { + wl_callback_destroy(popup_draw_surf.frame_cb); + popup_draw_surf.frame_cb = NULL; + } wl_surface_destroy(draw_surf.surf); draw_surf.attached = false; @@ -787,7 +817,19 @@ layer_surface = zwlr_layer_shell_v1_get_layer_surface( layer_shell, draw_surf.surf, current_output_data, layer, namespace); - zwlr_layer_surface_v1_set_size(layer_surface, 0, height); + anchor = ZWLR_LAYER_SURFACE_V1_ANCHOR_BOTTOM; + uint32_t req_w = 0; + if (dock_mode == DOCK_LEFT) { + anchor |= ZWLR_LAYER_SURFACE_V1_ANCHOR_LEFT; + req_w = keyboard.w; + } else if (dock_mode == DOCK_RIGHT) { + anchor |= ZWLR_LAYER_SURFACE_V1_ANCHOR_RIGHT; + req_w = keyboard.w; + } else { + anchor |= ZWLR_LAYER_SURFACE_V1_ANCHOR_LEFT | ZWLR_LAYER_SURFACE_V1_ANCHOR_RIGHT; + req_w = 0; + } + zwlr_layer_surface_v1_set_size(layer_surface, req_w, height); zwlr_layer_surface_v1_set_anchor(layer_surface, anchor); if (keyboard.exclusive) { zwlr_layer_surface_v1_set_exclusive_zone(layer_surface, height); @@ -880,6 +922,7 @@ keyboard.preferred_scale = 1; keyboard.preferred_fractional_scale = 0; keyboard.exclusive = true; + keyboard.corner_radius = 0; keyboard.show_popup = true; keyboard.show_highlight = true; @@ -925,6 +968,13 @@ } alpha = atoi(argv[++i]); alpha_defined = true; + } else if (!strcmp(argv[i], "--bg-alpha")) { + if (i >= argc - 1) { + usage(argv[0]); + exit(1); + } + bg_alpha = atoi(argv[++i]); + bg_alpha_defined = true; } else if ((!strcmp(argv[i], "-fg")) || (!strcmp(argv[i], "--fg"))) { if (i >= argc - 1) { usage(argv[0]); @@ -1060,6 +1110,62 @@ } else if ((!strcmp(argv[i], "-auto")) || (!strcmp(argv[i], "--auto"))) { im_auto = true; + } else if ((!strcmp(argv[i], "-wayland-layer")) || + (!strcmp(argv[i], "--wayland-layer"))) { + if (i >= argc - 1) { + usage(argv[0]); + exit(1); + } + ++i; + + if (!strcmp(argv[i], "background")) { + layer = ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND; + } else if (!strcmp(argv[i], "bottom")) { + layer = ZWLR_LAYER_SHELL_V1_LAYER_BOTTOM; + } else if (!strcmp(argv[i], "top")) { + layer = ZWLR_LAYER_SHELL_V1_LAYER_TOP; + } else if (!strcmp(argv[i], "overlay")) { + layer = ZWLR_LAYER_SHELL_V1_LAYER_OVERLAY; + } else { + usage(argv[0]); + exit(1); + } + } else if (!strcmp(argv[i], "--dock")) { + if (i >= argc - 1) { + usage(argv[0]); + exit(1); + } + i++; + if (!strcmp(argv[i], "left")) { + dock_mode = DOCK_LEFT; + if (width_ratio == 1.0) width_ratio = 0.68; + } else if (!strcmp(argv[i], "right")) { + dock_mode = DOCK_RIGHT; + if (width_ratio == 1.0) width_ratio = 0.68; + } else { + dock_mode = DOCK_FULL; + width_ratio = 1.0; + } + } else if (!strcmp(argv[i], "--corner-radius")) { + if (i >= argc - 1) { + usage(argv[0]); + exit(1); + } + corner_radius = atoi(argv[++i]); + } else if (!strcmp(argv[i], "--width")) { + if (i >= argc - 1) { + usage(argv[0]); + exit(1); + } + custom_width = atoi(argv[++i]); + } else if (!strcmp(argv[i], "--ratio")) { + if (i >= argc - 1) { + usage(argv[0]); + exit(1); + } + width_ratio = atof(argv[++i]); + if (width_ratio < 0.3) width_ratio = 0.3; + if (width_ratio > 1.0) width_ratio = 1.0; } else { fprintf(stderr, "Invalid argument: %s\n", argv[i]); usage(argv[0]); @@ -1067,13 +1173,24 @@ } } + if (corner_radius >= 0) { + keyboard.corner_radius = corner_radius; + } else if (dock_mode != DOCK_FULL) { + keyboard.corner_radius = 16; + } else { + keyboard.corner_radius = 0; + } + if (alpha_defined) { - keyboard.schemes[0].bg.bgra[3] = alpha; + keyboard.schemes[0].bg.bgra[3] = bg_alpha_defined ? bg_alpha : alpha; keyboard.schemes[0].fg.bgra[3] = alpha; keyboard.schemes[0].high.bgra[3] = alpha; - keyboard.schemes[1].bg.bgra[3] = alpha; + keyboard.schemes[1].bg.bgra[3] = bg_alpha_defined ? bg_alpha : alpha; keyboard.schemes[1].fg.bgra[3] = alpha; keyboard.schemes[1].high.bgra[3] = alpha; + } else if (bg_alpha_defined) { + keyboard.schemes[0].bg.bgra[3] = bg_alpha; + keyboard.schemes[1].bg.bgra[3] = bg_alpha; } if (fc_font_pattern) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wvkbd-0.20/wvkbd.1.scd new/wvkbd-0.21/wvkbd.1.scd --- old/wvkbd-0.20/wvkbd.1.scd 2026-07-24 23:16:05.000000000 +0200 +++ new/wvkbd-0.21/wvkbd.1.scd 2026-10-27 20:41:07.000000000 +0100 @@ -67,6 +67,27 @@ Allow keyboard to overlap existing windows, do not request an exclusive zone from the compositor. +*--wayland-layer* _[background|bottom|top|overlay]_ + Wayland layer shell z index + +*--dock* _left|right|full_ + Dock keyboard to the left or right screen corner for comfortable one-handed + typing on tablets and foldables. Defaults to full. + +*--ratio* _float_ + Width ratio when docked [0.3-1.0]. Defaults to 0.68. + +*--width* _int_ + Explicit custom width in pixels. + +*--corner-radius* _int_ + Corner radius in pixels for the keyboard window background (defaults to 16 when docked, + 0 when full-width). + +*--bg-alpha* _int_ + Set independent alpha value for the keyboard baseplate [0-255]. Allows + semi-opaque or opaque backing while maintaining translucent keycaps. + *--alpha* _int_ Set alpha value (i.e. transparency) for all colors [0-255]
