@Lri's answer is awesome (thank you so much; this was driving me insane), but I ended up modifying it a little.
(In this answer, I use the non-applyApple names for keys, so commandCommand = superSuper and optionOption = altAlt)
Super-leftSuperLeft and super-rightSuperRight used to actually be mapped to moveToLeftEndOfLine
and moveToRightEndOfLine
. Using moveToBeginningOfLine
and moveToEndOfLine
, like @Lri does, may cause inconsistent behaviour.
There are whole bunch of other differences between the applyApple shortcuts and literally everybody else's shortcuts ,thatthat I added. For example, ctrl-leftControlLeft and ctrl-rightControlRight are supposed to move between words; not alt-leftAltLeft and alt-rightAltLeft. I don't think this is exhaustive, but it's working pretty well for me right now. I assumed the user has already swapped the controlControl and superSuper keys to fix cutting, copying, and pasting.
~/Library/KeyBindings/DefaultKeyBinding.dict:
{
"\UF729" = moveToLeftEndOfLine:; // home
"\UF72B" = moveToRightEndOfLine:; // end
"$\UF729" = moveToBeginningOfLineAndModifySelection:; // shift-home
"$\UF72B" = moveToEndOfLineAndModifySelection:; // shift-end
"@\UF700" = moveUp:; //super-up
"@\UF701" = moveDown:; //super-down
"@\UF702" = moveWordLeft:; //super-left
"@\UF703" = moveWordRight:; //super-right
"@$\UF700" = moveUpAndModifySelection:; // super-shift-up
"@$\UF701" = moveDownAndModifySelection:; // super-shift-down
"@$\UF702" = moveWordLeftAndModifySelection:; // super-shift-left
"@$\UF703" = moveWordRightAndModifySelection:; // super-shift-right
"@\UF728" = deleteWordForward:; // super-delete
"@\U7F" = deleteWordBackward:; // super-backspace
}