interactive-evdev: reduce the space allocated for keysyms (#443)

* interactive-evdev: reduce the printed space used for keysyms

In commit 8cca3a7bfb the buffer for the keysym
was extended to accommodate for up to XKB_COMPOSE_MAX_STRING_SIZE bytes. This
caused the printf to expand to the same width for the keysym alone, making the
output less useful. Drop this back down to the same width it was before.
master
Peter Hutterer 2024-02-08 20:15:22 +10:00 committed by GitHub
parent 1731c6b3ef
commit dd3e214003
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -200,7 +200,7 @@ tools_print_keycode_state(char *prefix,
printf("keysyms [ "); printf("keysyms [ ");
for (int i = 0; i < nsyms; i++) { for (int i = 0; i < nsyms; i++) {
xkb_keysym_get_name(syms[i], s, sizeof(s)); xkb_keysym_get_name(syms[i], s, sizeof(s));
printf("%-*s ", (int) sizeof(s), s); printf("%-*s ", XKB_KEYSYM_NAME_MAX_SIZE, s);
} }
printf("] "); printf("] ");