[wiki] [sites] wiki updated

From: <hg_AT_suckless.org>
Date: Wed, 13 Oct 2010 18:45:35 +0000 (UTC)

changeset: 632:2da20b0917b6
tag: tip
user: Evgeny Grablyk <evgeny.grablyk_AT_gmail.com>
date: Wed Oct 13 21:45:10 2010 +0300
files: dwm.suckless.org/patches/dwm-5.9-pwkl.diff dwm.suckless.org/patches/pwkl.md
description:
Added a page for pwkl patch.


diff -r eea55a0b9caa -r 2da20b0917b6 dwm.suckless.org/patches/dwm-5.9-pwkl.diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/dwm.suckless.org/patches/dwm-5.9-pwkl.diff Wed Oct 13 21:45:10 2010 +0300
_AT_@ -0,0 +1,61 @@
+diff -r 406003e3a01f dwm.c
+--- a/dwm.c Mon Sep 27 07:53:44 2010 +0000
++++ b/dwm.c Wed Oct 13 21:16:04 2010 +0300
+_AT_@ -36,6 +36,7 @@
+ #include <X11/Xlib.h>
+ #include <X11/Xproto.h>
+ #include <X11/Xutil.h>
++#include <X11/XKBlib.h>
+ #ifdef XINERAMA
+ #include <X11/extensions/Xinerama.h>
+ #endif /* XINERAMA */
+_AT_@ -93,6 +94,7 @@
+ Client *snext;
+ Monitor *mon;
+ Window win;
++ unsigned char kbdgrp;
+ };
+
+ typedef struct {
+_AT_@ -821,6 +823,7 @@
+ selmon = c->mon;
+ if(c->isurgent)
+ clearurgent(c);
++ XkbLockGroup (dpy, XkbUseCoreKbd, c->kbdgrp);
+ detachstack(c);
+ attachstack(c);
+ grabbuttons(c, True);
+_AT_@ -1092,6 +1095,7 @@
+ Client *c, *t = NULL;
+ Window trans = None;
+ XWindowChanges wc;
++ XkbStateRec kbd_state;
+
+ if(!(c = malloc(sizeof(Client))))
+ die("fatal: could not malloc() %u bytes\n", sizeof(Client));
+_AT_@ -1146,6 +1150,8 @@
+ XMapWindow(dpy, c->win);
+ setclientstate(c, NormalState);
+ arrange(c->mon);
++ XkbGetState (dpy, XkbUseCoreKbd, &kbd_state);
++ c->kbdgrp = kbd_state.group;
+ }
+
+ void
+_AT_@ -1700,12 +1706,16 @@
+
+ void
+ unfocus(Client *c, Bool setfocus) {
++ XkbStateRec kbd_state;
++
+ if(!c)
+ return;
+ grabbuttons(c, False);
+ XSetWindowBorder(dpy, c->win, dc.norm[ColBorder]);
+ if(setfocus)
+ XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime);
++ XkbGetState (dpy, XkbUseCoreKbd, &kbd_state);
++ c->kbdgrp = kbd_state.group;
+ }
+
+ void
diff -r eea55a0b9caa -r 2da20b0917b6 dwm.suckless.org/patches/pwkl.md
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/dwm.suckless.org/patches/pwkl.md Wed Oct 13 21:45:10 2010 +0300
_AT_@ -0,0 +1,22 @@
+PER-WINDOW KEYBOARD LAYOUT
+===========
+
+Description
+-----------
+Basically, this patch implements per-window keyboard layout support in dwm.
+It makes dwm remember current keyboard layout when a window is unfocued,
+and restore it back when that window is focused again.
+
+Notes
+-----------
+Andreas Amann pointed out that "you cannot switch between tags per mouse
+if an alternate layout is activated". He kindly created a patch that fixes
+this: [see ml](http://lists.suckless.org/dev/1010/6195.html).
+
+Download
+--------
+* [dwm-5.9-pwkl.diff](dwm-5.9-pwkl.diff) (1.4K) (20101013)
+
+Author
+------
+* Evgeny Grablyk - <evgeny.grablyk_AT_gmail.com>
Received on Wed Oct 13 2010 - 20:45:35 CEST

This archive was generated by hypermail 2.3.0 : Thu Sep 13 2012 - 19:31:29 CEST