5
6

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Readable Xmodmap

Posted at

Xmodmap の設定ファイルで keycodekeysym を併用すると混乱するのでどちらか片方だけを使うほうがよいと思う。
keycode は番号で書くため読みにくくなるが、事項順序依存は発生しないため、長い設定ファイルを書く場合は番号の方が良い。

また、モディファイヤーキーを変更する場合は、次の順番で行うと失敗しない。

  • 変更しようとする全ての keysym と MODIFIERNAME との結びつきを外す (clear か remove を使用)
  • 物理的なキーコードに keysym を割り当てる ( keycode を使用)
  • MODIFIERNAME に keysym を追加する ( add を使用 )

例:

clear lock
clear control
keycode 66 = Control_L
keycode 37 = Caps_Lock
add Control = Control_L
add Lock = Caps_Lock

次の例は失敗するので注意すること。

! キーコード
! CapsLock  66
! Control_L 37

clear lock
keycode 66 = Control_L
add Control = Control_L

clear control
keycode 37 = Caps_Lock
add Lock = Caps_Lock
5
6
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
6

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?