summaryrefslogtreecommitdiffstats
path: root/xlib
diff options
context:
space:
mode:
authordas <das>2007-07-02 13:04:07 (GMT)
committerdas <das>2007-07-02 13:04:07 (GMT)
commit62be4daee8881fef41d16c205afb1a81cca2f34e (patch)
treed418ceca00cfbc5a6769edf77e5747224ab5a22b /xlib
parentfd6f23be1500b5efefed38ae033804ef95f66f1b (diff)
downloadtk-62be4daee8881fef41d16c205afb1a81cca2f34e.zip
tk-62be4daee8881fef41d16c205afb1a81cca2f34e.tar.gz
tk-62be4daee8881fef41d16c205afb1a81cca2f34e.tar.bz2
* xlib/xgc.c (XCreateGC): correct black and white pixel values used to
initialize GC foregrund and background fields.
Diffstat (limited to 'xlib')
-rw-r--r--xlib/xgc.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/xlib/xgc.c b/xlib/xgc.c
index 6f96df8..b2e8446 100644
--- a/xlib/xgc.c
+++ b/xlib/xgc.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: xgc.c,v 1.12 2007/05/30 06:35:55 das Exp $
+ * RCS: @(#) $Id: xgc.c,v 1.13 2007/07/02 13:04:07 das Exp $
*/
#include <tkInt.h>
@@ -68,8 +68,10 @@ XCreateGC(
InitField(function, GCFunction, GXcopy);
InitField(plane_mask, GCPlaneMask, (unsigned long)(~0));
- InitField(foreground, GCForeground, 0);
- InitField(background, GCBackground, 0xffffff);
+ InitField(foreground, GCForeground,
+ BlackPixelOfScreen(DefaultScreenOfDisplay(display)));
+ InitField(background, GCBackground,
+ WhitePixelOfScreen(DefaultScreenOfDisplay(display)));
InitField(line_width, GCLineWidth, 1);
InitField(line_style, GCLineStyle, LineSolid);
InitField(cap_style, GCCapStyle, 0);