diff options
| author | Anselm R. Garbe <garbeam@gmail.com> | 2007-08-13 19:13:54 +0200 |
|---|---|---|
| committer | Anselm R. Garbe <garbeam@gmail.com> | 2007-08-13 19:13:54 +0200 |
| commit | 77044e876511f51c34bde379d89e2de754707ee6 (patch) | |
| tree | 6626665e0d57068c2d6ddbb3669534f2afb4e159 /dwm.h | |
| parent | made resize more precise (diff) | |
| download | dwm-77044e876511f51c34bde379d89e2de754707ee6.tar.gz dwm-77044e876511f51c34bde379d89e2de754707ee6.zip | |
made Layout a static struct in layout.c, added some convenience getters in layout.c, now lt->arrange accesses are not possible anymore, arrange() is the super-arrange function which sets up all layouts
Diffstat (limited to 'dwm.h')
| -rw-r--r-- | dwm.h | 11 |
1 files changed, 4 insertions, 7 deletions
| @@ -74,11 +74,6 @@ typedef struct { | |||
| 74 | } font; | 74 | } font; |
| 75 | } DC; /* draw context */ | 75 | } DC; /* draw context */ |
| 76 | 76 | ||
| 77 | typedef struct { | ||
| 78 | const char *symbol; | ||
| 79 | void (*arrange)(void); | ||
| 80 | } Layout; | ||
| 81 | |||
| 82 | extern const char *tags[]; /* all tags */ | 77 | extern const char *tags[]; /* all tags */ |
| 83 | extern char stext[256]; /* status text */ | 78 | extern char stext[256]; /* status text */ |
| 84 | extern int screen, sx, sy, sw, sh; /* screen geometry */ | 79 | extern int screen, sx, sy, sw, sh; /* screen geometry */ |
| @@ -92,7 +87,6 @@ extern Client *clients, *sel, *stack; /* global client list and stack */ | |||
| 92 | extern Cursor cursor[CurLast]; | 87 | extern Cursor cursor[CurLast]; |
| 93 | extern DC dc; /* global draw context */ | 88 | extern DC dc; /* global draw context */ |
| 94 | extern Display *dpy; | 89 | extern Display *dpy; |
| 95 | extern Layout *lt; | ||
| 96 | extern Window root, barwin; | 90 | extern Window root, barwin; |
| 97 | 91 | ||
| 98 | /* client.c */ | 92 | /* client.c */ |
| @@ -120,8 +114,11 @@ unsigned int textw(const char *text); /* return the width of text in px*/ | |||
| 120 | void grabkeys(void); /* grab all keys defined in config.h */ | 114 | void grabkeys(void); /* grab all keys defined in config.h */ |
| 121 | 115 | ||
| 122 | /* layout.c */ | 116 | /* layout.c */ |
| 123 | void floating(void); /* arranges all windows floating, fallback layout */ | 117 | void arrange(void); /* arranges all windows depending on the layout in use */ |
| 124 | void focusclient(const char *arg); /* focuses next(1)/previous(-1) visible client */ | 118 | void focusclient(const char *arg); /* focuses next(1)/previous(-1) visible client */ |
| 119 | const char *getsymbol(void); /* returns True symbol of enabled layout */ | ||
| 120 | Bool isfloating(void); /* returns True if floating layout is enabled */ | ||
| 121 | Bool isarrange(void (*func)()); /* returns True if func is the layout function in use */ | ||
| 125 | void initlayouts(void); /* initialize layout array */ | 122 | void initlayouts(void); /* initialize layout array */ |
| 126 | Client *nexttiled(Client *c); /* returns tiled successor of c */ | 123 | Client *nexttiled(Client *c); /* returns tiled successor of c */ |
| 127 | void restack(void); /* restores z layers of all clients */ | 124 | void restack(void); /* restores z layers of all clients */ |
