Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added extra debug info for UserStats #58

Merged
merged 1 commit into from
May 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified binary/XCB-TRL/icccm.o
Binary file not shown.
Binary file modified binary/XCB-TRL/xcb_trl.o
Binary file not shown.
Binary file modified binary/XCB-TRL/xcb_winutil.o
Binary file not shown.
Binary file modified binary/bar.o
Binary file not shown.
Binary file modified binary/dwm
Binary file not shown.
Binary file modified binary/dwm.o
Binary file not shown.
Binary file modified binary/events.o
Binary file not shown.
Binary file modified binary/parser.o
Binary file not shown.
Binary file modified binary/settings.o
Binary file not shown.
Binary file modified binary/toggle.o
Binary file not shown.
Binary file modified binary/util.o
Binary file not shown.
3 changes: 1 addition & 2 deletions dwm.c
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ applysizehints(Client *c, i32 *x, i32 *y, i32 *width, i32 *height, uint8_t inter
return *x != c->x || *y != c->y || *width != c->w || *height != c->h;
}

void
void
arrangeq(Desktop *desk)
{
Client *c;
Expand Down Expand Up @@ -2144,7 +2144,6 @@ void
restack(Desktop *desk)
{
Client *c;
Client *cr;
XCBWindowChanges wc;

wc.stack_mode = XCB_STACK_MODE_BELOW;
Expand Down
32 changes: 30 additions & 2 deletions toggle.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,25 @@ UserStats(const Arg *arg)
Client *c = _wm.selmon->desksel->sel;

if(c)
{ DEBUG("(x: %d, y: %d, w: %u, h: %u)", c->x, c->y, c->w, c->h);
{
XCBARGB argb;
argb.argb = c->bcol;
DEBUG("(x: %d, y: %d, w: %u, h: %u)", c->x, c->y, c->w, c->h);
DEBUG("(ox: %d, oy: %d, ow: %u, oh: %u)", c->oldx, c->oldy, c->oldw, c->oldh);
DEBUG("NETNAME: %s", c->netwmname);
DEBUG("WMNAME: %s", c->wmname);
DEBUG("CLASSNAME: %s", c->classname);
DEBUG("INSTANCENAME:%s", c->instancename);
DEBUG("WindowID: %u", c->win);
DEBUG("PID: %u", c->pid);
DEBUG("RBGA: (%u, %u, %u, %u)", argb.r, argb.g, argb.b, argb.a);
DEBUG("BorderWidth: %u", c->bw);
DEBUG("MINW: %u", c->minw);
DEBUG("MINH: %u", c->minh);
DEBUG("MAXW: %u", c->maxw);
DEBUG("MAXH: %u", c->maxh);
DEBUG("INCW: %d", c->incw);
DEBUG("INCH: %d", c->inch);
}
else
{ DEBUG0("NULL");
Expand Down Expand Up @@ -160,6 +173,14 @@ DragWindow(
break;
}
}
else if(XCB_EVENT_RESPONSE_TYPE(ev) == XCB_DESTROY_NOTIFY)
{ XCBDestroyNotifyEvent *dev = (XCBDestroyNotifyEvent *)ev;
if(dev->window == win)
{ free(ev);
win = 0;
break;
}
}
free(ev);
}
} while(_wm.running && !XCBNextEvent(_wm.dpy, &ev) && XCB_EVENT_RESPONSE_TYPE(ev) != XCB_BUTTON_RELEASE);
Expand Down Expand Up @@ -204,7 +225,6 @@ ResizeWindow(const Arg *arg)

XCBDisplay *display = _wm.dpy;
XCBWindow win = c->win;
const int MIN_SIZE = 1;

i16 curx, cury;
i32 oldw, oldh;
Expand Down Expand Up @@ -302,6 +322,14 @@ ResizeWindow(const Arg *arg)
break;
}
}
else if(XCB_EVENT_RESPONSE_TYPE(ev) == XCB_DESTROY_NOTIFY)
{ XCBDestroyNotifyEvent *dev = (XCBDestroyNotifyEvent *)ev;
if(dev->window == win)
{ free(ev);
win = 0;
break;
}
}
free(ev);
}
} while(_wm.running && !XCBNextEvent(_wm.dpy, &ev) && XCB_EVENT_RESPONSE_TYPE(ev) != XCB_BUTTON_RELEASE);
Expand Down