+#ifdef DO_STIPPLE
+#define stipple_width 16
+#define stipple_height 4
+static unsigned char stipple_bits[] = {
+ 0x55, 0x55, 0xee, 0xee, 0x55, 0x55, 0xba, 0xbb};
+
+#define cross_weave_width 16
+#define cross_weave_height 16
+static unsigned char cross_weave_bits[] = {
+ 0x55, 0x55, 0x88, 0x88, 0x55, 0x55, 0x22, 0x22, 0x55, 0x55, 0x88, 0x88,
+ 0x55, 0x55, 0x22, 0x22, 0x55, 0x55, 0x88, 0x88, 0x55, 0x55, 0x22, 0x22,
+ 0x55, 0x55, 0x88, 0x88, 0x55, 0x55, 0x22, 0x22};
+
+#define dimple1_width 16
+#define dimple1_height 16
+static unsigned char dimple1_bits[] = {
+ 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00,
+ 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00,
+ 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00};
+
+#define dimple3_width 16
+#define dimple3_height 16
+static unsigned char dimple3_bits[] = {
+ 0x11, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x11, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x11, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x11, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
+
+#define flipped_gray_width 4
+#define flipped_gray_height 2
+static char flipped_gray_bits[] = { 0x07, 0x0d};
+#define gray1_width 2
+#define gray1_height 2
+static char gray1_bits[] = { 0x01, 0x02};
+#define gray3_width 4
+#define gray3_height 4
+static char gray3_bits[] = { 0x01, 0x00, 0x04, 0x00};
+#define hlines2_width 1
+#define hlines2_height 2
+static char hlines2_bits[] = { 0x01, 0x00};
+#define light_gray_width 4
+#define light_gray_height 2
+static char light_gray_bits[] = { 0x08, 0x02};
+#define root_weave_width 4
+#define root_weave_height 4
+static char root_weave_bits[] = { 0x07, 0x0d, 0x0b, 0x0e};
+#define vlines2_width 2
+#define vlines2_height 1
+static char vlines2_bits[] = { 0x01};
+#define vlines3_width 3
+#define vlines3_height 1
+static char vlines3_bits[] = { 0x02};
+
+#endif /* DO_STIPPLE */
+
+struct state {
+ Display *dpy;
+ Window window;
+
+ Pixmap pixmaps [NBITS];
+
+ GC gc;
+ int delay;
+ unsigned long fg, bg, pixels [512];
+ int npixels;
+ int xlim, ylim;
+ Bool grey_p;
+ Colormap cmap;
+};
+
+
+static void *
+greynetic_init (Display *dpy, Window window)