Skip to content

Commit e7078c0

Browse files
committed
do not try to draw 0 width/height windows
Ref: #76 (comment)
1 parent 99c1cbc commit e7078c0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/selection_wind.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,9 @@ void selectionWindDraw(void)
9494
opt.lineWidth }
9595
};
9696

97+
if (sel->rect.w == 0 || sel->rect.h == 0)
98+
return;
99+
97100
for (size_t i = 0; i < ARRAY_COUNT(pw->windows); ++i) {
98101
XRectangle *rp = rects + i;
99102
XMoveResizeWindow(disp, pw->windows[i], rp->x, rp->y, rp->width, rp->height);

0 commit comments

Comments
 (0)