Index: constraints.c
===================================================================
RCS file: /cvs/gnome/metacity/src/constraints.c,v
retrieving revision 1.6
diff -p -u -r1.6 constraints.c
--- constraints.c	12 Mar 2003 03:56:01 -0000	1.6
+++ constraints.c	12 Mar 2003 05:28:59 -0000
@@ -352,10 +352,11 @@ get_outermost_onscreen_positions (MetaWi
                                   int                  *bottommost_y)
 {
   if (leftmost_x)
-    *leftmost_x = info->nw_x + TITLEBAR_LENGTH_ONSCREEN - orig->width;
+    *leftmost_x = info->nw_x  - orig->width +
+      MIN(TITLEBAR_LENGTH_ONSCREEN, orig->width/2);
 
   if (rightmost_x)
-    *rightmost_x = info->se_x - TITLEBAR_LENGTH_ONSCREEN;
+    *rightmost_x = info->se_x - MIN(TITLEBAR_LENGTH_ONSCREEN, orig->width/2);
 
   if (topmost_y)
     *topmost_y = info->nw_y + info->fgeom.top_height;
@@ -368,7 +369,7 @@ get_outermost_onscreen_positions (MetaWi
       if (window->frame)
         *bottommost_y = info->se_y;
       else
-        *bottommost_y = info->se_y - TITLEBAR_LENGTH_ONSCREEN;
+        *bottommost_y = info->se_y - MIN(TITLEBAR_LENGTH_ONSCREEN, orig->height/2);
     }
 }
 
