rem: smartPlaceWindow(wwin, x_ret, y_ret, width, height);
add: smartPlaceWindow(wwin, x_ret, y_ret, width, height, usableArea);
context: PlaceWindow(WWindow *wwin, int *x_ret, int *y_ret,            unsigned width, unsigned height){    WScreen *scr = wwin->screen_ptr;    int h = WMFontHeight(scr->title_font) + (wPreferences.window_title_clearance + TITLEBAR_EXTEND_SPACE) * 2;    switch (wPreferences.window_placement) {     case WPM_MANUAL:	InteractivePlaceWindow(wwin, x_ret, y_ret, width, height);	break;     case WPM_SMART:	smartPlaceWindow(wwin, x_ret, y_ret, width, height);	break;     case WPM_AUTO:	if (autoPlaceWindow(wwin, x_ret, y_ret, width, height, 0)) {	    break;	} else if (autoPlaceWindow(wwin, x_ret, y_ret, width, height, 1)) {	    break;	}	/* there isn't a break here, because if we fail, it should fall	   through to cascade placement, as people who want tiling want	   automagicness aren't going to want to place their window */     case WPM_CASCADE:        if (wPreferences.window_placement == WPM_AUTO)            scr->cascade_index++;	cascadeWindow(scr, wwin, x_ret, y_ret, width, height, h);        if (wPreferences.window_placement == WPM_CASCADE)            scr->cascade_index++;	break;     case WPM_RANDOM:	{	    int w, h, extra_height;	    WArea usableArea = scr->totalUsableArea;            if (wwin->frame)                extra_height = wwin->frame->top_width + wwin->frame->bottom_width + 2;            else                extra_height = 24; /* random value */	    w = ((usableArea.x2-X_ORIGIN(scr)) - width);	    h = ((usableArea.y2-Y_ORIGIN(scr)) - height - extra_height);	    if (w<1) w = 1;	    if (h<1) h = 1;	    *x_ret = X_ORIGIN(scr) + rand()%w;	    *y_ret = Y_ORIGIN(scr) + rand()%h;	}	break;#ifdef DEBUG	     default:	puts("Invalid window placement!!!");	*x_ret = 0;	*y_ret = 0;#endif    }        if (*x_ret + width > scr->scr_width)	*x_ret = scr->scr_width - width;    if (*x_ret < 0)        *x_ret = 0;    if (*y_ret + height > scr->scr_height)	*y_ret = scr->scr_height - height;    if (*y_ret < 0)        *y_ret = 0;}