We use some essential cookies to make our website work.

We use optional cookies, as detailed in our cookie policy, to remember your settings and understand how you use our website.

1 post • Page 1 of 1
wata
Posts: 17
Joined: Sun Oct 03, 2021 2:55 pm

mac から VNC で接続した時のキーコンフィグ

Sun Oct 03, 2021 3:23 pm

mac の画面共有(macOS 標準の VNC クライアント)を使用して Raspberry Pi に接続しています。この時、mac のキーボードの割り当てを変更するにはどうしたら良いでしょうか?

下記のように変更したいです。
Command_L -> Control_L
Command_R -> Shift_R

何もしていない状態では下記のような挙動になっていました。
Command_L 単押し: Romaji
Command_L+その他のキー(または長押し): Alt_L
Command_R 単押し: Hiragana
Command_R+その他のキー(または長押し): Alt_L

Raspberry Pi に Bluetooth 接続している Apple Wireless Keyboard は /usr/share/X11/xkb/symbols/pc 内の下記3行を編集することで目的を達成できました。

Code: Select all

# 変更前:
key <LWIN> { [ Super_L ] }
# 変更後:
key <LWIN> { [ Control_L ] }
# 変更前:
key <RWIN> { [ Super_R ] }
# 変更後:
key <RWIN> { [ Shift_R ] }
# 変更前:
modifier_map_Control{ Control_L, Control_R };
# 変更後:
modifier_map_Control{ Control_L, Control_R, <LWIN> };
同じことを VNC クライアントのキーボードでも実現したいです。

RealVNC Viewer を試したところ、Command キーに Control を割り当てることはできませんでした。

構成:
Raspberry Pi 4 Model B Raspbian GNU/Linux 10 (buster)
Macbook Pro Late 2013 US Keyboard macOS Catalina


よろしくお願いします。

1 post • Page 1 of 1

Return to "日本語"

AltStyle によって変換されたページ (->オリジナル) /