util: print nonchanged axis with a space instead of a *

When printing tablet events always print a '*' or ' ' suffix to ensure
the alignment of the next field matches. We're using a tab to align
after each field so if the string length doesn't match, our events may
print at different tab stops.

Part-of: <https://gitlab.freedesktop.org/libinput/libinput/-/merge_requests/1299>
This commit is contained in:
Peter Hutterer 2025-08-18 12:01:12 +10:00 committed by Marge Bot
parent 537552480d
commit e45cd2bc13

View file

@ -404,7 +404,7 @@ print_tablet_axes(struct libinput_event_tablet_tool *t)
_autofree_ char *size = NULL;
#define changed_sym(ev, ax) \
(libinput_event_tablet_tool_##ax##_has_changed(ev) ? "*" : "")
(libinput_event_tablet_tool_##ax##_has_changed(ev) ? "*" : " ")
if (libinput_tablet_tool_has_tilt(tool)) {
x = libinput_event_tablet_tool_get_tilt_x(t);