+
+ geom.x = 0;
+ geom.y = 0;
+ geom.width = xgwa.width;
+ geom.height = xgwa.height;
+
+ data = jwxyz_load_random_image (dpy, &width, &height, &name);
+ if (! data)
+ draw_colorbars (screen, xgwa.visual, drawable, xgwa.colormap,
+ 0, 0, xgwa.width, xgwa.height);
+ else
+ {
+ XImage *img = XCreateImage (dpy, xgwa.visual, 32,
+ ZPixmap, 0, data, width, height, 0, 0);
+ XGCValues gcv;
+ GC gc;
+ gcv.foreground = BlackPixelOfScreen (screen);
+ gc = XCreateGC (dpy, drawable, GCForeground, &gcv);
+ XFillRectangle (dpy, drawable, gc, 0, 0, xgwa.width, xgwa.height);
+ XPutImage (dpy, drawable, gc, img, 0, 0,
+ (xgwa.width - width) / 2,
+ (xgwa.height - height) / 2,
+ width, height);
+ XDestroyImage (img);
+ XFreeGC (dpy, gc);
+ }
+
+ callback (screen, window, drawable, name, &geom, closure);
+ if (name) free (name);