X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=hacks%2Fxscreensaver-sgigl.c;h=8d25ad14abf9b416522a5763ced6b33a9d41db9d;hb=3f438031d610c7e15fd33876a879b97e290e05fb;hp=a4247784efec9973e8d6ce5f989de7a888fe5ffc;hpb=df7adbee81405e2849728a24b498ad2117784b1f;p=xscreensaver diff --git a/hacks/xscreensaver-sgigl.c b/hacks/xscreensaver-sgigl.c index a4247784..8d25ad14 100644 --- a/hacks/xscreensaver-sgigl.c +++ b/hacks/xscreensaver-sgigl.c @@ -1,4 +1,4 @@ -/* xscreensaver, Copyright (c) 1997 Jamie Zawinski +/* xscreensaver, Copyright (c) 1997, 2005 Jamie Zawinski * * Permission to use, copy, modify, distribute, and sell this software and its * documentation for any purpose is hereby granted without fee, provided that @@ -64,6 +64,7 @@ static char *progname; #include #include #include +#include #include #include "vroot.h" @@ -103,6 +104,8 @@ main(int ac, char **av) char *n2 = 0; Bool verbose = False; Window root, vroot; + XSizeHints h; + long ls; progname = av[0]; @@ -205,6 +208,13 @@ main(int ac, char **av) if (verbose) fprintf(stderr, "%s: resizing 0x%x\n", progname, w); + /* Make sure the window allows itself to be resized. */ + XGetWMNormalHints (dpy, w, &h, &ls); + h.flags |= PMaxSize; + h.max_width = WidthOfScreen(screen)+128; + h.max_height = HeightOfScreen(screen)+128; + XSetWMNormalHints (dpy, w, &h); + XMoveResizeWindow(dpy, w, 0, 0, WidthOfScreen(screen), HeightOfScreen(screen));