aboutsummaryrefslogtreecommitdiff
path: root/showevent
diff options
context:
space:
mode:
authorDerek Stevens <nilix@nilfm.cc>2021-11-16 15:16:28 -0700
committerDerek Stevens <nilix@nilfm.cc>2021-11-16 15:16:28 -0700
commit496da4fe6e8652064de54cfda6282a795427bbe6 (patch)
treebac9781629423d67867dedccff82b37b6fe73d2a /showevent
parentb23f229ca59b1225f6dba04e8195c64a617c05c6 (diff)
add OPACITY, TRANSPARENTLIST config macros; add clang-format back to build script; update docs
Diffstat (limited to 'showevent')
-rw-r--r--showevent/ShowEvent.c474
1 files changed, 295 insertions, 179 deletions
diff --git a/showevent/ShowEvent.c b/showevent/ShowEvent.c
index 39a4e5c..22484b9 100644
--- a/showevent/ShowEvent.c
+++ b/showevent/ShowEvent.c
@@ -12,11 +12,14 @@ static char* sep;
static char* TorF(bool) int bool;
{
switch (bool) {
- case True: return ("True");
+ case True:
+ return ("True");
- case False: return ("False");
+ case False:
+ return ("False");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -24,11 +27,14 @@ static char* TorF(bool) int bool;
static char* PropertyState(state) int state;
{
switch (state) {
- case PropertyNewValue: return ("PropertyNewValue");
+ case PropertyNewValue:
+ return ("PropertyNewValue");
- case PropertyDelete: return ("PropertyDelete");
+ case PropertyDelete:
+ return ("PropertyDelete");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -36,13 +42,17 @@ static char* PropertyState(state) int state;
static char* VisibilityState(state) int state;
{
switch (state) {
- case VisibilityUnobscured: return ("VisibilityUnobscured");
+ case VisibilityUnobscured:
+ return ("VisibilityUnobscured");
- case VisibilityPartiallyObscured: return ("VisibilityPartiallyObscured");
+ case VisibilityPartiallyObscured:
+ return ("VisibilityPartiallyObscured");
- case VisibilityFullyObscured: return ("VisibilityFullyObscured");
+ case VisibilityFullyObscured:
+ return ("VisibilityFullyObscured");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -157,11 +167,14 @@ static char* ConfigureValueMask(valuemask) unsigned int valuemask;
static char* IsHint(is_hint) char is_hint;
{
switch (is_hint) {
- case NotifyNormal: return ("NotifyNormal");
+ case NotifyNormal:
+ return ("NotifyNormal");
- case NotifyHint: return ("NotifyHint");
+ case NotifyHint:
+ return ("NotifyHint");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -182,11 +195,14 @@ static char* MaybeNone(value) int value;
static char* ColormapState(state) int state;
{
switch (state) {
- case ColormapInstalled: return ("ColormapInstalled");
+ case ColormapInstalled:
+ return ("ColormapInstalled");
- case ColormapUninstalled: return ("ColormapUninstalled");
+ case ColormapUninstalled:
+ return ("ColormapUninstalled");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -194,17 +210,23 @@ static char* ColormapState(state) int state;
static char* CrossingDetail(detail) int detail;
{
switch (detail) {
- case NotifyAncestor: return ("NotifyAncestor");
+ case NotifyAncestor:
+ return ("NotifyAncestor");
- case NotifyInferior: return ("NotifyInferior");
+ case NotifyInferior:
+ return ("NotifyInferior");
- case NotifyVirtual: return ("NotifyVirtual");
+ case NotifyVirtual:
+ return ("NotifyVirtual");
- case NotifyNonlinear: return ("NotifyNonlinear");
+ case NotifyNonlinear:
+ return ("NotifyNonlinear");
- case NotifyNonlinearVirtual: return ("NotifyNonlinearVirtual");
+ case NotifyNonlinearVirtual:
+ return ("NotifyNonlinearVirtual");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -212,23 +234,32 @@ static char* CrossingDetail(detail) int detail;
static char* FocusChangeDetail(detail) int detail;
{
switch (detail) {
- case NotifyAncestor: return ("NotifyAncestor");
+ case NotifyAncestor:
+ return ("NotifyAncestor");
- case NotifyInferior: return ("NotifyInferior");
+ case NotifyInferior:
+ return ("NotifyInferior");
- case NotifyVirtual: return ("NotifyVirtual");
+ case NotifyVirtual:
+ return ("NotifyVirtual");
- case NotifyNonlinear: return ("NotifyNonlinear");
+ case NotifyNonlinear:
+ return ("NotifyNonlinear");
- case NotifyNonlinearVirtual: return ("NotifyNonlinearVirtual");
+ case NotifyNonlinearVirtual:
+ return ("NotifyNonlinearVirtual");
- case NotifyPointer: return ("NotifyPointer");
+ case NotifyPointer:
+ return ("NotifyPointer");
- case NotifyPointerRoot: return ("NotifyPointerRoot");
+ case NotifyPointerRoot:
+ return ("NotifyPointerRoot");
- case NotifyDetailNone: return ("NotifyDetailNone");
+ case NotifyDetailNone:
+ return ("NotifyDetailNone");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -236,17 +267,23 @@ static char* FocusChangeDetail(detail) int detail;
static char* ConfigureDetail(detail) int detail;
{
switch (detail) {
- case Above: return ("Above");
+ case Above:
+ return ("Above");
- case Below: return ("Below");
+ case Below:
+ return ("Below");
- case TopIf: return ("TopIf");
+ case TopIf:
+ return ("TopIf");
- case BottomIf: return ("BottomIf");
+ case BottomIf:
+ return ("BottomIf");
- case Opposite: return ("Opposite");
+ case Opposite:
+ return ("Opposite");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -254,15 +291,20 @@ static char* ConfigureDetail(detail) int detail;
static char* GrabMode(mode) int mode;
{
switch (mode) {
- case NotifyNormal: return ("NotifyNormal");
+ case NotifyNormal:
+ return ("NotifyNormal");
- case NotifyGrab: return ("NotifyGrab");
+ case NotifyGrab:
+ return ("NotifyGrab");
- case NotifyUngrab: return ("NotifyUngrab");
+ case NotifyUngrab:
+ return ("NotifyUngrab");
- case NotifyWhileGrabbed: return ("NotifyWhileGrabbed");
+ case NotifyWhileGrabbed:
+ return ("NotifyWhileGrabbed");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -270,13 +312,17 @@ static char* GrabMode(mode) int mode;
static char* MappingRequest(request) int request;
{
switch (request) {
- case MappingModifier: return ("MappingModifier");
+ case MappingModifier:
+ return ("MappingModifier");
- case MappingKeyboard: return ("MappingKeyboard");
+ case MappingKeyboard:
+ return ("MappingKeyboard");
- case MappingPointer: return ("MappingPointer");
+ case MappingPointer:
+ return ("MappingPointer");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -284,11 +330,14 @@ static char* MappingRequest(request) int request;
static char* Place(place) int place;
{
switch (place) {
- case PlaceOnTop: return ("PlaceOnTop");
+ case PlaceOnTop:
+ return ("PlaceOnTop");
- case PlaceOnBottom: return ("PlaceOnBottom");
+ case PlaceOnBottom:
+ return ("PlaceOnBottom");
- default: return ("?");
+ default:
+ return ("?");
}
}
@@ -298,11 +347,15 @@ static char* MajorCode(code) int code;
static char buffer[32];
switch (code) {
- case X_CopyArea: return ("X_CopyArea");
+ case X_CopyArea:
+ return ("X_CopyArea");
- case X_CopyPlane: return ("X_CopyPlane");
+ case X_CopyPlane:
+ return ("X_CopyPlane");
- default: sprintf(buffer, "0x%x", code); return (buffer);
+ default:
+ sprintf(buffer, "0x%x", code);
+ return (buffer);
}
}
@@ -330,12 +383,12 @@ static char* Keycode(ev) XKeyEvent* ev;
}
/* Returns the string equivalent of an atom or "None"*/
-static char*
-AtomName(Display* dpy, Atom atom) {
+static char* AtomName(Display* dpy, Atom atom) {
static char buffer[256];
char* atom_name;
- if (atom == None) return ("None");
+ if (atom == None)
+ return ("None");
atom_name = XGetAtomName(dpy, atom);
strncpy(buffer, atom_name, 256);
@@ -347,8 +400,7 @@ AtomName(Display* dpy, Atom atom) {
/**** Routines to print out readable values for the field of various events ***/
/******************************************************************************/
-static void
-VerbMotion(XMotionEvent* ev) {
+static void VerbMotion(XMotionEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("root=0x%x%s", (unsigned)ev->root, sep);
printf("subwindow=0x%x%s", (unsigned)ev->subwindow, sep);
@@ -360,8 +412,7 @@ VerbMotion(XMotionEvent* ev) {
printf("same_screen=%s\n", TorF(ev->same_screen));
}
-static void
-VerbButton(XButtonEvent* ev) {
+static void VerbButton(XButtonEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("root=0x%x%s", (unsigned)ev->root, sep);
printf("subwindow=0x%x%s", (unsigned)ev->subwindow, sep);
@@ -373,16 +424,14 @@ VerbButton(XButtonEvent* ev) {
printf("same_screen=%s\n", TorF(ev->same_screen));
}
-static void
-VerbColormap(XColormapEvent* ev) {
+static void VerbColormap(XColormapEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("colormap=%s%s", MaybeNone(ev->colormap), sep);
printf("new=%s%s", TorF(ev->new), sep);
printf("state=%s\n", ColormapState(ev->state));
}
-static void
-VerbCrossing(XCrossingEvent* ev) {
+static void VerbCrossing(XCrossingEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("root=0x%x%s", (unsigned)ev->root, sep);
printf("subwindow=0x%x%s", (unsigned)ev->subwindow, sep);
@@ -396,16 +445,14 @@ VerbCrossing(XCrossingEvent* ev) {
printf("state=%s\n", ButtonAndOrModifierState(ev->state));
}
-static void
-VerbExpose(XExposeEvent* ev) {
+static void VerbExpose(XExposeEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("x=%d y=%d%s", ev->x, ev->y, sep);
printf("width=%d height=%d%s", ev->width, ev->height, sep);
printf("count=%d\n", ev->count);
}
-static void
-VerbGraphicsExpose(XGraphicsExposeEvent* ev) {
+static void VerbGraphicsExpose(XGraphicsExposeEvent* ev) {
printf("drawable=0x%x%s", (unsigned)ev->drawable, sep);
printf("x=%d y=%d%s", ev->x, ev->y, sep);
printf("width=%d height=%d%s", ev->width, ev->height, sep);
@@ -413,32 +460,29 @@ VerbGraphicsExpose(XGraphicsExposeEvent* ev) {
printf("minor_code=%d\n", ev->minor_code);
}
-static void
-VerbNoExpose(XNoExposeEvent* ev) {
+static void VerbNoExpose(XNoExposeEvent* ev) {
printf("drawable=0x%x%s", (unsigned)ev->drawable, sep);
printf("major_code=%s%s", MajorCode(ev->major_code), sep);
printf("minor_code=%d\n", ev->minor_code);
}
-static void
-VerbFocus(XFocusChangeEvent* ev) {
+static void VerbFocus(XFocusChangeEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("mode=%s%s", GrabMode(ev->mode), sep);
printf("detail=%s\n", FocusChangeDetail(ev->detail));
}
-static void
-VerbKeymap(XKeymapEvent* ev) {
+static void VerbKeymap(XKeymapEvent* ev) {
int i;
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("key_vector=");
- for (i = 0; i < 32; i++) printf("%02x", ev->key_vector[i]);
+ for (i = 0; i < 32; i++)
+ printf("%02x", ev->key_vector[i]);
printf("\n");
}
-static void
-VerbKey(XKeyEvent* ev) {
+static void VerbKey(XKeyEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("root=0x%x%s", (unsigned)ev->root, sep);
printf("subwindow=0x%x%s", (unsigned)ev->subwindow, sep);
@@ -450,29 +494,25 @@ VerbKey(XKeyEvent* ev) {
printf("same_screen=%s\n", TorF(ev->same_screen));
}
-static void
-VerbProperty(XPropertyEvent* ev) {
+static void VerbProperty(XPropertyEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("atom=%s%s", AtomName(ev->display, ev->atom), sep);
printf("time=%s%s", ServerTime(ev->time), sep);
printf("state=%s\n", PropertyState(ev->state));
}
-static void
-VerbResizeRequest(XResizeRequestEvent* ev) {
+static void VerbResizeRequest(XResizeRequestEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("width=%d height=%d\n", ev->width, ev->height);
}
-static void
-VerbCirculate(XCirculateEvent* ev) {
+static void VerbCirculate(XCirculateEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("place=%s\n", Place(ev->place));
}
-static void
-VerbConfigure(XConfigureEvent* ev) {
+static void VerbConfigure(XConfigureEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("x=%d y=%d%s", ev->x, ev->y, sep);
@@ -482,8 +522,7 @@ VerbConfigure(XConfigureEvent* ev) {
printf("override_redirect=%s\n", TorF(ev->override_redirect));
}
-static void
-VerbCreateWindow(XCreateWindowEvent* ev) {
+static void VerbCreateWindow(XCreateWindowEvent* ev) {
printf("parent=0x%x%s", (unsigned)ev->parent, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("x=%d y=%d%s", ev->x, ev->y, sep);
@@ -492,28 +531,24 @@ VerbCreateWindow(XCreateWindowEvent* ev) {
printf("override_redirect=%s\n", TorF(ev->override_redirect));
}
-static void
-VerbDestroyWindow(XDestroyWindowEvent* ev) {
+static void VerbDestroyWindow(XDestroyWindowEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x\n", (unsigned)ev->window);
}
-static void
-VerbGravity(XGravityEvent* ev) {
+static void VerbGravity(XGravityEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("x=%d y=%d\n", ev->x, ev->y);
}
-static void
-VerbMap(XMapEvent* ev) {
+static void VerbMap(XMapEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("override_redirect=%s\n", TorF(ev->override_redirect));
}
-static void
-VerbReparent(XReparentEvent* ev) {
+static void VerbReparent(XReparentEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("parent=0x%x%s", (unsigned)ev->parent, sep);
@@ -521,22 +556,19 @@ VerbReparent(XReparentEvent* ev) {
printf("override_redirect=%s\n", TorF(ev->override_redirect));
}
-static void
-VerbUnmap(XUnmapEvent* ev) {
+static void VerbUnmap(XUnmapEvent* ev) {
printf("event=0x%x%s", (unsigned)ev->event, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("from_configure=%s\n", TorF(ev->from_configure));
}
-static void
-VerbCirculateRequest(XCirculateRequestEvent* ev) {
+static void VerbCirculateRequest(XCirculateRequestEvent* ev) {
printf("parent=0x%x%s", (unsigned)ev->parent, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("place=%s\n", Place(ev->place));
}
-static void
-VerbConfigureRequest(XConfigureRequestEvent* ev) {
+static void VerbConfigureRequest(XConfigureRequestEvent* ev) {
printf("parent=0x%x%s", (unsigned)ev->parent, sep);
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("x=%d y=%d%s", ev->x, ev->y, sep);
@@ -547,41 +579,37 @@ VerbConfigureRequest(XConfigureRequestEvent* ev) {
printf("value_mask=%s\n", ConfigureValueMask(ev->value_mask));
}
-static void
-VerbMapRequest(XMapRequestEvent* ev) {
+static void VerbMapRequest(XMapRequestEvent* ev) {
printf("parent=0x%x%s", (unsigned)ev->parent, sep);
printf("window=0x%x\n", (unsigned)ev->window);
}
-static void
-VerbClient(XClientMessageEvent* ev) {
+static void VerbClient(XClientMessageEvent* ev) {
int i;
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("message_type=%s%s", AtomName(ev->display, ev->message_type), sep);
printf("format=%d\n", ev->format);
printf("data (shown as longs)=");
- for (i = 0; i < 5; i++) printf(" 0x%08lx", ev->data.l[i]);
+ for (i = 0; i < 5; i++)
+ printf(" 0x%08lx", ev->data.l[i]);
printf("\n");
}
-static void
-VerbMapping(XMappingEvent* ev) {
+static void VerbMapping(XMappingEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("request=%s%s", MappingRequest(ev->request), sep);
printf("first_keycode=0x%x%s", ev->first_keycode, sep);
printf("count=0x%x\n", ev->count);
}
-static void
-VerbSelectionClear(XSelectionClearEvent* ev) {
+static void VerbSelectionClear(XSelectionClearEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("selection=%s%s", AtomName(ev->display, ev->selection), sep);
printf("time=%s\n", ServerTime(ev->time));
}
-static void
-VerbSelection(XSelectionEvent* ev) {
+static void VerbSelection(XSelectionEvent* ev) {
printf("requestor=0x%x%s", (unsigned)ev->requestor, sep);
printf("selection=%s%s", AtomName(ev->display, ev->selection), sep);
printf("target=%s%s", AtomName(ev->display, ev->target), sep);
@@ -589,8 +617,7 @@ VerbSelection(XSelectionEvent* ev) {
printf("time=%s\n", ServerTime(ev->time));
}
-static void
-VerbSelectionRequest(XSelectionRequestEvent* ev) {
+static void VerbSelectionRequest(XSelectionRequestEvent* ev) {
printf("owner=0x%x%s", (unsigned)ev->owner, sep);
printf("requestor=0x%x%s", (unsigned)ev->requestor, sep);
printf("selection=%s%s", AtomName(ev->display, ev->selection), sep);
@@ -599,8 +626,7 @@ VerbSelectionRequest(XSelectionRequestEvent* ev) {
printf("time=%s\n", ServerTime(ev->time));
}
-static void
-VerbVisibility(XVisibilityEvent* ev) {
+static void VerbVisibility(XVisibilityEvent* ev) {
printf("window=0x%x%s", (unsigned)ev->window, sep);
printf("state=%s\n", VisibilityState(ev->state));
}
@@ -612,39 +638,72 @@ VerbVisibility(XVisibilityEvent* ev) {
char* GetType(ev) XEvent* ev;
{
switch (ev->type) {
- case KeyPress: return ("KeyPress");
- case KeyRelease: return ("KeyRelease");
- case ButtonPress: return ("ButtonPress");
- case ButtonRelease: return ("ButtonRelease");
- case MotionNotify: return ("MotionNotify");
- case EnterNotify: return ("EnterNotify");
- case LeaveNotify: return ("LeaveNotify");
- case FocusIn: return ("FocusIn");
- case FocusOut: return ("FocusOut");
- case KeymapNotify: return ("KeymapNotify");
- case Expose: return ("Expose");
- case GraphicsExpose: return ("GraphicsExpose");
- case NoExpose: return ("NoExpose");
- case VisibilityNotify: return ("VisibilityNotify");
- case CreateNotify: return ("CreateNotify");
- case DestroyNotify: return ("DestroyNotify");
- case UnmapNotify: return ("UnmapNotify");
- case MapNotify: return ("MapNotify");
- case MapRequest: return ("MapRequest");
- case ReparentNotify: return ("ReparentNotify");
- case ConfigureNotify: return ("ConfigureNotify");
- case ConfigureRequest: return ("ConfigureRequest");
- case GravityNotify: return ("GravityNotify");
- case ResizeRequest: return ("ResizeRequest");
- case CirculateNotify: return ("CirculateNotify");
- case CirculateRequest: return ("CirculateRequest");
- case PropertyNotify: return ("PropertyNotify");
- case SelectionClear: return ("SelectionClear");
- case SelectionRequest: return ("SelectionRequest");
- case SelectionNotify: return ("SelectionNotify");
- case ColormapNotify: return ("ColormapNotify");
- case ClientMessage: return ("ClientMessage");
- case MappingNotify: return ("MappingNotify");
+ case KeyPress:
+ return ("KeyPress");
+ case KeyRelease:
+ return ("KeyRelease");
+ case ButtonPress:
+ return ("ButtonPress");
+ case ButtonRelease:
+ return ("ButtonRelease");
+ case MotionNotify:
+ return ("MotionNotify");
+ case EnterNotify:
+ return ("EnterNotify");
+ case LeaveNotify:
+ return ("LeaveNotify");
+ case FocusIn:
+ return ("FocusIn");
+ case FocusOut:
+ return ("FocusOut");
+ case KeymapNotify:
+ return ("KeymapNotify");
+ case Expose:
+ return ("Expose");
+ case GraphicsExpose:
+ return ("GraphicsExpose");
+ case NoExpose:
+ return ("NoExpose");
+ case VisibilityNotify:
+ return ("VisibilityNotify");
+ case CreateNotify:
+ return ("CreateNotify");
+ case DestroyNotify:
+ return ("DestroyNotify");
+ case UnmapNotify:
+ return ("UnmapNotify");
+ case MapNotify:
+ return ("MapNotify");
+ case MapRequest:
+ return ("MapRequest");
+ case ReparentNotify:
+ return ("ReparentNotify");
+ case ConfigureNotify:
+ return ("ConfigureNotify");
+ case ConfigureRequest:
+ return ("ConfigureRequest");
+ case GravityNotify:
+ return ("GravityNotify");
+ case ResizeRequest:
+ return ("ResizeRequest");
+ case CirculateNotify:
+ return ("CirculateNotify");
+ case CirculateRequest:
+ return ("CirculateRequest");
+ case PropertyNotify:
+ return ("PropertyNotify");
+ case SelectionClear:
+ return ("SelectionClear");
+ case SelectionRequest:
+ return ("SelectionRequest");
+ case SelectionNotify:
+ return ("SelectionNotify");
+ case ColormapNotify:
+ return ("ColormapNotify");
+ case ClientMessage:
+ return ("ClientMessage");
+ case MappingNotify:
+ return ("MappingNotify");
}
return "???";
}
@@ -653,8 +712,7 @@ char* GetType(ev) XEvent* ev;
/**************** Print the values of all fields for any event ****************/
/******************************************************************************/
-void
-ShowEvent(XEvent* eev) {
+void ShowEvent(XEvent* eev) {
XAnyEvent* ev = (XAnyEvent*)eev;
/* determine which field separator to use */
if (use_separate_lines)
@@ -668,66 +726,124 @@ ShowEvent(XEvent* eev) {
printf("display=0x%p%s", ev->display, sep);
switch (ev->type) {
- case MotionNotify: VerbMotion((void*)ev); break;
+ case MotionNotify:
+ VerbMotion((void*)ev);
+ break;
case ButtonPress:
- case ButtonRelease: VerbButton((void*)ev); break;
+ case ButtonRelease:
+ VerbButton((void*)ev);
+ break;
- case ColormapNotify: VerbColormap((void*)ev); break;
+ case ColormapNotify:
+ VerbColormap((void*)ev);
+ break;
case EnterNotify:
- case LeaveNotify: VerbCrossing((void*)ev); break;
+ case LeaveNotify:
+ VerbCrossing((void*)ev);
+ break;
- case Expose: VerbExpose((void*)ev); break;
+ case Expose:
+ VerbExpose((void*)ev);
+ break;
- case GraphicsExpose: VerbGraphicsExpose((void*)ev); break;
+ case GraphicsExpose:
+ VerbGraphicsExpose((void*)ev);
+ break;
- case NoExpose: VerbNoExpose((void*)ev); break;
+ case NoExpose:
+ VerbNoExpose((void*)ev);
+ break;
case FocusIn:
- case FocusOut: VerbFocus((void*)ev); break;
+ case FocusOut:
+ VerbFocus((void*)ev);
+ break;
- case KeymapNotify: VerbKeymap((void*)ev); break;
+ case KeymapNotify:
+ VerbKeymap((void*)ev);
+ break;
case KeyPress:
- case KeyRelease: VerbKey((void*)ev); break;
+ case KeyRelease:
+ VerbKey((void*)ev);
+ break;
- case PropertyNotify: VerbProperty((void*)ev); break;
+ case PropertyNotify:
+ VerbProperty((void*)ev);
+ break;
- case ResizeRequest: VerbResizeRequest((void*)ev); break;
+ case ResizeRequest:
+ VerbResizeRequest((void*)ev);
+ break;
- case CirculateNotify: VerbCirculate((void*)ev); break;
+ case CirculateNotify:
+ VerbCirculate((void*)ev);
+ break;
- case ConfigureNotify: VerbConfigure((void*)ev); break;
+ case ConfigureNotify:
+ VerbConfigure((void*)ev);
+ break;
- case CreateNotify: VerbCreateWindow((void*)ev); break;
+ case CreateNotify:
+ VerbCreateWindow((void*)ev);
+ break;
- case DestroyNotify: VerbDestroyWindow((void*)ev); break;
+ case DestroyNotify:
+ VerbDestroyWindow((void*)ev);
+ break;
- case GravityNotify: VerbGravity((void*)ev); break;
+ case GravityNotify:
+ VerbGravity((void*)ev);
+ break;
- case MapNotify: VerbMap((void*)ev); break;
+ case MapNotify:
+ VerbMap((void*)ev);
+ break;
- case ReparentNotify: VerbReparent((void*)ev); break;
+ case ReparentNotify:
+ VerbReparent((void*)ev);
+ break;
- case UnmapNotify: VerbUnmap((void*)ev); break;
+ case UnmapNotify:
+ VerbUnmap((void*)ev);
+ break;
- case CirculateRequest: VerbCirculateRequest((void*)ev); break;
+ case CirculateRequest:
+ VerbCirculateRequest((void*)ev);
+ break;
- case ConfigureRequest: VerbConfigureRequest((void*)ev); break;
+ case ConfigureRequest:
+ VerbConfigureRequest((void*)ev);
+ break;
- case MapRequest: VerbMapRequest((void*)ev); break;
+ case MapRequest:
+ VerbMapRequest((void*)ev);
+ break;
- case ClientMessage: VerbClient((void*)ev); break;
+ case ClientMessage:
+ VerbClient((void*)ev);
+ break;
- case MappingNotify: VerbMapping((void*)ev); break;
+ case MappingNotify:
+ VerbMapping((void*)ev);
+ break;
- case SelectionClear: VerbSelectionClear((void*)ev); break;
+ case SelectionClear:
+ VerbSelectionClear((void*)ev);
+ break;
- case SelectionNotify: VerbSelection((void*)ev); break;
+ case SelectionNotify:
+ VerbSelection((void*)ev);
+ break;
- case SelectionRequest: VerbSelectionRequest((void*)ev); break;
+ case SelectionRequest:
+ VerbSelectionRequest((void*)ev);
+ break;
- case VisibilityNotify: VerbVisibility((void*)ev); break;
+ case VisibilityNotify:
+ VerbVisibility((void*)ev);
+ break;
}
}