mirror of
https://github.com/dylanaraps/sowm.git
synced 2026-11-06 15:50:51 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f4cb48d7af | ||
|
|
ccb96521c1 | ||
|
|
5663175d57 | ||
|
|
95596f43aa | ||
|
|
e595bfb365 |
No files matched your search
@@ -38,8 +38,8 @@ Patches available here: https://github.com/dylanaraps/sowm/pulls
|
||||
| `MOD4` + `f` | maximize toggle |
|
||||
| `MOD4` + `c` | center window |
|
||||
| `MOD4` + `q` | kill window |
|
||||
| `MOD4` + `1-9` | desktop swap |
|
||||
| `MOD4` + `Shift` +`1-9` | send window to desktop |
|
||||
| `MOD4` + `1-6` | desktop swap |
|
||||
| `MOD4` + `Shift` +`1-6` | send window to desktop |
|
||||
| `MOD1` + `TAB` (*alt-tab*) | focus cycle |
|
||||
|
||||
**Programs**
|
||||
@@ -85,14 +85,14 @@ Type=Application
|
||||
|
||||
## Thanks
|
||||
|
||||
- 2bwm
|
||||
- SmallWM
|
||||
- berry
|
||||
- catwm
|
||||
- dminiwm
|
||||
- dwm
|
||||
- monsterwm
|
||||
- openbox
|
||||
- possumwm
|
||||
- swm
|
||||
- tinywm
|
||||
- [2bwm](https://github.com/venam/2bwm)
|
||||
- [SmallWM](https://github.com/adamnew123456/SmallWM)
|
||||
- [berry](https://github.com/JLErvin/berry)
|
||||
- [catwm](https://github.com/pyknite/catwm)
|
||||
- [dminiwm](https://github.com/moetunes/dminiwm)
|
||||
- [dwm](https://dwm.suckless.org)
|
||||
- [monsterwm](https://github.com/c00kiemon5ter/monsterwm)
|
||||
- [openbox](https://github.com/danakj/openbox)
|
||||
- [possum-wm](https://github.com/duckinator/possum-wm)
|
||||
- [swm](https://github.com/dcat/swm)
|
||||
- [tinywm](http://incise.org/tinywm.html)
|
||||
@@ -24,6 +24,7 @@ static void (*events[LASTEvent])(XEvent *e) = {
|
||||
[ConfigureRequest] = configure_request,
|
||||
[KeyPress] = key_press,
|
||||
[MapRequest] = map_request,
|
||||
[MappingNotify] = mapping_notify,
|
||||
[DestroyNotify] = notify_destroy,
|
||||
[EnterNotify] = notify_enter,
|
||||
[MotionNotify] = notify_motion
|
||||
@@ -221,6 +222,15 @@ void map_request(XEvent *e) {
|
||||
win_focus(list->prev);
|
||||
}
|
||||
|
||||
void mapping_notify(XEvent *e) {
|
||||
XMappingEvent *ev = &e->xmapping;
|
||||
|
||||
if (ev->request == MappingKeyboard || ev->request == MappingModifier) {
|
||||
XRefreshKeyboardMapping(ev);
|
||||
input_grab(root);
|
||||
}
|
||||
}
|
||||
|
||||
void run(const Arg arg) {
|
||||
if (fork()) return;
|
||||
if (d) close(ConnectionNumber(d));
|
||||
@@ -240,6 +250,8 @@ void input_grab(Window root) {
|
||||
== XKeysymToKeycode(d, 0xff7f))
|
||||
numlock = (1 << i);
|
||||
|
||||
XUngrabKey(d, AnyKey, AnyModifier, root);
|
||||
|
||||
for (i = 0; i < sizeof(keys)/sizeof(*keys); i++)
|
||||
if ((code = XKeysymToKeycode(d, keys[i].keysym)))
|
||||
for (j = 0; j < sizeof(modifiers)/sizeof(*modifiers); j++)
|
||||
|
||||
Reference in new issue
Block a user