Index: libwnck/libwnck-2.14.1/libwnck/window.c
===================================================================
--- libwnck.orig/libwnck-2.14.1/libwnck/window.c	2006-05-25 22:57:44.000000000 +0100
+++ libwnck/libwnck-2.14.1/libwnck/window.c	2006-05-25 23:23:35.000000000 +0100
@@ -1521,6 +1521,42 @@
 }
 
 /**
+ * wnck_window_set_geometry:
+ * @window: a #WnckWindow
+ * @gravity:
+ * @source:
+ * @x: new X coordinate of window, -1 means don't modify
+ * @y: new Y coordinate of window, -1 means don't modify
+ * @width: new width of window, -1 means don't modify
+ * @height: new height of window, -1 means don't modify
+ *
+ * Sets the size and position of the window.
+ *
+ **/
+void
+wnck_window_set_geometry (WnckWindow               *window,
+                          WnckWindowGravity         gravity,
+                          WnckWindowSource          source,
+                          WnckWindowResizePresence  geometry_mask,
+                          int                       x,
+                          int                       y,
+                          int                       width,
+                          int                       height)
+{
+  int gravity_flags;
+
+  g_return_if_fail (WNCK_IS_WINDOW (window));
+
+  gravity_flags = gravity;
+  gravity_flags |= source << 8;
+  gravity_flags |= source << 12;
+
+  _wnck_set_window_geometry (WNCK_SCREEN_XSCREEN (window->priv->screen),
+                             window->priv->xwindow,
+                             gravity_flags, x, y, width, height);
+}
+
+/**
  * wnck_window_is_visible_on_workspace:
  * @window: a #WnckWindow
  * @workspace: a #WnckWorkspace
Index: libwnck/libwnck-2.14.1/libwnck/window.h
===================================================================
--- libwnck.orig/libwnck-2.14.1/libwnck/window.h	2006-05-25 22:57:44.000000000 +0100
+++ libwnck/libwnck-2.14.1/libwnck/window.h	2006-05-25 23:20:59.000000000 +0100
@@ -83,6 +83,34 @@
   WNCK_WINDOW_SPLASHSCREEN  /* splash screen */
 } WnckWindowType;
 
+typedef enum
+{
+  WNCK_WINDOW_GRAVITY_NORTHWEST = 1,
+  WNCK_WINDOW_GRAVITY_NORTH,
+  WNCK_WINDOW_GRAVITY_NORTHEAST,
+  WNCK_WINDOW_GRAVITY_WEST,
+  WNCK_WINDOW_GRAVITY_CENTER,
+  WNCK_WINDOW_GRAVITY_EAST,
+  WNCK_WINDOW_GRAVITY_SOUTHWEST,
+  WNCK_WINDOW_GRAVITY_SOUTH,
+  WNCK_WINDOW_GRAVITY_SOUTHEAST
+} WnckWindowGravity;
+
+typedef enum
+{
+  WNCK_WINDOW_RESIZE_X      = 1 << 0,
+  WNCK_WINDOW_RESIZE_Y      = 1 << 1,
+  WNCK_WINDOW_RESIZE_WIDTH  = 1 << 2,
+  WNCK_WINDOW_RESIZE_HEIGHT = 1 << 3,
+} WnckWindowResizePresence;
+
+typedef enum
+{
+  WNCK_WINDOW_SOURCE_APPLICATION = 1,
+  WNCK_WINDOW_SOURCE_PAGER       = 2,
+  WNCK_WINDOW_SOURCE_TASKBAR     = 2
+} WnckWindowSource;
+
 #define WNCK_TYPE_WINDOW              (wnck_window_get_type ())
 #define WNCK_WINDOW(object)           (G_TYPE_CHECK_INSTANCE_CAST ((object), WNCK_TYPE_WINDOW, WnckWindow))
 #define WNCK_WINDOW_CLASS(klass)      (G_TYPE_CHECK_CLASS_CAST ((klass), WNCK_TYPE_WINDOW, WnckWindowClass))
@@ -230,6 +258,14 @@
                                int        *yp,
                                int        *widthp,
                                int        *heightp);
+void wnck_window_set_geometry (WnckWindow               *window,
+                               WnckWindowGravity         gravity,
+                               WnckWindowSource          source,
+                               WnckWindowResizePresence  geometry_mask,
+                               int                       x,
+                               int                       y,
+                               int                       width,
+                               int                       height);
 
 gboolean wnck_window_is_visible_on_workspace (WnckWindow    *window,
                                               WnckWorkspace *workspace);
Index: libwnck/libwnck-2.14.1/libwnck/xutils.c
===================================================================
--- libwnck.orig/libwnck-2.14.1/libwnck/xutils.c	2006-05-25 22:57:54.000000000 +0100
+++ libwnck/libwnck-2.14.1/libwnck/xutils.c	2006-05-25 22:58:11.000000000 +0100
@@ -2232,6 +2232,36 @@
     *heightp = height;
 }
 
+void _wnck_set_window_geometry (Screen *screen,
+				Window  xwindow,
+                                int     grflags,
+                                int     x,
+                                int     y,
+                                int     width,
+                                int     height)
+{
+  XEvent xev;
+
+  xev.xclient.type = ClientMessage;
+  xev.xclient.serial = 0;
+  xev.xclient.send_event = True;
+  xev.xclient.display = gdk_display;
+  xev.xclient.window = xwindow;
+  xev.xclient.message_type = _wnck_atom_get ("_NET_MOVERESIZE_WINDOW");
+  xev.xclient.format = 32;
+  xev.xclient.data.l[0] = grflags;
+  xev.xclient.data.l[1] = x;
+  xev.xclient.data.l[2] = y;
+  xev.xclient.data.l[3] = width;
+  xev.xclient.data.l[4] = height;
+
+  XSendEvent (gdk_display,
+              RootWindowOfScreen (screen),
+              False,
+              SubstructureRedirectMask | SubstructureNotifyMask,
+              &xev);
+}
+
 void
 _wnck_get_window_position (Screen *screen,
 			   Window  xwindow,
Index: libwnck/libwnck-2.14.1/libwnck/xutils.h
===================================================================
--- libwnck.orig/libwnck-2.14.1/libwnck/xutils.h	2006-05-25 22:57:54.000000000 +0100
+++ libwnck/libwnck-2.14.1/libwnck/xutils.h	2006-05-25 22:58:11.000000000 +0100
@@ -163,6 +163,13 @@
                                 int    *yp,
                                 int    *widthp,
                                 int    *heightp);
+void _wnck_set_window_geometry (Screen *screen,
+				Window  xwindow,
+                                int     grflags,
+                                int     x,
+                                int     y,
+                                int     width,
+                                int     height);
 
 void _wnck_get_window_position (Screen *screen,
 				Window  xwindow,
