[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: xkb-data with support for Mac keyboards into unstable

Hi All

Please note: The attached patch is a suggestion of what might be nice
for qwertz (DE) macintosh laptops. It's meant as an idea for those who
like the pc105 mappings on macintosh laptops .. Please change the
patch to your likings, or have your say if you like the default
current unchanged official xkb-data 0.8-16 when running the
'setxkbmap' one liner below.

The patch should work on xkb-data 0.8-16.

On Fri, Sep 29 2006, at 16:54 +0200, Helge Kreutzmann wrote:
> Hello,
> On Thu, Sep 28, 2006 at 10:46:49PM +0200, Wolfgang Pfeiffer wrote:
> > > Which problems do you have, when you load the pc105 layout? Aren't it work?
> > 
> > Exactly. Currently I've loaded xkb-data 0.8-14, and with that version
> > as with the previous one I basically can use only 2 models:
> > "powerbook" or "pc105": pc105 seems broken. With 'powerbook' at least
> > I find the keys I need.
> I've tried it with -13 on my ibook G4 and it is broken as well. If
> that would help, I can provide a list of broken keycodes, but the
> entire third level seems goofed or gone.
> > So I'm editing symbols/macintosh_vndr/de currently ... I will surely
> > have what I want :) ..
> Could you post your final results and check with Denis if they can be
> included in the official deb?

I have a result that works, but I'd bet this little patch (attached to
this message), although it works perfectly here for a pc105 layout and
with the CLI one-liner below, can't get into some official
xkb-data. Simply because I believe it changes every pc105 layout on
every keyboard (macintosh, PC105, etc), just everywhere .... :)

So it's just an ugly hack, a suggestion rather to Denis and those who
prefer to have a pc105 layout on their Apple qwertz (DE) notebooks
than a patch to be included in xkb-data, and it's intended as a
practical way to show you what I'd prefer to have.

And if you like this diff: Great ... at least I do ... :)

The patch works for this PowerBook5,8 keyboard:

Note there might be changes I'd prefer much more than the ones
suggested here: Please let me know if you have better ideas than I do
... :)

setxkbmap -option -rules xorg -model pc105 -layout de  -option apple:badmap -option lv3:lwin_switch -print | xkbcomp - :0

The small changes this patch does:

*** 1:

        Alt_R instead of KP_Enter

With this last one-liner above with the regular xkb-data 0.8-16 I still
have a KP_Enter key left of the arrow <LEFT> key ... I played a bit
with that KP_Enter key, and all I found was that it's completely
useless. Please, anyone out there knowing more than I do: let me know.

So after applying the patch in this mail, on KP_Enter I will have an
Alt_R key. This is useful for me as I need some ALT key very often
with emacs.

It was difficult to map Alt_R to that key: The only way I found to do
that was to add also Meta_R ... Denis: What did I miss as to this last

*** 2:

        at on 'L'

I believe even on a PC105 layout it's nice to have what is engraved on
the keys. So I mapped the 'at' key to the 'L'. 

I have it twice now because it's already on 'Q', but I'm not anal
about this: I simply like it that way ... :)

*** 3:

       macron, exclamdown, questiondown 

The macron is on a higher level on the 'L' key now, some sort of
"upper_score", I think I've never seen it before, and it might be
useful sometimes. Looks like ¯¯¯this¯¯¯ ... :) ..

I also mapped exclamdown, questiondown to 'K' ... this last mapping
probably is not important, just nice to know I have it somewhere
... :) .... like so: ¡ ¿

Here's a way to apply the patch:

As root:
cd /usr/share/X11/xkb/symbols/

The backup:
cp de de.orig

The test:
patch -p2 --dry-run < /path/to/de-pc105.diff

Real change:
patch -p2 < /path/to/de-pc105.diff

As non-root:

 ... and then running the setxkbmap one-liner above ...

Enjoy ... :)

Best Regards

wolfgang pfeiffer: /ICQ: 286585973/ + + +  /AIM: crashinglinux/

Key ID: E3037113
--- xkb/symbols/de.orig	2006-09-29 22:21:32.000000000 +0200
+++ xkb/symbols/de	2006-09-29 23:47:40.000000000 +0200
@@ -28,7 +28,13 @@
     key <BKSL>	{ [numbersign, apostrophe,   dead_grave,   dead_breve ]	};
     key <AB01>	{ [         y,          Y, guillemotleft,        less ]	};
+    key <AC08>	{ [         k,          K, exclamdown, questiondown   ]	};
+    key <AC09>	{ [         l,          L, 	at,  	macron        ]	};
+    // remove the KP_ENTER key from macintosh keyboards .. and install 
+    // a key that might be useful otherwise ... :)
+    key <KPEN>  { [		Alt_R,      Meta_R          ] };
     include "keypad(comma)"
     include "level3(ralt_switch)"

Reply to: