help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Dvorak layout except when modifier key is pressed


From: Peter Dyballa
Subject: Re: Dvorak layout except when modifier key is pressed
Date: Fri, 28 Dec 2007 11:54:07 +0100


Am 28.12.2007 um 04:05 schrieb B. T. Raven:

then ad(d)just:
    add    Shift   = Shift_L    Shift_R

! add Lock = Caps_Lock !! I want this to be Hyper_L . Will this conflict with your Mod4 assignment below?

You don't need to follow my examples. I was not trying to solve your keyboard layout problem, just giving hints. The Lock "function" can of course be performed by a key that also supplies the Hyper_L modifier. With funny results.


    add    Control = Control_L    Control_R

! add Mod1 = Mode_switch Mode_switch !! This I don't understand at all. Is it the M$ Menu key?

If no keycode is mapped to produce the Mode_switch keysymbol, you can't assign Mode_switch to Mod1 modifier. If you don't want to have a Mod1 modifier, you don't need to assign it. You can choose any defined key(symbol) to perform a modifier function.


! add Mod2 = Meta_L Meta_R !! I don't need this since I don't have a Meta key, right?

So leave it cleared! All modifier and control and shift and lock keys are optional.


    add    Mod3    = Alt_L        Alt_R
    add    Mod4    = Hyper_L    Hyper_R
    add    Mod5    = Super_L    Super_R
Generally you can set the "key bindings" like:
keycode 0x35 = n N dead_tilde U203A
    keycode 66 = Meta_L

This keycode method seems like the easiest way to swap keys since I can get the keycodes from xev.

Or 'xmodmap -pke'?

Are the above "clear" and "add" lines still needed?

Not all. They were meant as a complete example.

In my /etc/X11/Xmodmap file (all commented out) I read:


! keycode and keysym remapping should generally be used only if the X
! server config file has been configured to disable the XKEYBOARD
! extension

Where is the server config file? Is this something I have to worry about or can I just add these lines to that file? :

/etc or /etc/X11. The file names will probably contain the extension .conf. Man <the X server used> will reveal more details. There are configuration programmes for these files. 'apropos configure' might reveal the programmes and the files. Mistakes can prevent X11 to launch, so better make a backup of the file you want to change!

If you have a package with XKeyCaps in it, install it. XKeyCaps can be quite helpful in many ways.


clear Lock
!.
!. maybe other expressions
!.
add Lock = Hyper_L !! Is that meaningful?

No. The Lock key can't be a modifier key, your car not a bike. (But the key that emits the Lock symbol can be changed to emit Hyper_L symbol.)


keycode 66 = Hyper_L !! is this needed even with the above add Lock expression?

You can set:

        my modifier Nº 1 is my right pinky.

As long as there is no keysymbol "right pinky" defined as being emitted by some key, you can't assign that symbol to a "function" like Mod<whatsoever>.


keycode 37 = Super_L
keycode 115 = Alt_L  !! It says Alt on the keycap.

So what? Aren't you going to tell your Linux PC that X is U?

keycode 64 = Control_L
keycode 113 = Control_R
keycode 116 = Alt_R !! Again that's on keycap. Can't I just say alt- is-meta or something somewhere?

Of course you can set it to Meta, either right side or left side. You're free to do what you want, since your computer can't read what its keys are imprinted with. The keycode is something like a "scan code" that a controller IC sends to the CPU. This same "scan code" can have in different environments different meanings ("switching keyboards [encodings/layouts]"). With 'keycode equals keysymbol' you assign the dumb "scan code" to something meaningful an user (high level) programme can work with.


I read that there can be eight columns but that most apps don't support beyond four. Does Emacs?

I don't know. Make a try: assign on the fly some key some more keysymbols. For example a, emitting the usual "a symbols," then b and B, and finally c and C. So you'll easily see what Modx-a or Modx-A deliver. And it's easy to restore: M-p, some delete, RET.

Could I globalsetkey something to [(shift control alt super hyper h)] ?

Emacs key-bindings are independent of those in X11 or any other windowing system. GNU Emacs receives the keysymbols, not the keycodes. It can handle only those keysymbols it receives. What you tell it to do with the received keysymbols is up to you. So it's surely possible to leave the keyboard's layout in X as is and change it to Dvořak only in GNU Emacs.


Multi_key is a nice thing: pressing Multi_key o / could produce ø. Not sure whether it's still supported ...

I want to do all this sort of thing with Emacs (leim) input methods.

Fedora 8 should be capable to substitute leim. Doing so will enable you to have the same wealth in all applications. At least with Unicode Emacs 23.0.60 you don't leim at all.

--
Greetings

  Pete

What is this talk of 'release?' Klingons do not make software 'releases.' Our software 'escapes,' leaving a bloody trail of designers and quality assurance people in its wake.







reply via email to

[Prev in Thread] Current Thread [Next in Thread]