place randomly inside the area available. if its too big, put the top left corner inside still
Dana Jansens danakj@orodu.net
1 files changed,
2 insertions(+),
2 deletions(-)
jump to
M
openbox/place.c
→
openbox/place.c
@@ -126,9 +126,9 @@ r = areas[i]->x + areas[i]->width - client->frame->area.width;
b = areas[i]->y + areas[i]->height - client->frame->area.height; if (r > l) *x = g_random_int_range(l, r + 1); - else *x = 0; + else *x = areas[i]->x; if (b > t) *y = g_random_int_range(t, b + 1); - else *y = 0; + else *y = areas[i]->y; g_free(areas);