]>
Dogcows Code - chaz/openbox/blob - tests/urgent.c
10 Atom _net_fs
, _net_state
;
12 int x
=50,y
=50,h
=100,w
=400;
15 display
= XOpenDisplay(NULL
);
17 if (display
== NULL
) {
18 fprintf(stderr
, "couldn't connect to X server :0\n");
22 _net_state
= XInternAtom(display
, "_NET_WM_STATE", False
);
23 _net_fs
= XInternAtom(display
, "_NET_WM_STATE_FULLSCREEN", False
);
25 win
= XCreateWindow(display
, RootWindow(display
, 0),
26 x
, y
, w
, h
, 10, CopyFromParent
, CopyFromParent
,
27 CopyFromParent
, 0, NULL
);
29 XSetWindowBackground(display
,win
,WhitePixel(display
,0));
31 XMapWindow(display
, win
);
35 hint
.flags
= XUrgencyHint
;
36 XSetWMHints(display
, win
, &hint
);
40 XNextEvent(display
, &report
);
42 switch (report
.type
) {
47 x
= report
.xconfigure
.x
;
48 y
= report
.xconfigure
.y
;
49 w
= report
.xconfigure
.width
;
50 h
= report
.xconfigure
.height
;
51 printf("confignotify %i,%i-%ix%i\n",x
,y
,w
,h
);
This page took 0.034036 seconds and 4 git commands to generate.