]> git.lyx.org Git - lyx.git/blob - lib/bind/sciword.bind
small fixes
[lyx.git] / lib / bind / sciword.bind
1 # This file is part of LyX
2
3 # LyX keyboard definitions similar to those of Scientific Word.
4 # Prepared by Serge Winitzki. Version 1.2
5
6 # Tip: to find the "LyX name" for a key, look at the status bar after
7 # typing some non-existent key combination. E.g. to find how "Ctrl-&" is
8 # referenced, press Ctrl-S Ctrl-&: the status bar shows "C-s S-C-ampersand."
9
10 #\bind "C-a"                    "------"
11 #\bind "C-b"                    "font-bold"
12
13 # Copy, paste, etc.: more familiar keys
14 \bind "C-c"     "copy"
15
16 # Display equation toggle: type it in a displayed equation to convert it
17 # back to an inline equation
18 # Sciword mnemonic.
19 \bind "C-d"     "math-display"
20
21 #\bind "C-e"    "------"
22 # Greek for only one character. "math-greek-toggle" is the persistent Greek
23 # toggle which nobody really needs when typing math.
24 # Sciword mnemonic.
25 \bind "C-f"     "math-insert frac"
26 \bind "C-g"     "math-greek"
27
28 # Do we need this?
29 #\bind "C-h"    "hyphenation-point-insert"
30
31 # Sciword mnemonic.
32 \bind "C-i"     "math-insert int"
33
34 #\bind "C-j"    "------"
35
36 \bind "C-k"     "line-delete-forward"
37 \bind "C-l"     "screen-recenter"
38
39 # Toggle: in text mode, switch to math, and vice versa. Also C-t.
40 \bind "C-m"     "math-mode"
41 # C-n is numbering equations now. Sciword had "C-Tab" mnemonic which conflicts with many things.
42 # Numbering equations. Should perhaps simplify math-number and math-nonumber into one command since they are used in very different contexts. This and also math-macro stuff should be available in the Lyx menus!
43 \bind "C-n"     "math-number"
44 \bind "S-C-n" "math-nonumber"
45 \bind "C-o"     "inset-toggle"
46
47 # Insert a quote character. Do I need this?
48 # Probably, since we need a way to get a raw quote
49 \bind "C-q"     "self-insert \""
50
51 # Sciword mnemonic.
52 \bind "C-r"     "math-insert sqrt"
53
54 # This combination is now a gateway to math symbols (C-s ...)
55 #\bind "C-s"    "------"
56
57 # Sciword mnemonic for going between text and math modes.
58 \bind "C-t"     "math-mode"
59 \bind "C-u"     "font-underline"
60 \bind "C-v"     "paste"
61 \bind "C-w"     "buffer-close"
62 \bind "C-x"     "cut"
63 \bind "C-z"     "undo"
64 \bind "S-C-z"   "redo"
65
66
67 # This combination makes an umlaut accent now.
68 #\bind "S-C-quotedbl"           "quote-insert"
69
70 # Bracket delimiters. Sciword mnemonic is to press Control-<bracket key>
71
72 \bind "C-9"     "math-delim ( )"
73 \bind "S-C-parenleft"   "math-delim ( )"
74 \bind "C-0"     "math-delim ( )"
75 \bind "S-C-parenright"  "math-delim ( )"
76
77 \bind "C-bracketleft"           "math-delim [ ]"
78 \bind "C-bracketright"  "math-delim [ ]"
79 \bind "C-S-less"                "math-delim langle rangle"
80 \bind "C-S-greater"             "math-delim langle rangle"
81
82 # The bar bracket: on some keyboards, e.g. British, the bar character is
83 # bound to an Alt-something and on some wayward Unices to "brokenbar".
84 \bind "C-S-bar"         "math-delim | |"
85 \bind "C-S-brokenbar"   "math-delim | |"
86 \bind "C-M-bar"         "math-delim | |"
87
88 \bind "S-C-braceleft"           "math-delim { }"
89 \bind "S-C-braceright"          "math-delim { }"
90
91 # Accents by Sciword mnemonics. Mostly press Ctrl-<accent key>
92 # e.g. Ctrl-. for overdot, Ctrl-' for acute accent, Ctrl-~ for tilde etc.
93 # Some of them seem to work only in math mode?
94
95 \bind "C-period"        "accent-dot"
96 \bind "S-C-colon"       "math-insert ddot"
97 \bind "C-quoteleft"     "accent-grave"
98 \bind "S-C-asciitilde"  "accent-tilde"
99 \bind "S-C-quotedbl"    "accent-umlaut"
100 \bind "C-apostrophe"    "accent-acute"
101 \bind "S-C-asciicircum" "accent-circumflex"
102 \bind "C-equal"         "accent-vector"
103 # Why is it not "accent-bar"?
104 \bind "C-minus" "math-insert bar"
105 # What is "accent-underbar"?
106 #\bind "S-C-underscore" "accent-underbar"
107
108 # Function keys.
109
110 #\bind "F1"     "help"  # Not yet implemented!
111 #\bind "C-F1"                   "help-context"                  # Not yet implemented!
112 \bind "F2"                     "buffer-write"
113 \bind "F3"                     "find-replace"
114
115 \bind "C-F4"                   "buffer-close"
116 \bind "M-F4"                   "lyx-quit"
117 # F4 to F8 are used to switch fonts. Sciword mnemonic.
118 \bind "F4"                     "font-default"
119 \bind "F5"                     "font-bold"
120 \bind "F6"                     "font-emph"
121 \bind "F7"                     "font-code"
122 \bind "F8"                     "font-noun"
123 # F9 bound below as meta-prefix (useful e.g. if the keyboard doesn't have a working ALT).
124 #\bind "F9"                     "------"
125 #\bind "F10"                    "------"
126
127 #
128 # Math menu (unmodified)
129 #
130
131 \bind "M-m f"                   "math-insert frac"
132 \bind "M-m i"                   "math-insert int"
133 \bind "M-m o"                   "math-insert oint"
134 \bind "M-m p"                  "math-insert partial"
135 \bind "M-m s"                  "math-insert sqrt"
136 \bind "M-m S-S"                "math-insert sum"
137 \bind "M-m l"                  "math-limits"
138 \bind "M-m n"                  "math-number"
139 \bind "M-m v"                  "accent-vector"
140 \bind "M-m space"              "menu-open Math"
141
142 # Sciword mnemonics for math editing:
143
144 \bind "M-apostrophe"    "math-insert prime"
145 \bind "C-Up"            "math-insert ^"
146 \bind "C-Down"          "math-insert _"
147 \bind "C-s d"           "math-insert partial"
148 \bind "C-s e"           "math-insert sum"
149 \bind "C-s p"           "math-insert prod"
150 \bind "C-s i"           "math-insert infty"
151 \bind "C-s x"           "math-insert times"
152
153 # My own embellishments for symbols I use often.
154
155 #I'd like to combine math-insert ^ and math-insert prime, but don't know how.
156
157 \bind "C-s apostrophe"  "math-insert prime"
158 \bind "C-s S-plus"      "math-insert dagger"
159 \bind "C-s equal"       "math-insert equiv"
160 \bind "M-equal"         "math-insert approx"
161 \bind "M-minus"         "math-insert sim"
162 \bind "C-minus"         "math-insert rightarrow"
163 \bind "S-M-less"        "math-insert leq"
164 \bind "S-M-greater"     "math-insert geq"
165 \bind "C-s S-less"      "math-insert ll"
166 \bind "C-s S-greater"   "math-insert gg"
167
168         ############################
169 ######### Almost no changes below. #########
170         ############################
171
172 #
173 # Motion group
174 #
175
176 \bind "Right"                  "char-forward"
177 \bind "Left"                   "char-backward"
178 \bind "Up"                     "up"
179 \bind "Down"                   "down"
180 \bind "C-Right"                "word-forward"
181 \bind "C-Left"                 "word-backward"
182 # These are now used to insert superscripts and subscripts.
183 #\bind "C-Up"                   "paragraph-up"
184 #\bind "C-Down"                 "paragraph-down"
185 \bind "Home"                   "line-begin"
186 \bind "End"                    "line-end"
187 \bind "Prior"                  "screen-up"
188 \bind "Next"                   "screen-down"
189 \bind "C-Home"                 "buffer-begin"
190 \bind "C-End"                  "buffer-end"
191 \bind "Tab"                    "tab-forward"
192
193 #
194 # Motion + select group
195 #
196
197 \bind "S-Right"                "forward-select"
198 \bind "S-Left"                 "backward-select"
199 \bind "S-Up"                   "up-select"
200 \bind "S-Down"                 "down-select"
201 \bind "S-C-Right"              "word-forward-select"
202 \bind "S-C-Left"               "word-backward-select"
203 \bind "S-C-Up"                 "paragraph-up-select"
204 \bind "S-C-Down"               "paragraph-down-select"
205 \bind "S-Home"                 "line-begin-select"
206 \bind "S-End"                  "line-end-select"
207 \bind "S-Prior"                "screen-up-select"
208 \bind "S-Next"                 "screen-down-select"
209 \bind "S-C-Home"               "buffer-begin-select"
210 \bind "S-C-End"                "buffer-end-select"
211 \bind "C-Insert"               "copy"
212 \bind "S-Insert"               "paste"
213 \bind "S-Delete"               "cut"
214
215 #
216 # Edit group
217 #
218
219 \bind "Delete"                 "delete-forward"
220 \bind "BackSpace"              "delete-backward"
221 \bind "C-Delete"               "word-delete-forward"
222 \bind "C-BackSpace"            "word-delete-backward"
223 \bind "Return"                 "break-paragraph"
224 \bind "M-Return"               "break-paragraph-keep-layout"
225 \bind "C-Return"               "break-line"
226 \bind "C-S-L"                  "ligature-break-insert"
227 \bind "C-space"                "protected-space-insert"
228 \bind "Escape"                 "cancel"
229 \bind "F9"                     "meta-prefix"
230
231 #
232 # Visible Menu access menu
233 #
234
235 #\bind "F10 d"                  "menu-open Documents"
236 #\bind "F10 e"                  "menu-open Edit"
237 #\bind "F10 f"                  "menu-open File"
238 #\bind "F10 h"                  "menu-open Help"
239 #\bind "F10 i"                  "menu-open Insert"
240 #\bind "F10 l"                  "menu-open Layout"
241 #\bind "F10 m"                  "menu-open Math"
242 #\bind "F10 o"                  "menu-open Options"
243
244
245
246 #
247 # File menu
248 #
249
250 #\bind "M-f a"                  "buffer-write-as"
251 #\bind "M-f c"                  "buffer-close"
252 #\bind "M-f n"                  "buffer-new"
253 #\bind "M-f l"                  "file-last"                      # Not yet implemented.
254 #\bind "M-f o"                  "file-open"
255 #\bind "M-f p"                  "buffer-print"
256 #\bind "M-f q"                  "lyx-quit"
257 #\bind "M-f r"                  "buffer-update dvi"
258         # Obsolete
259 #\bind "M-f s"                  "buffer-write"
260 #\bind "M-f t"                  "buffer-update dvi"
261
262 #\bind "M-f x"                  "buffer-view dvi"
263 #\bind "M-f g"                  "buffer-view ps"
264 #\bind "M-f space"              "menu-open File"
265
266
267 #
268 # Edit menu
269 #
270
271 ##\bind "M-e b"                  "table"                         # Not yet implemented!
272 #\bind "M-e c"                  "cut"
273 #\bind "M-e e"                  "error-next"
274 #\bind "M-e f"                  "find-replace"
275 #\bind "M-e k"                  "line-delete-forward"
276 #\bind "M-e m"                  "mark-on"
277 #\bind "M-e S-M"                "mark-off"
278 #\bind "M-e n"                  "note-next"
279 #\bind "M-e o"                  "copy"
280 #\bind "M-e p"                  "paste"
281 #\bind "M-e r"                  "redo"
282 #\bind "M-e s"                  "spellchecker"
283 #\bind "M-e t"                  "toc-update"
284 #\bind "M-e u"                  "undo"
285 #\bind "M-e space"              "menu-open Edit"
286
287
288 #
289 # Layout menu
290 #
291
292 #\bind "M-l c"                  "layout-character"
293 #\bind "M-l p"                  "layout-paragraph"
294 #\bind "M-l d"                  "layout-document"
295 #\bind "M-l q"                  "layout-quotes"
296 #\bind "M-l l"                  "layout-preamble"
297 #\bind "M-l e"                  "font-emph"
298 #\bind "M-l n"                  "font-smallcaps"
299 #\bind "M-l b"                  "font-bold"
300 #\bind "M-l t"                  "ert-insert"
301 #\bind "M-l v"                  "depth-next"
302 #\bind "M-l space"              "menu-open Layout"
303
304
305
306 #
307 # Insert menu
308 #
309
310 #\bind "M-i c"                  "citation-insert"
311 #\bind "M-i f"                  "footnote-insert"
312 #\bind "M-i h"                  "hfill-insert"
313 #\bind "M-i m"                  "marginpar-insert"
314 #\bind "M-i n"                  "note-insert"
315 #\bind "M-i l"                  "label-insert"
316 #\bind "M-i r"                  "reference-insert"
317 #\bind "M-i minus"              "hyphenation-point-insert"
318 #\bind "M-i apostrophe"         "quote-insert"
319 #\bind "M-i S-quotedbl"         "quote-insert"
320 #\bind "M-i space"              "menu-open Insert"
321
322
323
324 #
325 # Options menu
326 #
327
328 #\bind "M-o f"                  "screen-font-options"           # Not yet implemented!
329 #\bind "M-o s"                  "spellcheck-options"            # Not yet implemented!
330 #\bind "M-o k"                  "keyboard-options"              # Not yet implemented!
331 #\bind "M-o l"                  "latex-options"                 # Not yet implemented!
332 #\bind "M-o space"              "menu-open Options"
333
334
335
336 #
337 # Documents menu
338 #
339
340 #\bind "M-d p"                  "buffer-previous"
341 #\bind "M-d space"              "menu-open Documents"
342
343
344
345 #
346 # Help menu
347 #
348
349 #\bind "M-h d"                  "help-documentation"            # Not yet implemented!
350 #\bind "M-h o"                  "help-copyright"                # Not yet implemented!
351 #\bind "M-h w"                  "help-warranty"                 # Not yet implemented!
352 #\bind "M-h c"                  "help-credits"                  # Not yet implemented!
353 #\bind "M-h v"                  "help-version"                  # Not yet implemented!
354 #\bind "M-h space"              "menu-open Help"
355
356
357
358 #
359 # Font size menu
360 #
361
362 \bind "M-s S-A"                "font-size largest"             # \LARGE
363 \bind "M-s g"                  "font-size giant"               # \Huge
364 \bind "M-s h"                  "font-size huge"                # \huge
365 \bind "M-s S-H"                "font-size giant"               # \Huge
366 \bind "M-s l"                  "font-size large"               # \large
367 \bind "M-s S-L"                "font-size larger"              # \Large
368 \bind "M-s n"                  "font-size normal"              # \normalsize
369 \bind "M-s s"                  "font-size small"               # \small
370 \bind "M-s t"                  "font-size tiny"                # \tiny
371
372 \bind "M-s 1"                  "font-size tiny"
373 \bind "M-s 2"                  "font-size small"
374 \bind "M-s 3"                  "font-size normal"
375 \bind "M-s 4"                  "font-size large"
376 \bind "M-s 5"                  "font-size larger"
377 \bind "M-s 6"                  "font-size largest"
378 \bind "M-s 7"                  "font-size huge"
379 \bind "M-s 8"                  "font-size giant"
380
381
382
383 #
384 # Alignment menu
385 #
386
387 #\bind "M-a l"                  "para-align left"               # Not yet implemented!
388 #\bind "M-a r"                  "para-align right"              # Not yet implemented!
389 #\bind "M-a c"                  "para-align center"             # Not yet implemented!
390 #\bind "M-a b"                  "para-align block"              # Not yet implemented!
391 #\bind "M-a f"                  "para-align block"              # Not yet implemented!
392 #\bind "M-a d"                  "para-align default"            # Not yet implemented!
393
394
395
396 #
397 # Paragraph style menu
398 #
399
400 \bind "M-p c"                  "drop-layouts-choice"
401 \bind "M-p 1"                  "layout Chapter"
402 \bind "M-p 2"                  "layout Section"
403 \bind "M-p 3"                  "layout Subsection"
404 \bind "M-p 4"                  "layout Subsubsection"
405 \bind "M-p 5"                  "layout Paragraph"
406 \bind "M-p 6"                  "layout Subparagraph"
407 \bind "M-p b"                  "layout Itemize"                        # bulleted list
408 \bind "M-p d"                  "layout Description"
409 \bind "M-p e"                  "layout Enumerate"                      # numbered list
410 \bind "M-p i"                  "layout Itemize"                        # bulleted list
411 \bind "M-p l"                  "layout List"
412 \bind "M-p n"                  "layout Enumerate"                      # numbered list
413 \bind "M-p p"                  "layout Lyx-Code"
414 \bind "M-p q"                  "layout Quote"
415 \bind "M-p S-Q"                "layout Quotation"
416 \bind "M-p s"                  "layout Standard"
417 \bind "M-p t"                  "layout Title"
418 \bind "M-p S-at"               "layout Section*"                       # M-p S-2
419 \bind "M-p S-dollar"           "layout Subsubsection*"                 # M-p S-4
420 \bind "M-p S-numbersign"       "layout Subsection*"                    # M-p S-3
421
422 \bind "M-p Left"               "depth-decrement"
423 \bind "M-p Right"              "depth-increment"
424
425
426
427 #
428 # Character style menu
429 #
430
431 \bind "M-c b"                  "font-bold"
432 #\bind "M-c c"                  "font-smallcaps"
433 \bind "M-c e"                  "font-emph"
434 \bind "M-c i"                  "font-emph"                                              # italics
435 \bind "M-c m"                  "math-mode"
436 \bind "M-c p"                  "font-code"
437 \bind "M-c r"                  "font-roman"
438 \bind "M-c s"                  "font-sans"
439 \bind "M-c t"                  "ert-insert"
440 \bind "M-c u"                  "font-underline"
441
442 \bind "M-c Down"               "word-lowcase"
443 \bind "M-c Up"                 "word-upcase"
444 \bind "M-c Right"              "word-capitalize"
445
446 \bind "M-c space"              "font-default"
447
448
449
450 #
451 # Keyboard menu
452 #
453
454 \bind "M-k 1"                  "keymap-primary"
455 \bind "M-k 2"                  "keymap-secondary"
456 \bind "M-k o"                  "keymap-off"
457 \bind "M-k t"                  "keymap-toggle"
458 \bind "M-k x"                  "keymap-off"
459
460
461
462 #
463 # Misc menu
464 #
465
466 \bind "M-x c"                  "screen-recenter"
467
468 \bind_file latinkeys.bind