summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorscuri <scuri>2009-11-30 19:26:36 +0000
committerscuri <scuri>2009-11-30 19:26:36 +0000
commit4c4866d151bbf664273b74e1cee817633881d38f (patch)
treeedc5234e98d4320973b7c5ae45d64fdcda37110f
parent801a4237dc9847ff2356e1ec9460c31e977a2105 (diff)
Fixed: Clear method was affected by WriteMode in the X11 base driver.
-rw-r--r--src/x11/cdx11.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/x11/cdx11.c b/src/x11/cdx11.c
index 4f427e3..bbc9420 100644
--- a/src/x11/cdx11.c
+++ b/src/x11/cdx11.c
@@ -1107,13 +1107,17 @@ static void cdxCheckSolidStyle(cdCtxCanvas *ctxcanvas, int set)
cdinteriorstyle(ctxcanvas, ctxcanvas->canvas->interior_style);
}
+static int cdwritemode(cdCtxCanvas *ctxcanvas, int write_mode);
+
static void cdclear(cdCtxCanvas* ctxcanvas)
{
+ if (ctxcanvas->canvas->write_mode!= CD_REPLACE) cdwritemode(ctxcanvas, CD_REPLACE);
cdxCheckSolidStyle(ctxcanvas, 1);
XSetForeground(ctxcanvas->dpy, ctxcanvas->gc, cdxGetPixel(ctxcanvas, ctxcanvas->canvas->background));
XFillRectangle(ctxcanvas->dpy, ctxcanvas->wnd, ctxcanvas->gc, 0, 0, ctxcanvas->canvas->w, ctxcanvas->canvas->h);
XSetForeground(ctxcanvas->dpy, ctxcanvas->gc, cdxGetPixel(ctxcanvas, ctxcanvas->canvas->foreground));
cdxCheckSolidStyle(ctxcanvas, 0);
+ if (ctxcanvas->canvas->write_mode!= CD_REPLACE) cdwritemode(ctxcanvas, ctxcanvas->canvas->write_mode);
}
static void cdline(cdCtxCanvas *ctxcanvas, int x1, int y1, int x2, int y2)