X-Git-Url: https://jasonwoof.com/gitweb/?p=dwm.git;a=blobdiff_plain;f=wm.h;h=9ea74fedde76916f647a5cd17b0afdbcbe9add91;hp=70f7ec77731555a0a54c109e2302c69b37a2ff5b;hb=16c67f32d62849792c8e6d4fdec22a1896f9c279;hpb=8a34fa50f75f4d6d8af234ac0c4f6d40b988d700 diff --git a/wm.h b/wm.h index 70f7ec7..9ea74fe 100644 --- a/wm.h +++ b/wm.h @@ -3,56 +3,74 @@ * See LICENSE file for license details. */ +#include "config.h" #include "draw.h" #include "util.h" #include -/* WM atoms */ -enum { WMState, WMProtocols, WMDelete, WMLast }; - -/* NET atoms */ +/* atoms */ enum { NetSupported, NetWMName, NetLast }; -/* Cursor */ +/* cursor */ enum { CurNormal, CurResize, CurMove, CurInput, CurLast }; -/* Rects */ +/* rects */ enum { RFloat, RGrid, RLast }; typedef struct Client Client; -typedef struct Tag Tag; +typedef struct Key Key; struct Client { - Tag *tag; char name[256]; - int proto; + char tag[256]; + unsigned int border; + Bool fixedsize; Window win; Window trans; Window title; - GC gc; XSizeHints size; XRectangle r[RLast]; Client *next; - Client *tnext; - Client *tprev; + Client *snext; }; -struct Tag { - char name[256]; - Client *clients; - Client *sel; - XRectangle r; +struct Key { + unsigned long mod; + KeySym keysym; + void (*func)(char *arg); + char *arg; }; extern Display *dpy; -extern Window root; -extern XRectangle rect; -extern int screen, sel_screen; -extern unsigned int kmask, numlock_mask; -extern Atom wm_atom[WMLast]; +extern Window root, barwin; extern Atom net_atom[NetLast]; extern Cursor cursor[CurLast]; -extern Pixmap pmap; +extern XRectangle rect, barrect; +extern Bool running; +extern Bool grid; +extern void (*handler[LASTEvent]) (XEvent *); + +extern int screen, sel_screen; +extern char *bartext, tag[256]; + +extern Brush brush; +extern Client *clients; + +/* bar.c */ +extern void draw_bar(); + +/* cmd.c */ +extern void run(char *arg); +extern void quit(char *arg); + +/* client.c */ +extern Client *create_client(Window w, XWindowAttributes *wa); +extern void manage(Client *c); +extern Client * getclient(Window w); + +/* key.c */ +extern void update_keys(); +extern void keypress(XEvent *e); /* wm.c */