Voglio imparare le combinazioni di tasti emac, ma ho l'abitudine di usare i tasti freccia. C'è un modo per disattivare temporaneamente i tasti freccia (tramite software)?
Puoi disabilitarli nella maggior parte delle visualizzazioni di testo salvando un elenco di proprietà come questo come ~ / Library / KeyBindings / DefaultKeyBinding.dict :
{
"\UF700" = noop:;
"\UF701" = noop:;
"\UF702" = noop:;
"\UF703" = noop:;
"$\UF700" = noop:;
"$\UF701" = noop:;
"$\UF702" = noop:;
"$\UF703" = noop:;
"~\UF700" = noop:;
"~\UF701" = noop:;
"~\UF702" = noop:;
"~\UF703" = noop:;
"~$\UF700" = noop:;
"~$\UF701" = noop:;
"~$\UF702" = noop:;
"~$\UF703" = noop:;
"@\UF700" = noop:;
"@\UF701" = noop:;
"@\UF702" = noop:;
"@\UF703" = noop:;
"@$\UF700" = noop:;
"@$\UF701" = noop:;
"@$\UF702" = noop:;
"@$\UF703" = noop:;
}
Se usi bash, puoi disabilitare i tasti freccia (senza altri tasti modificatori) aggiungendo questo a ~/.inputrc
:
"\e[A":
"\e[B":
"\e[C":
"\e[D":
Se vuoi disabilitarli completamente, puoi aggiungerlo a KeyRemap4MacBook 's private.xml :
<autogen>__KeyToKey__ KeyCode::CURSOR_LEFT, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_RIGHT, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_UP, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_DOWN, KeyCode::VK_NONE</autogen>
Ciò li disabiliterà solo in TextMate, TextEdit, Terminal e iTerm e influirà solo su alcune combinazioni di tasti:
<only>TEXTMATE, EDITOR, TERMINAL</only>
<autogen>__KeyToKey__ KeyCode::CURSOR_LEFT, ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_RIGHT, ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_UP, ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_DOWN, ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_LEFT, VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_RIGHT, VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_UP, VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_DOWN, VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_LEFT, VK_OPTION | VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_RIGHT, VK_OPTION | VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_UP, VK_OPTION | VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_DOWN, VK_OPTION | VK_SHIFT | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_LEFT, VK_OPTION | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_RIGHT, VK_OPTION | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_UP, VK_OPTION | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>
<autogen>__KeyToKey__ KeyCode::CURSOR_DOWN, VK_OPTION | ModifierFlag::NONE, KeyCode::VK_NONE</autogen>