I am a full-time .NET Developer, so I work in Windows 10 at work; however, I definitely prefer macOS and use it at home. I am a constant user of the Home and End keys and they make me so much more efficient. Is there any way to force the Home and End keys on macOS to behave like Windows 10?
What I Want
Home: Sends cursor to beginning of current line
End: Sends cursor to end of current line
Shift-Home: Sends cursor to beginning of current line with selection
Shift-End: Sends cursor to end of current line with selection
Command-Home: Sends cursor to beginning of current document
Command-End: Sends cursor to end of current document
Shift-Command-Home: Sends cursor to beginning of current document with selection
Shift-Command-End: Sends cursor to end of current document with selection
What I've Tried
A simple Google search provided me with the possible solution of adding custom NSResponder entries in ~/Library/KeyBindings/DefaultKeyBinding.dict
and rebooting. Unfortunately, that does not seem to have worked. I have tested it in Xcode, Sublime Text, and Safari. The keys appear to behave in the normal macOS manner.
{
"\UF729" = "moveToBeginningOfLine:";
"\UF72B" = "moveToEndOfLine:";
"$\UF729" = "moveToBeginningOfLineAndModifySelection:";
"$\UF72B" = "moveToEndOfLineAndModifySelection:";
}
I have also tried using BetterTouchTool to set a keyboard shortcut mapping Home to Command-Left and End to Command-Right. That works for Home and End but it doesn't work for the selecting text nor for navigating the document
What I'm Using
- Mid-2012 non-Retina MacBook Pro
- macOS High Sierra Public Beta 5
- Apple Magic Keyboard
- Xcode, Sublime Text, Safari specifically
Bonus Points
Command-Left: Sends cursor to beginning of word
Command-Right: Sends cursor to end of word
Shift-Command-Left: Sends cursor to beginning of word with selection
Shift-Command-Right: Sends cursor to end of word with selection