diff --git a/config.h b/config.h index 6184cef..13d5abe 100644 --- a/config.h +++ b/config.h @@ -3,7 +3,7 @@ /* appearance */ static const unsigned int borderpx = 6; /* border pixel of windows */ static const unsigned int gappx = 6; -static const unsigned int CORNER_RADIUS = 24; +static const unsigned int cornerrad = 20; static const unsigned int snap = 32; /* snap pixel */ static const int showbar = 1; /* 0 means no bar */ static const int topbar = 1; /* 0 means bottom bar */ diff --git a/dwm.c b/dwm.c index fbe8484..afb2239 100644 --- a/dwm.c +++ b/dwm.c @@ -1311,11 +1311,11 @@ resizeclient(Client *c, int x, int y, int w, int h) void drawroundedcorners(Client *c) { // if set to zero in config.h, do not attempt to round - if(CORNER_RADIUS < 0) return; + if(cornerrad < 0) return; // NOTE: this is extremely hacky and surely could be optimized. // Any X wizards out there reading this, please pull request. - if (CORNER_RADIUS > 0 && c && !c->isfullscreen) { + if (cornerrad > 0 && c && !c->isfullscreen) { Window win; win = c->win; if(!win) return; @@ -1324,7 +1324,7 @@ void drawroundedcorners(Client *c) { if(!XGetWindowAttributes(dpy, win, &win_attr)) return; // set in config.h: - int dia = 2 * CORNER_RADIUS; + int dia = 2 * cornerrad; int w = c->w; int h = c->h; if(w < dia || h < dia) return; @@ -1350,8 +1350,8 @@ void drawroundedcorners(Client *c) { XFillArc(dpy, mask, shape_gc, w-dia-1, 0, dia, dia, 0, 23040); XFillArc(dpy, mask, shape_gc, 0, h-dia-1, dia, dia, 0, 23040); XFillArc(dpy, mask, shape_gc, w-dia-1, h-dia-1, dia, dia, 0, 23040); - XFillRectangle(dpy, mask, shape_gc, CORNER_RADIUS, 0, w-dia, h); - XFillRectangle(dpy, mask, shape_gc, 0, CORNER_RADIUS, w, h-dia); + XFillRectangle(dpy, mask, shape_gc, cornerrad, 0, w-dia, h); + XFillRectangle(dpy, mask, shape_gc, 0, cornerrad, w, h-dia); XShapeCombineMask(dpy, win, ShapeBounding, 0, 0, mask, ShapeSet); XFreePixmap(dpy, mask); XFreeGC(dpy, shape_gc); diff --git a/dwm.o b/dwm.o index c5aae3f..b1ef4b4 100644 Binary files a/dwm.o and b/dwm.o differ