2 # ==================================================================
4 # LyX, the High Level Word Processor
6 # Copyright (C) 1995-1997 Asger Alstrup & The LyX Team
8 # ==================================================================
11 # This is the Mac flavour bind file for LyX/Mac 2.0.x, based on
12 # bindings found in the Mac world.
14 # DO NOT CHANGE THIS DEFAULT BINDING FILE! It will be replaced
15 # with every new install of LyX and your changes will be lost.
16 # Instead, customize a copy of this file placed in
31 # based on the table at http://support.apple.com/kb/HT1343
32 # Note: these bindings assume the swapped Meta and Control modifiers standard of Qt
37 # Status indicates if it is matching the mac standard
39 # -: missing or wrong binding
40 # Status: "Key combination" What it does
41 # +: "Command-Space" # Show or hide the Spotlight search field (if multiple languages are installed, may rotate through enabled script systems)
42 # +: "Option-Command-Space" # Show the Spotlight search results window (if multiple languages are installed, may rotate through keyboard layouts and input methods within a script)
43 # +: "Command-esc" # Open Front Row (if installed)
44 # +: "Option-Eject" # Eject from secondary optical media drive (if one is installed)
45 # +: "Control-Eject" # Show shutdown dialog
46 # +: "Option-Command-Eject" # Put the computer to sleep
47 # +: "Control-Command-Eject" # Quit all applications (after giving you a chance to save changes to open documents), then restart the computer
48 # +: "Control Option-Command-Eject" # Quit all applications (after giving you a chance to save changes to open documents), then shut down the computer
49 # +: "Command-Tab" # Move forward to the next most recently used application in a list of open applications
50 # +: "Shift-Command-Tab" # Move backward through a list of open applications (sorted by recent use)
51 # -: "Control-A" # Move to beginning of line/paragraph
52 # used by menu.bind - paragraph-params
53 # +: "Control-B" # Move one character backward
54 \bind "M-b" "char-backward"
55 # +: "Control-D" # Delete the character in front of the cursor
56 \bind "M-d" "char-delete-forward"
57 # +: "Control-E" # Move to end of line/paragraph
58 \bind "M-e" "line-end"
59 # +: "Control-F" # Move one character forward
60 \bind "M-f" "char-forward"
61 # +: "Control-H" # Delete the character behind the cursor
62 \bind "M-h" "char-delete-backward"
63 # -: "Control-K" # Delete from the character in front of the cursor to the end of the line/paragraph
64 # used by menu.bind - keymap
65 # +: "Control-L" # Center the cursor/selection in the visible area
66 \bind "M-l" "screen-recenter"
67 \bind "F5" "screen-recenter"
68 # +: "Control-N" # Move down one line
70 # +: "Control-O" # Insert a new line after the cursor
71 \bind "M-o" "break-paragraph"
72 # -: "Control-P" # Move up one line
73 # used by menu.bind - layouts
74 # +: "Control-T" # Transpose the character behind the cursor and the character in front of the cursor
75 \bind "M-t" "chars-transpose"
76 # +: "Control-V" # Move down one page
77 \bind "M-v" "scroll page up"
78 # -: "Shift-Tab" # Navigate through controls in a reverse direction
79 # +: "Control-Tab" # Move focus to the next grouping of controls in a dialog or the next table (when Tab moves to the next cell)
80 \bind "M-Tab" "buffer-next"
81 # +: "Shift-Control-Tab" # Move focus to the previous grouping of controls
82 \bind "M-S-BackTab" "buffer-previous"
83 # +: "fn-Delete" # Forward Delete (on portable Macs' built-in keyboard)
84 \bind "Delete" "char-delete-forward"
85 # ?: "Control-F1" # Toggle full keyboard access on or off
86 # +: "Control-F2" # Move focus to the menu bar
87 # +: "Control-F3" # Move focus to the Dock
88 # +: "Control-F4" # Move focus to the active (or next) window
89 # +: "Shift-Control-F4" # Move focus to the previously active window
90 # -: "Control-F5" # Move focus to the toolbar.
91 # -: "Control-F6" # Move focus to the first (or next) panel
92 # -: "Shift-Control-F6" # Move focus to the previous panel
93 # -: "Control-F7" # Temporarily override the current keyboard access mode in windows and dialogs
94 # -: "F9" # Tile or untile all open windows
95 # -: "F10" # Tile or untile all open windows in the currently active application
96 # +: "F11" # Hide or show all open windows
97 # +: "F12" # Hide or display Dashboard
98 # -: "Command-`" # Activate the next open window in the frontmost application
99 # -: "Shift-Command-`" # Activate the previous open window in the frontmost application
100 # -: "Option-Command-`" # Move focus to the window drawer
101 # +: "Command- - (minus)" # Decrease the size of the selected item
102 \bind "C-minus" "buffer-zoom-out"
103 # +: "Shift-Command-=" # Increase the size of the selected item
104 \bind "C-plus" "buffer-zoom-in"
105 \bind "C-S-equal" "buffer-zoom-in"
106 \bind "C-equal" "buffer-zoom-in"
107 # -: "Command-{" # Left-align a selection
108 # -: "Command-}" # Right-align a selection
109 # -: "Command-|" # Center-align a selection
110 # -: "Command-:" # Display the Spelling window
111 # +: "Command-;" # Find misspelled words in the document
112 \bind "C-S-semicolon" "dialog-show spellchecker"
113 # +: "Command-," # Open the front application's preferences window (if it supports this keyboard shortcut)
114 \bind "C-comma" "dialog-show prefs"
115 # +: "Option-Control-Command-," # Decrease screen contrast
116 # +: "Option-Control-Command-." # Increase screen contrast
117 # -: "Command-?" # Open the application's help in Help Viewer
118 # -: "Option-Command-/" # Turn font smoothing on or off
119 # +: "Shift-Command-3" # Capture the screen to a file
120 # +: "Shift-Control-Command-3" # Capture the screen to the Clipboard
121 # +: "Shift-Command-4" # Capture a selection to a file
122 # +: "Shift-Control-Command-4" # Capture a selection to the Clipboard
123 # +: "Command-A" # Highlight every item in a document or window, or all characters in a text field
124 \bind "C-a" "command-sequence buffer-begin ; buffer-end-select"
125 \bind "C-M-a" "inset-select-all"
126 # +: "Command-B" # Boldface the selected text or toggle boldfaced text on and off
127 \bind "C-M-b" "font-boldsymbol"
128 \bind "C-b" "font-bold"
129 # +: "Command-C" # Copy the selected data to the Clipboard
131 # -: "Shift-Command-C" # Display the Colors window
132 # -: "Option-Command-C" # Copy the style of the selected text
133 # -: "Control-Command-C" # Copy the formatting settings of the selected item and store on the Clipboard
134 # +: "Option-Command-D" # Show or hide the Dock
135 # -: "Command-Control D" # Display the definition of the selected word in the Dictionary application
136 \bind "C-d" "buffer-view dvi" # 'd' for dvi
137 \bind "C-M-d" "master-buffer-view dvi"
138 \bind "C-S-D" "buffer-update dvi" # 'd' for dvi
139 # -: "Command-E" # Use the selection for a find
140 \bind "C-e" "font-emph"
141 # +: "Command-F" # Open a Find window
142 \bind "C-f" "dialog-show findreplace"
143 \bind "C-S-f" "dialog-show findreplaceadv"
144 # -: "Option-Command-F" # Move to the search field control
145 # +: "Command-G" # Find the next occurrence of the selection
146 \bind "C-g" "word-find-forward"
147 # +: "Shift-Command-G" # Find the previous occurrence of the selection
148 \bind "C-S-g" "word-find-backward"
149 # +: "Command-H" # Hide the windows of the currently running application
150 # +: "Option-Command-H" # Hide the windows of all other running applications
151 # -: "Command-I" # Italicize the selected text or toggle italic text on or off
152 \bind "C-i" "inset-toggle" # 'i' for Inset
153 # -: "Option-Command-I" # Display an inspector window
154 # -: "Command-J" # Scroll to a selection
155 \bind "C-k" "line-delete-forward"
156 # -: "Command-M" # Minimize the active window to the Dock
157 # -: "Option-Command-M" # Minimize all windows of the active application to the Dock
158 \bind "C-m" "math-mode"
159 \bind "C-S-M" "math-display"
160 \bind "C-M-n" "command-sequence math-display; math-number-toggle;"
161 # +: "Command-N" # Create a new document in the frontmost application
162 \bind "C-n" "buffer-new"
163 \bind "C-S-N" "buffer-new-template"
164 # +: "Command-O" # Display a dialog for choosing a document to open in the frontmost application
165 \bind "C-o" "file-open"
166 # +: "Command-P" # Display the Print dialog
167 \bind "C-p" "dialog-show print"
168 # -: "Shift-Command-P" # Display a dialog for specifying printing parameters (Page Setup)
169 \bind "C-S-P" "font-typewriter" # 'P' for Program
170 # +: "Command-Q" # Quit the frontmost application
171 \bind "C-q" "lyx-quit"
172 \bind "C-r" "buffer-view"
173 # +: "Command-S" # Save the active document
174 \bind "C-s" "buffer-write"
175 # +: "Shift-Command-S" # Display the Save As dialog
176 \bind "C-S-S" "buffer-write-as"
177 # -: "Command-T" # Display the Fonts window
178 \bind "C-t" "buffer-view pdf"
179 \bind "C-M-t" "master-buffer-view pdf"
180 # -: "Option-Command-T" # Show or hide a toolbar
181 # -: "Command-U" # Underline the selected text or turn underlining on or off
182 \bind "C-u" "font-underline"
183 # +: "Command-V" # Paste the Clipboard contents at the insertion point
185 \bind "C-S-v" "clipboard-paste"
186 # -: "Option-Command-V" # Apply the style of one object to the selected object (Paste Style)
187 # -: "Option-Shift-Command-V" # Apply the style of the surrounding text to the inserted object (Paste and Match Style)
188 # -: "Control-Command-V" # Apply formatting settings to the selected object (Paste Ruler Command)
189 \bind "C-M-v" "primary-selection-paste"
190 # ?: "Command-W" # Close the frontmost window
191 \bind "C-w" "buffer-close" # should be "window-close"
192 # +: "Shift-Command-W" # Close a file and its associated windows
193 \bind "C-S-w" "buffer-close"
194 # +: "Option-Command-W" # Close all windows in the application without quitting it
195 \bind "C-A-w" "buffer-close-all"
196 # +: "Command-X" # Remove the selection and store in the Clipboard
198 \bind "M-x" "command-execute"
199 # -: "Command-Z" # Undo previous command (some applications allow for multiple Undos)
201 # -: "Shift-Command-Z" # Redo previous command (some applications allow for multiple Redos)
203 # -: "Control-Right Arrow" # Move focus to another value or cell within a view, such as a table
204 # -: "Control-Left Arrow" # Move focus to another value or cell within a view, such as a table
205 # -: "Control-Down Arrow" # Move focus to another value or cell within a view, such as a table
206 # -: "Control-Up Arrow" # Move focus to another value or cell within a view, such as a table
207 # +: "Command-Right Arrow" # Move the text insertion point to the end of the current line
208 \bind "C-Right" "line-end"
209 # +: "Command-Left Arrow" # Move the text insertion point to the beginning of the current line
210 \bind "C-Left" "line-begin"
211 # +: "Command-Down Arrow" # Move the text insertion point to the end of the document
212 \bind "C-Down" "buffer-end"
213 \bind "M-A-Down" "inset-end"
214 # +: "Command-Up Arrow" # Move the text insertion point to the beginning of the document
215 \bind "C-Up" "buffer-begin"
216 \bind "M-A-Up" "inset-begin"
217 # +: "Shift-Command-Right Arrow" # Select text between the insertion point and the end of the current line (*)
218 \bind "S-C-Right" "line-end-select"
219 # +: "Shift-Command-Left Arrow" # Select text between the insertion point and the beginning of the current line (*)
220 \bind "S-C-Left" "line-begin-select"
221 # +: "Shift-Right Arrow" # Extend text selection one character to the right (*)
222 \bind "S-Right" "char-right-select"
223 # +: "Shift-Left Arrow" # Extend text selection one character to the left (*)
224 \bind "S-Left" "char-left-select"
225 # +: "Shift-Command-Up Arrow" # Select text between the insertion point and the beginning of the document (*)
226 \bind "S-C-Up" "buffer-begin-select"
227 # +: "Shift-Command-Down Arrow" # Select text between the insertion point and the end of the document (*)
228 \bind "S-C-Down" "buffer-end-select"
229 # +: "Shift-Up Arrow" # Extend text selection to the line above, to the nearest character boundary at the same horizontal location (*)
230 \bind "S-Up" "up-select"
231 # +: "Shift-Down Arrow" # Extend text selection to the line below, to the nearest character boundary at the same horizontal location (*)
232 \bind "S-Down" "down-select"
233 # +: "Shift-Option-Right Arrow" # Extend text selection to the end of the current word, then to the end of the following word if pressed again (*)
234 \bind "A-Right" "word-right"
235 \bind "S-A-Right" "word-right-select"
236 # +: "Shift-Option-Left Arrow" # Extend text selection to the beginning of the current word, then to the beginning of the following word if pressed again (*)
237 \bind "A-Left" "word-left"
238 \bind "S-A-Left" "word-left-select"
239 # +: "Shift-Option-Down Arrow" # Extend text selection to the end of the current paragraph, then to the end of the following paragraph if pressed again (*)
240 \bind "A-Down" "paragraph-down"
241 \bind "S-A-Down" "paragraph-down-select"
242 \bind "S-M-A-Down" "inset-end-select"
243 # +: "Shift-Option-Up Arrow" # Extend text selection to the beginning of the current paragraph, then to the beginning of the following paragraph if pressed again (*)
244 \bind "A-Up" "paragraph-up"
245 \bind "S-A-Up" "paragraph-up-select"
246 \bind "S-M-A-Up" "inset-begin-select"
247 # -: "Control-Space" # Toggle between the current and previous input sources
248 # -: "Option-Control-Space" # Toggle through all enabled input sources
249 # +: "Option-Command-esc" # Force Quit
251 # Additional commands
253 \bind "C-S-O" "font-strikeout"
254 \bind "C-S-T" "buffer-update pdf" # (pdflatex; was "ps")
255 \bind "C-S-R" "buffer-update"
256 \bind "C-M-S-T" "master-buffer-update pdf"
257 \bind "C-M-S-D" "master-buffer-update dvi"
259 \bind "C-S-E" "changes-track" # it's what MS Word uses
260 \bind "~S-M-quotedbl" "quote-insert single"
261 \bind "~S-C-quotedbl" "self-insert \""
262 \bind "C-S-underscore" "command-alternatives math-macro-fold;specialchar-insert hyphenation"
263 \bind "C-M-minus" "specialchar-insert nobreakdash"
264 \bind "M-C-Right" "depth-increment"
265 \bind "M-C-Left" "depth-decrement"
266 \bind "C-S-L" "specialchar-insert ligature-break"
267 \bind "C-l" "ert-insert" # 'l' for LaTeX
268 \bind "C-S-I" "info-insert"
270 #bind "F1" "help" # Not yet implemented!
271 #bind "C-F1" "help-context" # Not yet implemented!
272 \bind "F2" "buffer-write"
273 \bind "C-F4" "buffer-close"
274 \bind "C-A-Up" "scroll line up"
275 \bind "C-A-Down" "scroll line down"
276 \bind "C-A-Prior" "scroll page up"
277 \bind "C-A-Next" "scroll page down"
278 \bind "F7" "dialog-show spellchecker"
279 \bind "S-F7" "thesaurus-entry"
281 \bind "C-M-o" "dialog-show toc"
284 # Additional Motion group
287 \bind "C-~S-greater" "label-goto"
288 \bind "C-~S-less" "bookmark-goto 0"
291 # Additional Motion + select group
294 \bind "S-Prior" "screen-up-select"
295 \bind "S-Next" "screen-down-select"
296 \bind "C-Insert" "copy"
297 \bind "S-Insert" "paste"
298 \bind "S-Delete" "cut"
300 # Numeric keypad (if Shift+KP_XXX does not switch the NumLock state)
301 \bind "S-KP_Right" "char-right-select"
302 \bind "S-KP_Left" "char-left-select"
303 \bind "S-KP_Up" "up-select"
304 \bind "S-KP_Down" "down-select"
305 \bind "S-M-KP_Right" "word-right-select"
306 \bind "S-M-KP_Left" "word-left-select"
307 \bind "S-M-KP_Up" "paragraph-up-select"
308 \bind "S-M-KP_Down" "paragraph-down-select"
309 \bind "S-KP_Home" "line-begin-select"
310 \bind "S-KP_End" "line-end-select"
311 \bind "S-KP_Prior" "screen-up-select"
312 \bind "S-KP_Next" "screen-down-select"
313 \bind "S-C-KP_Home" "buffer-begin-select"
314 \bind "S-C-KP_End" "buffer-end-select"
315 \bind "S-C-KP_Prior" "buffer-begin-select"
316 \bind "S-C-KP_Next" "buffer-end-select"
317 \bind "C-KP_Insert" "copy"
318 \bind "S-KP_Insert" "paste"
319 \bind "S-KP_Delete" "cut"
325 \bind "C-~S-1" "bookmark-goto 1"
326 \bind "C-~S-2" "bookmark-goto 2"
327 \bind "C-~S-3" "bookmark-goto 3"
328 \bind "C-~S-4" "bookmark-goto 4"
329 \bind "C-~S-5" "bookmark-goto 5"
330 \bind "C-~S-6" "bookmark-goto 6"
331 \bind "C-~S-7" "bookmark-goto 7"
332 \bind "C-~S-8" "bookmark-goto 8"
333 \bind "C-~S-9" "bookmark-goto 9"
334 \bind "C-M-~S-1" "bookmark-save 1"
335 \bind "C-M-~S-2" "bookmark-save 2"
336 \bind "C-M-~S-3" "bookmark-save 3"
337 \bind "C-M-~S-4" "bookmark-save 4"
338 \bind "C-M-~S-5" "bookmark-save 5"
339 \bind "C-M-~S-6" "bookmark-save 6"
340 \bind "C-M-~S-7" "bookmark-save 7"
341 \bind "C-M-~S-8" "bookmark-save 8"
342 \bind "C-M-~S-9" "bookmark-save 9"
345 # Additional Edit group
348 \bind "A-Delete" "word-delete-forward"
349 \bind "A-BackSpace" "word-delete-backward"
350 \bind "M-Return" "break-paragraph inverse"
351 \bind "C-Return" "newline-insert newline"
352 \bind "C-S-Return" "newline-insert linebreak"
353 \bind "A-space" "command-alternatives space-insert protected ; math-space"
354 \bind "nobreakspace" "space-insert protected"
355 \bind "C-A-space" "space-insert normal"
356 \bind "S-A-space" "space-insert thin"
357 \bind "C-~S-slash" "specialchar-insert slash"
358 \bind "C-period" "specialchar-insert end-of-sentence"
359 \bind "M-period" "specialchar-insert dots"
360 \bind "Escape" "cancel"
361 \bind "C-M-Up" "paragraph-move-up"
362 \bind "C-M-Down" "paragraph-move-down"
363 #\bind "F9" "meta-prefix"
365 # Include menu and math bindings
367 \bind_file menus.bind
369 \bind_file latinkeys.bind
370 \bind_file cyrkeys.bind
371 \bind_file greekkeys.bind