st->twitch = get_boolean_resource(st->dpy, "twitch", "Boolean");
st->dbuf = get_boolean_resource(st->dpy, "doubleBuffer", "Boolean");
-# ifdef HAVE_COCOA /* Don't second-guess Quartz's double-buffering */
+# ifdef HAVE_JWXYZ /* Don't second-guess Quartz's double-buffering */
st->dbuf = False;
# endif
st->gw = st->sw ? st->xgwa.width / st->sw : 0;
st->gh = st->sh ? st->xgwa.height / st->sh : 0;
st->nsquares = st->gw * st->gh;
+ if (st->nsquares < 1) st->nsquares = 1;
+ if (st->ncolors < 1) st->ncolors = 1;
gcv.foreground = fg.pixel;
gcv.background = bg.pixel;
rgb_to_hsv (fg.red, fg.green, fg.blue, &h1, &s1, &v1);
rgb_to_hsv (bg.red, bg.green, bg.blue, &h2, &s2, &v2);
- make_color_ramp (st->dpy, st->xgwa.colormap,
+ make_color_ramp (st->xgwa.screen, st->xgwa.visual, st->xgwa.colormap,
h1, s1, v1,
h2, s2, v2,
st->colors, &st->ncolors, /* would this be considered a value-result argument? */
st->gh = st->sh ? st->xgwa.height / st->sh : 0;
st->nsquares = st->gw * st->gh;
free (st->squares);
+ if (st->nsquares < 1) st->nsquares = 1;
st->squares = (square *) calloc (st->nsquares, sizeof(square));
for (y = 0; y < st->gh; y++)
"*useDBE: True",
"*useDBEClear: True",
#endif /* HAVE_DOUBLE_BUFFER_EXTENSION */
+#ifdef HAVE_MOBILE
+ "*ignoreRotation: True",
+#endif
0
};