- self = XCreatePixmap (dpy, window, size, size, depth);
- temp = XCreatePixmap (dpy, window, size, size, depth);
- mask = XCreatePixmap (dpy, window, size, size, depth);
- gcv.foreground = (depth == 1 ? 1 : (~0));
- gcv.function=GXset; SET = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv);
- gcv.function=GXclear;CLR = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv);
- gcv.function=GXcopy; CPY = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv);
- gcv.function=GXor; IOR = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv);
- gcv.function=GXand; AND = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv);
- gcv.function=GXxor; XOR = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv);
-
- gcv.foreground = gcv.background = bg;
- gc = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv);
- /* Clear self to the background color (not to 0, which CLR does.) */
- XFillRectangle (dpy, self, gc, 0, 0, size, size);
- XSetForeground (dpy, gc, fg);
-
- XCopyArea (dpy, bitmap, self, CPY, 0, 0, width, height,
- (size - width)>>1, (size - height)>>1);
- XFreePixmap(dpy, bitmap);
-
- display (self);
- XSync(dpy, False);
+ st->self = XCreatePixmap (st->dpy, st->window, st->size, st->size, st->xgwa.depth);
+ st->temp = XCreatePixmap (st->dpy, st->window, st->size, st->size, st->xgwa.depth);
+ st->mask = XCreatePixmap (st->dpy, st->window, st->size, st->size, st->xgwa.depth);
+ gcv.foreground = (st->xgwa.depth == 1 ? 1 : (~0));
+ gcv.function=GXset; st->SET = XCreateGC(st->dpy,st->self,GCFunction|GCForeground,&gcv);
+ gcv.function=GXclear;st->CLR = XCreateGC(st->dpy,st->self,GCFunction|GCForeground,&gcv);
+ gcv.function=GXcopy; st->CPY = XCreateGC(st->dpy,st->self,GCFunction|GCForeground,&gcv);
+ gcv.function=GXor; st->IOR = XCreateGC(st->dpy,st->self,GCFunction|GCForeground,&gcv);
+ gcv.function=GXand; st->AND = XCreateGC(st->dpy,st->self,GCFunction|GCForeground,&gcv);
+ gcv.function=GXxor; st->XOR = XCreateGC(st->dpy,st->self,GCFunction|GCForeground,&gcv);
+
+ gcv.foreground = gcv.background = st->bg;
+ st->gc = XCreateGC (st->dpy, st->window, GCForeground|GCBackground, &gcv);
+ /* Clear st->self to the background color (not to 0, which st->CLR does.) */
+ XFillRectangle (st->dpy, st->self, st->gc, 0, 0, st->size, st->size);
+ XSetForeground (st->dpy, st->gc, st->fg);
+
+#if 0
+#ifdef HAVE_COCOA
+ jwxyz_XSetAntiAliasing (st->dpy, st->gc, False);
+ jwxyz_XSetAntiAliasing (st->dpy, st->SET, False);
+ jwxyz_XSetAntiAliasing (st->dpy, st->CLR, False);
+ jwxyz_XSetAntiAliasing (st->dpy, st->CPY, False);
+ jwxyz_XSetAntiAliasing (st->dpy, st->IOR, False);
+ jwxyz_XSetAntiAliasing (st->dpy, st->AND, False);
+ jwxyz_XSetAntiAliasing (st->dpy, st->XOR, False);
+#endif /* HAVE_COCOA */
+#endif
+
+ XCopyArea (st->dpy, st->bitmap, st->self, st->CPY, 0, 0,
+ st->width, st->height,
+ (st->size - st->width) >> 1,
+ (st->size - st->height) >> 1);
+/* XFreePixmap(st->dpy, st->bitmap);*/
+
+ st->qwad = -1;
+ st->first_time = 1;