-/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997, 1998, 2006
- * Jamie Zawinski <jwz@jwz.org>
+/* xscreensaver, Copyright (c) 1992-2008 Jamie Zawinski <jwz@jwz.org>
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
qix->lines[i].p = (struct qpoint *)
calloc(qix->npoly, sizeof(struct qpoint));
-# ifndef HAVE_COCOA
+# ifndef HAVE_JWXYZ
if (!mono_p && !st->transparent_p)
# endif
{
qix->lines[i].color = qix->lines[0].color;
qix->lines[i].dead = qix->lines[0].dead;
-# ifndef HAVE_COCOA
+# ifndef HAVE_JWXYZ
if (!mono_p && !st->transparent_p)
# endif
if (!XAllocColor (st->dpy, st->cmap, &qix->lines[i].color))
st->additive_p = get_boolean_resource (st->dpy, "additive", "Boolean");
st->cmap_p = has_writable_cells (xgwa.screen, xgwa.visual);
-# ifndef HAVE_COCOA
+# ifndef HAVE_JWXYZ
if (st->transparent_p)
{
unsigned long *plane_masks = 0;
st->gcs [1][i] = XCreateGC (st->dpy, st->window,
GCForeground|GCPlaneMask,
&gcv);
-# ifdef HAVE_COCOA
+# ifdef HAVE_JWXYZ
/* jwxyz_XSetAntiAliasing (st->dpy, st->gcs [0][i], False);
jwxyz_XSetAntiAliasing (st->dpy, st->gcs [1][i], False); */
if (st->transparent_p)
jwxyz_XSetAlphaAllowed (dpy, st->gcs [0][i], True);
jwxyz_XSetAlphaAllowed (dpy, st->gcs [1][i], True);
}
-# endif /* HAVE_COCOA */
+# endif /* HAVE_JWXYZ */
}
}
XClearWindow (st->dpy, st->window);
}
else
-#endif /* !HAVE_COCOA */
+#endif /* !HAVE_JWXYZ */
if (st->xor_p)
{
-#ifndef HAVE_COCOA
+#ifndef HAVE_JWXYZ
NON_TRANSPARENT_XOR:
#endif
gcv.function = GXxor;
}
else
{
-#ifndef HAVE_COCOA
+#ifndef HAVE_JWXYZ
NON_TRANSPARENT:
#endif
st->draw_gc = XCreateGC (st->dpy, st->window, GCForeground, &gcv);
st->erase_gc = XCreateGC (st->dpy, st->window, GCForeground, &gcv);
}
-#ifdef HAVE_COCOA
+#ifdef HAVE_JWXYZ
if (st->transparent_p)
jwxyz_XSetAlphaAllowed (dpy, st->draw_gc, True);
#endif
st->qixes [st->count]->id = st->count;
}
-# ifdef HAVE_COCOA
+# ifdef HAVE_JWXYZ
/* line-mode leaves turds without this. */
jwxyz_XSetAntiAliasing (st->dpy, st->erase_gc, False);
jwxyz_XSetAntiAliasing (st->dpy, st->draw_gc, False);
- (st->random_p ? random() % st->max_spread : 0);
}
-#ifndef HAVE_COCOA
+#ifndef HAVE_JWXYZ
if (!mono_p && !st->transparent_p)
#endif
{
abort (); /* same color should work */
}
-# ifdef HAVE_COCOA
+# ifdef HAVE_JWXYZ
if (st->transparent_p)
{
/* give a non-opaque alpha to the color */
unsigned long pixel = qline->color.pixel;
- unsigned long amask = BlackPixelOfScreen (0);
+ unsigned long amask = BlackPixel (st->dpy, 0);
unsigned long a = (0xBBBBBBBB & amask);
pixel = (pixel & (~amask)) | a;
qline->color.pixel = pixel;
}
-# endif /* HAVE_COCOA */
+# endif /* HAVE_JWXYZ */
XSetForeground (st->dpy, st->draw_gc, qline->color.pixel);
}
static const char *qix_defaults [] = {
".background: black",
".foreground: white",
-#if 0
- "*count: 1",
-#else
- "*count: 5",
-#endif
- "*segments: 50",
+ "*fpsSolid: true",
+ "*count: 4",
+ "*segments: 250",
"*poly: 2",
"*spread: 8",
- "*size: 0",
+ "*size: 200",
"*colorShift: 3",
- "*solid: false",
+ "*solid: true",
"*delay: 10000",
- "*random: true",
+ "*random: false",
"*xor: false",
-#if 0
- "*transparent:false",
-#else
"*transparent:true",
-#endif
"*gravity: false",
"*additive: true",
+#ifdef HAVE_MOBILE
+ "*ignoreRotation: True",
+#endif
0
};