fvwm学习笔记之 Key Bind 說明 zz

zz form 大步向前走

我先假設這篇文章是寫給像我一樣笨看不懂 fvwmrc 官方說明文件 的人。

因為如果你要看得懂上面的文件,你需要了解幾樣東西:


  1. xmodmap
  2. Xorg.conf
  3. /usr/include/X11/keysymdef.h
  4. fvwmrc key binding section


官方的說明在 key bind 的部份是這麼寫的:

BUILT-IN KEY AND MOUSE BINDINGS

The following commands are built-in to fvwm:

Key Help R A Popup MenuFvwmRoot
Key F1 R A Popup MenuFvwmRoot
Key Tab A M WindowList Root c c NoDeskSort
Key Escape A MC EscapeFunc
Mouse 1 R A Menu MenuFvwmRoot
Mouse 1 T A FuncFvwmRaiseLowerX Move
Mouse 1 FS A FuncFvwmRaiseLowerX Resize
Mouse 2 FST A FuncFvwmRaiseLowerX Move
AddToFunc FuncFvwmRaiseLowerX
+ I Raise
+ M $0
+ D Lower

The Help and F1 keys invoke a built-in menu that fvwm creates. This is primarily for new users that have not created their own configuration file. Either key on the root (background) window pops up an menu to help you get started.

The Tab key pressed anywhere with the Meta key (same as the Alt key on PC keyboards) held down pop-ups a window list.

Mouse button 1 on the title-bar or side frame can move, raise or lower a window.

Mouse button 1 on the window corners can resize, raise or lower a window.

You can override or remove these bindings. To remove the window list binding, use this:

Key Tab A M -


很簡單的給你例子:
Key KeyName A M FunctionName
如果你要做一堆東西,就用 Function 串這些動作。
如果你要移除這個 Key Bind ,請用 Key KeyName A M - 就可以。

嗯,問題來了:

Q: KeyName List 在哪裡?
Q: A M 是什麼東西?

第一個答案,在 comment 裡面有寫到:

SelectOnRelease takes an optional key name as an argument. If the given key is released in a menu using this style, the current menu item is selected. This is intended for Alt-Tab WindowList navigation. The key name is a standard X11 key name as defined in /usr/include/X11/keysymdef.h, (without the XK_ prefix), or the keysym database /usr/X11R6/lib/X11/XKeysymDB. To disable this behavior, omit the key name.


簡單的說,"請參考 /usr/include/X11/keysymdef.h" ,但是相信我,如果你去那裡看就能看得懂,那你真是個天才!!!

正解(?)應該是請參考 xmodmap ,用 xmodmap -pk 顯示目前 X 使用的 xmodmap list 來加入 keyname ,並且這個 keyname 應該符合 /usr/include/X11/keysymdef.h 的定義。

另外在 A M 的定義上面:

A 且當它是 And 的意思。(心虛)
M 是 Modifiers 的意思:

# Here you can easily change modifier keys:
# N - no modifier (none pressed)
# A - any modifier (0 or more)
# S - Shift key (Shift_L)
# M - Meta or Alt key (Alt_L)
# C - Control key (Control_L)
# 4 - Windows left key (Super_L)
  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值