made barclick to select the specific tag

This commit is contained in:
Anselm R. Garbe committed 2006-07-14 10:34:07 +02:00
1 parent 9cd686c93a
commit 6458d72572
6 files changed
+36 -4

No files matched your search

+14
View File
@@ -5,6 +5,20 @@
#include "dwm.h"
void
barclick(XButtonPressedEvent *e)
{
int x = 0;
Arg a;
for(a.i = 0; a.i < TLast; a.i++) {
x += textw(tags[a.i]) + dc.font.height;
if(e->x < x) {
view(&a);
return;
}
}
}
void
draw_bar()
{