diff options
Diffstat (limited to '')
| -rw-r--r-- | tile.c | 32 |
1 files changed, 16 insertions, 16 deletions
| @@ -4,8 +4,8 @@ int bx, by, bw, bh, blw, mx, my, mw, mh, tx, ty, tw, th, wx, wy, ww, wh; | |||
| 4 | 4 | ||
| 5 | void setmfact(const char *arg); | 5 | void setmfact(const char *arg); |
| 6 | void tile(void); | 6 | void tile(void); |
| 7 | void tilegeom(void); | ||
| 8 | void tileresize(Client *c, int x, int y, int w, int h); | 7 | void tileresize(Client *c, int x, int y, int w, int h); |
| 8 | void updatetilegeom(void); | ||
| 9 | 9 | ||
| 10 | void | 10 | void |
| 11 | setmfact(const char *arg) { | 11 | setmfact(const char *arg) { |
| @@ -65,21 +65,6 @@ tile(void) { | |||
| 65 | } | 65 | } |
| 66 | 66 | ||
| 67 | void | 67 | void |
| 68 | tilegeom(void) { | ||
| 69 | /* master area geometry */ | ||
| 70 | mx = wx; | ||
| 71 | my = wy; | ||
| 72 | mw = mfact * ww; | ||
| 73 | mh = wh; | ||
| 74 | |||
| 75 | /* tile area geometry */ | ||
| 76 | tx = mx + mw; | ||
| 77 | ty = wy; | ||
| 78 | tw = ww - mw; | ||
| 79 | th = wh; | ||
| 80 | } | ||
| 81 | |||
| 82 | void | ||
| 83 | tileresize(Client *c, int x, int y, int w, int h) { | 68 | tileresize(Client *c, int x, int y, int w, int h) { |
| 84 | resize(c, x, y, w, h, RESIZEHINTS); | 69 | resize(c, x, y, w, h, RESIZEHINTS); |
| 85 | if((RESIZEHINTS) && ((c->h < bh) || (c->h > h) || (c->w < bh) || (c->w > w))) | 70 | if((RESIZEHINTS) && ((c->h < bh) || (c->h > h) || (c->w < bh) || (c->w > w))) |
| @@ -101,3 +86,18 @@ zoom(const char *arg) { | |||
| 101 | } | 86 | } |
| 102 | arrange(); | 87 | arrange(); |
| 103 | } | 88 | } |
| 89 | |||
| 90 | void | ||
| 91 | updatetilegeom(void) { | ||
| 92 | /* master area geometry */ | ||
| 93 | mx = wx; | ||
| 94 | my = wy; | ||
| 95 | mw = mfact * ww; | ||
| 96 | mh = wh; | ||
| 97 | |||
| 98 | /* tile area geometry */ | ||
| 99 | tx = mx + mw; | ||
| 100 | ty = wy; | ||
| 101 | tw = ww - mw; | ||
| 102 | th = wh; | ||
| 103 | } | ||
