look = RrAppearanceNew(inst, 0);
look->surface.grad = RR_SURFACE_MIRROR_HORIZONTAL;
- look->surface.secondary = RrColorParse(inst, "Yellow");
look->surface.split_secondary = RrColorParse(inst, "Red");
look->surface.split_primary = RrColorParse(inst, "Green");
- look->surface.primary = RrColorParse(inst, "Blue");
+ look->surface.secondary = RrColorParse(inst, "Dark Orange");
+ look->surface.primary = RrColorParse(inst, "Dark Blue");
look->surface.interlaced = FALSE;
if (ob_display == NULL) {
fprintf(stderr, "couldn't connect to X server :0\n");
case Expose:
break;
case ConfigureNotify:
+ look->surface.grad += 1;
+ if (look->surface.grad > RR_SURFACE_MIRROR_HORIZONTAL)
+ look->surface.grad = RR_SURFACE_SPLIT_VERTICAL;
RrPaint(look, win,
report.xconfigure.width,
report.xconfigure.height);
#include <stdio.h>
#include <assert.h>
#include <glib.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
Window findClient(Display *d, Window win)
{
XPutImage(d, p, DefaultGC(d, s), i[j], 0, 0, x, 0,
i[j]->width, i[j]->height);
x += i[j]->width;
+ char *filename;
+ asprintf(&filename, "icon%i.raw", j);
+ int fd = open(filename, O_CREAT | O_RDWR);
+ write(fd, i[j]->data, i[j]->width * i[j]->height * i[j]->depth);
XDestroyImage(i[j]);
}
XDestroyWindow(display, win);
XSync(display, False);
- break;
- sleep(2);
+ //break;
+ usleep(200000);
}
return 1;
Display *display;
Window win;
XEvent report;
- Atom _net_fs, _net_state;
XEvent msg;
int x=50,y=50,h=100,w=400;
XWMHints hint;
return 0;
}
- _net_state = XInternAtom(display, "_NET_WM_STATE", False);
- _net_fs = XInternAtom(display, "_NET_WM_STATE_FULLSCREEN", False);
-
win = XCreateWindow(display, RootWindow(display, 0),
x, y, w, h, 10, CopyFromParent, CopyFromParent,
CopyFromParent, 0, NULL);