]> Dogcows Code - chaz/openbox/blobdiff - render/mask.c
make the segfault swearing more clear
[chaz/openbox] / render / mask.c
index 8b0f21c04eb83a02629358b77588262f437f99c3..d0f375bce43f063fa281db218de3976ce8cb016c 100644 (file)
@@ -25,7 +25,7 @@ void RrPixmapMaskFree(RrPixmapMask *m)
     }
 }
 
-void RrPixmapMaskDraw(Pixmap p, const RrTextureMask *m, const Rect *area)
+void RrPixmapMaskDraw(Pixmap p, const RrTextureMask *m, const RrRect *area)
 {
     int x, y;
     if (m->mask == None) return; /* no mask given */
@@ -37,16 +37,16 @@ void RrPixmapMaskDraw(Pixmap p, const RrTextureMask *m, const Rect *area)
     if (x < 0) x = 0;
     if (y < 0) y = 0;
 
-    XSetClipMask(RrDisplay(m->mask->inst), m->color->gc, m->mask->mask);
-    XSetClipOrigin(RrDisplay(m->mask->inst), m->color->gc, x, y);
+    XSetClipMask(RrDisplay(m->mask->inst), RrColorGC(m->color), m->mask->mask);
+    XSetClipOrigin(RrDisplay(m->mask->inst), RrColorGC(m->color), x, y);
 
     /* fill in the clipped region */
-    XFillRectangle(RrDisplay(m->mask->inst), p, m->color->gc, x, y,
+    XFillRectangle(RrDisplay(m->mask->inst), p, RrColorGC(m->color), x, y,
                    x + m->mask->width, y + m->mask->height);
 
     /* unset the clip region */
-    XSetClipMask(RrDisplay(m->mask->inst), m->color->gc, None);
-    XSetClipOrigin(RrDisplay(m->mask->inst), m->color->gc, 0, 0);
+    XSetClipMask(RrDisplay(m->mask->inst), RrColorGC(m->color), None);
+    XSetClipOrigin(RrDisplay(m->mask->inst), RrColorGC(m->color), 0, 0);
 }
 
 RrPixmapMask *RrPixmapMaskCopy(const RrPixmapMask *src)
This page took 0.02556 seconds and 4 git commands to generate.