summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlen <alen@dotfiles.xyz>2023-09-14 01:20:02 +0400
committerAlen <alen@dotfiles.xyz>2023-09-14 01:36:41 +0400
commitea9d5f41c1c93bac9703fd0cd89859fa18d40c59 (patch)
tree0a940f32c9d9499826591d94f66d1853bcfd7b3f
parent0266521687393cb5e1f816bcdb9631147a23b19c (diff)
Add some macOS default keybindings
-rw-r--r--private_Library/KeyBindings/DefaultKeyBinding.dict87
1 files changed, 87 insertions, 0 deletions
diff --git a/private_Library/KeyBindings/DefaultKeyBinding.dict b/private_Library/KeyBindings/DefaultKeyBinding.dict
new file mode 100644
index 0000000..7db34bd
--- /dev/null
+++ b/private_Library/KeyBindings/DefaultKeyBinding.dict
@@ -0,0 +1,87 @@
+/*
+Modifiers:
+  ^ : ctrl
+  $ : shift
+  ~ : option
+  @ : command
+  # : numeric keypad
+
+Non-Printable Key Codes:
+  Standard
+  Up Arrow:     \UF700        Backspace:    \U0008        F1:           \UF704
+  Down Arrow:   \UF701        Tab:          \U0009        F2:           \UF705
+  Left Arrow:   \UF702        Escape:       \U001B        F3:           \UF706
+  Right Arrow:  \UF703        Enter:        \U000A        ...
+  Insert:       \UF727        Page Up:      \UF72C
+  Delete:       \UF728        Page Down:    \UF72D
+  Home:         \UF729        Print Screen: \UF72E
+  End:          \UF72B        Scroll Lock:  \UF72F
+  Break:        \UF732        Pause:        \UF730
+  SysReq:       \UF731        Menu:         \UF735
+  Help:         \UF746
+
+  OS X
+  delete:       \U007F
+
+For a good reference see http://osxnotes.net/keybindings.html.
+*/
+
+{
+  "^w" = (deleteWordBackward:);
+  "^h" = (deleteBackward:);
+  "^l" = (deleteForward:);
+  "^b" = (moveBackward:);
+  "^f" = (moveForward:);
+
+  "~w" = (selectWord:);
+  "~S" = (selectParagraph:);
+  "~s" = (moveToBeginningOfParagraph:, moveToEndOfParagraphAndModifySelection:);
+  "~q" = (moveToBeginningOfParagraphAndModifySelection:, cut:);
+  "~k" = (moveToEndOfParagraphAndModifySelection:, cut:);
+
+  "~1" = (setMark:);
+  "~2" = (swapWithMark:,centerSelectionInVisibleArea:);
+
+
+
+    "@\UF72B"  = "moveToEndOfDocument:";                         /* Cmd  + End   */
+    "~@\UF703" = "moveToEndOfDocument:";                         /* Cmd + Option + Right Arrow */
+
+    "@$\UF72B" = "moveToEndOfDocumentAndModifySelection:";       /* Shift + Cmd  + End */
+
+    "@\UF729"  = "moveToBeginningOfDocument:";                   /* Cmd  + Home  */
+    "~@\UF702" = "moveToBeginningOfDocument:";                   /* Cmd + Option + Left Arrow */
+
+    "@$\UF729" = "moveToBeginningOfDocumentAndModifySelection:"; /* Shift + Cmd  + Home */
+
+    "\UF729"   = "moveToBeginningOfLine:";                       /* Home         */
+    "~\UF702"  = "moveToBeginningOfLine:";                       /* Option + Left Arrow */
+
+    "$\UF729"  = "moveToBeginningOfLineAndModifySelection:";     /* Shift + Home */
+    "$~\UF702" = "moveToBeginningOfLineAndModifySelection:";     /* Shift + Option + Right Arrow */
+
+    "\UF72B"   = "moveToEndOfLine:";                             /* End          */
+    "~\UF703"  = "moveToEndOfLine:";                             /* Option + Right Arrow */
+
+    "$\UF72B"  = "moveToEndOfLineAndModifySelection:";           /* Shift + End  */
+    "$~\UF703" = "moveToEndOfLineAndModifySelection:";           /* Shift + Option + Left Arrow  */
+
+    "\UF72C"   = "pageUp:";                                      /* PageUp       */
+    "\UF72D"   = "pageDown:";                                    /* PageDown     */
+
+    "$\UF728"  = "cut:";                                         /* Shift + Del  */
+    "$\UF727"  = "paste:";                                       /* Shift + Ins */
+    "@\UF727"  = "copy:";                                        /* Cmd  + Ins  */
+    "$\UF746"  = "paste:";                                       /* Shift + Help */
+    "@\UF746"  = "copy:";                                        /* Cmd  + Help (Ins) */
+
+  "~\UF700" = (pageUp:);
+  "~\UF701" = (pageDown:);
+
+  "^\UF702" = (moveWordBackward:);       // ctrl-left
+  "^\UF703" = (moveWordForward:);        // ctrl-right
+  "@\UF702" = (moveWordBackward:);       // command-left
+  "@\UF703" = (moveWordForward:);        // command-right
+  "~\UF702" = (moveToBeginningOfLine:);  // option-left
+  "~\UF703" = (moveToEndOfLine:);        // option-right
+}