comparison src/keymap.c @ 5118:e0db3c197671 ben-lisp-object

merge up to latest default branch, doesn't compile yet
author Ben Wing <ben@xemacs.org>
date Sat, 26 Dec 2009 21:18:49 -0600
parents 3742ea8250b5 2fd201d73a92
children d1247f3cc363
comparison
equal deleted inserted replaced
5117:3742ea8250b5 5118:e0db3c197671
215 int mice_only_p, 215 int mice_only_p,
216 Lisp_Object buffer); 216 Lisp_Object buffer);
217 static Lisp_Object keymap_submaps (Lisp_Object keymap); 217 static Lisp_Object keymap_submaps (Lisp_Object keymap);
218 218
219 Lisp_Object Qcontrol, Qctrl, Qmeta, Qsuper, Qhyper, Qalt, Qshift; 219 Lisp_Object Qcontrol, Qctrl, Qmeta, Qsuper, Qhyper, Qalt, Qshift;
220 Lisp_Object Qbutton0, Qbutton1, Qbutton2, Qbutton3; 220 Lisp_Object Qbutton0;
221 Lisp_Object Qbutton4, Qbutton5, Qbutton6, Qbutton7; 221 Lisp_Object Qbutton1, Qbutton2, Qbutton3, Qbutton4, Qbutton5;
222 Lisp_Object Qbutton0up, Qbutton1up, Qbutton2up, Qbutton3up; 222 Lisp_Object Qbutton6, Qbutton7, Qbutton8, Qbutton9, Qbutton10;
223 Lisp_Object Qbutton4up, Qbutton5up, Qbutton6up, Qbutton7up; 223 Lisp_Object Qbutton11, Qbutton12, Qbutton13, Qbutton14, Qbutton15;
224 Lisp_Object Qbutton16, Qbutton17, Qbutton18, Qbutton19, Qbutton20;
225 Lisp_Object Qbutton21, Qbutton22, Qbutton23, Qbutton24, Qbutton25;
226 Lisp_Object Qbutton26;
227 Lisp_Object Qbutton0up;
228 Lisp_Object Qbutton1up, Qbutton2up, Qbutton3up, Qbutton4up, Qbutton5up;
229 Lisp_Object Qbutton6up, Qbutton7up, Qbutton8up, Qbutton9up, Qbutton10up;
230 Lisp_Object Qbutton11up, Qbutton12up, Qbutton13up, Qbutton14up, Qbutton15up;
231 Lisp_Object Qbutton16up, Qbutton17up, Qbutton18up, Qbutton19up, Qbutton20up;
232 Lisp_Object Qbutton21up, Qbutton22up, Qbutton23up, Qbutton24up, Qbutton25up;
233 Lisp_Object Qbutton26up;
224 234
225 Lisp_Object Qmenu_selection; 235 Lisp_Object Qmenu_selection;
226 /* Emacs compatibility */ 236 /* Emacs compatibility */
227 Lisp_Object Qdown_mouse_1, Qmouse_1; 237 Lisp_Object Qdown_mouse_1, Qmouse_1;
228 Lisp_Object Qdown_mouse_2, Qmouse_2; 238 Lisp_Object Qdown_mouse_2, Qmouse_2;
229 Lisp_Object Qdown_mouse_3, Qmouse_3; 239 Lisp_Object Qdown_mouse_3, Qmouse_3;
230 Lisp_Object Qdown_mouse_4, Qmouse_4; 240 Lisp_Object Qdown_mouse_4, Qmouse_4;
231 Lisp_Object Qdown_mouse_5, Qmouse_5; 241 Lisp_Object Qdown_mouse_5, Qmouse_5;
232 Lisp_Object Qdown_mouse_6, Qmouse_6; 242 Lisp_Object Qdown_mouse_6, Qmouse_6;
233 Lisp_Object Qdown_mouse_7, Qmouse_7; 243 Lisp_Object Qdown_mouse_7, Qmouse_7;
244 Lisp_Object Qdown_mouse_8, Qmouse_8;
245 Lisp_Object Qdown_mouse_9, Qmouse_9;
246 Lisp_Object Qdown_mouse_10, Qmouse_10;
247 Lisp_Object Qdown_mouse_11, Qmouse_11;
248 Lisp_Object Qdown_mouse_12, Qmouse_12;
249 Lisp_Object Qdown_mouse_13, Qmouse_13;
250 Lisp_Object Qdown_mouse_14, Qmouse_14;
251 Lisp_Object Qdown_mouse_15, Qmouse_15;
252 Lisp_Object Qdown_mouse_16, Qmouse_16;
253 Lisp_Object Qdown_mouse_17, Qmouse_17;
254 Lisp_Object Qdown_mouse_18, Qmouse_18;
255 Lisp_Object Qdown_mouse_19, Qmouse_19;
256 Lisp_Object Qdown_mouse_20, Qmouse_20;
257 Lisp_Object Qdown_mouse_21, Qmouse_21;
258 Lisp_Object Qdown_mouse_22, Qmouse_22;
259 Lisp_Object Qdown_mouse_23, Qmouse_23;
260 Lisp_Object Qdown_mouse_24, Qmouse_24;
261 Lisp_Object Qdown_mouse_25, Qmouse_25;
262 Lisp_Object Qdown_mouse_26, Qmouse_26;
234 263
235 /* Kludge kludge kludge */ 264 /* Kludge kludge kludge */
236 Lisp_Object QLFD, QTAB, QRET, QESC, QDEL, QSPC, QBS; 265 Lisp_Object QLFD, QTAB, QRET, QESC, QDEL, QSPC, QBS;
237 266
238 267
280 { XD_LISP_OBJECT, offsetof (Lisp_Keymap, name) }, 309 { XD_LISP_OBJECT, offsetof (Lisp_Keymap, name) },
281 { XD_END } 310 { XD_END }
282 }; 311 };
283 312
284 /* No need for keymap_equal #### Why not? */ 313 /* No need for keymap_equal #### Why not? */
285 DEFINE_LISP_OBJECT ("keymap", keymap, 314 DEFINE_DUMPABLE_LISP_OBJECT ("keymap", keymap,
286 mark_keymap, print_keymap, 0, 0, 0, 315 mark_keymap, print_keymap, 0, 0, 0,
287 keymap_description, 316 keymap_description,
288 Lisp_Keymap); 317 Lisp_Keymap);
289 318
290 /************************************************************************/ 319 /************************************************************************/
465 Lisp_Object keysym, int modifiers) 494 Lisp_Object keysym, int modifiers)
466 { 495 {
467 Lisp_Keymap *k; 496 Lisp_Keymap *k;
468 497
469 modifiers &= ~(XEMACS_MOD_BUTTON1 | XEMACS_MOD_BUTTON2 | XEMACS_MOD_BUTTON3 498 modifiers &= ~(XEMACS_MOD_BUTTON1 | XEMACS_MOD_BUTTON2 | XEMACS_MOD_BUTTON3
470 | XEMACS_MOD_BUTTON4 | XEMACS_MOD_BUTTON5); 499 | XEMACS_MOD_BUTTON4 | XEMACS_MOD_BUTTON5 | XEMACS_MOD_BUTTON6
500 | XEMACS_MOD_BUTTON7 | XEMACS_MOD_BUTTON8 | XEMACS_MOD_BUTTON9
501 | XEMACS_MOD_BUTTON10 | XEMACS_MOD_BUTTON11 | XEMACS_MOD_BUTTON12
502 | XEMACS_MOD_BUTTON13 | XEMACS_MOD_BUTTON14 | XEMACS_MOD_BUTTON15
503 | XEMACS_MOD_BUTTON16 | XEMACS_MOD_BUTTON17 | XEMACS_MOD_BUTTON18
504 | XEMACS_MOD_BUTTON19 | XEMACS_MOD_BUTTON20 | XEMACS_MOD_BUTTON21
505 | XEMACS_MOD_BUTTON22 | XEMACS_MOD_BUTTON23 | XEMACS_MOD_BUTTON24
506 | XEMACS_MOD_BUTTON25 | XEMACS_MOD_BUTTON26);
471 if ((modifiers & ~(XEMACS_MOD_CONTROL | XEMACS_MOD_META | XEMACS_MOD_SUPER 507 if ((modifiers & ~(XEMACS_MOD_CONTROL | XEMACS_MOD_META | XEMACS_MOD_SUPER
472 | XEMACS_MOD_HYPER | XEMACS_MOD_ALT | XEMACS_MOD_SHIFT)) 508 | XEMACS_MOD_HYPER | XEMACS_MOD_ALT | XEMACS_MOD_SHIFT))
473 != 0) 509 != 0)
474 ABORT (); 510 ABORT ();
475 511
646 Lisp_Object keysym = KEY_DATA_KEYSYM (key); 682 Lisp_Object keysym = KEY_DATA_KEYSYM (key);
647 int modifiers = KEY_DATA_MODIFIERS (key); 683 int modifiers = KEY_DATA_MODIFIERS (key);
648 Lisp_Keymap *k = XKEYMAP (keymap); 684 Lisp_Keymap *k = XKEYMAP (keymap);
649 685
650 modifiers &= ~(XEMACS_MOD_BUTTON1 | XEMACS_MOD_BUTTON2 | XEMACS_MOD_BUTTON3 686 modifiers &= ~(XEMACS_MOD_BUTTON1 | XEMACS_MOD_BUTTON2 | XEMACS_MOD_BUTTON3
651 | XEMACS_MOD_BUTTON4 | XEMACS_MOD_BUTTON5); 687 | XEMACS_MOD_BUTTON4 | XEMACS_MOD_BUTTON5 | XEMACS_MOD_BUTTON6
688 | XEMACS_MOD_BUTTON7 | XEMACS_MOD_BUTTON8 | XEMACS_MOD_BUTTON9
689 | XEMACS_MOD_BUTTON10 | XEMACS_MOD_BUTTON11 | XEMACS_MOD_BUTTON12
690 | XEMACS_MOD_BUTTON13 | XEMACS_MOD_BUTTON14 | XEMACS_MOD_BUTTON15
691 | XEMACS_MOD_BUTTON16 | XEMACS_MOD_BUTTON17 | XEMACS_MOD_BUTTON18
692 | XEMACS_MOD_BUTTON19 | XEMACS_MOD_BUTTON20 | XEMACS_MOD_BUTTON21
693 | XEMACS_MOD_BUTTON22 | XEMACS_MOD_BUTTON23 | XEMACS_MOD_BUTTON24
694 | XEMACS_MOD_BUTTON25 | XEMACS_MOD_BUTTON26);
652 assert ((modifiers & ~(XEMACS_MOD_CONTROL | XEMACS_MOD_META 695 assert ((modifiers & ~(XEMACS_MOD_CONTROL | XEMACS_MOD_META
653 | XEMACS_MOD_SUPER | XEMACS_MOD_HYPER 696 | XEMACS_MOD_SUPER | XEMACS_MOD_HYPER
654 | XEMACS_MOD_ALT | XEMACS_MOD_SHIFT)) == 0); 697 | XEMACS_MOD_ALT | XEMACS_MOD_SHIFT)) == 0);
655 698
656 /* If the keysym is a one-character symbol, use the char code instead. */ 699 /* If the keysym is a one-character symbol, use the char code instead. */
1055 { 1098 {
1056 Lisp_Object event = Fmake_event (Qnil, Qnil); 1099 Lisp_Object event = Fmake_event (Qnil, Qnil);
1057 struct gcpro gcpro1; 1100 struct gcpro gcpro1;
1058 GCPRO1 (event); 1101 GCPRO1 (event);
1059 character_to_event (XCHAR (idx), XEVENT (event), 1102 character_to_event (XCHAR (idx), XEVENT (event),
1060 XCONSOLE (Vselected_console), 0, 0); 1103 XCONSOLE (Vselected_console),
1104 high_bit_is_meta, 0);
1061 indirection.keysym = XEVENT_KEY_KEYSYM (event); 1105 indirection.keysym = XEVENT_KEY_KEYSYM (event);
1062 indirection.modifiers = XEVENT_KEY_MODIFIERS (event); 1106 indirection.modifiers = XEVENT_KEY_MODIFIERS (event);
1063 UNGCPRO; 1107 UNGCPRO;
1064 } 1108 }
1065 else if (CONSP (idx)) 1109 else if (CONSP (idx))
1326 !qxestrcmp_ascii (name, "SPC") || 1370 !qxestrcmp_ascii (name, "SPC") ||
1327 !qxestrcmp_ascii (name, "BS"))) 1371 !qxestrcmp_ascii (name, "BS")))
1328 #endif /* unused */ 1372 #endif /* unused */
1329 ) 1373 )
1330 invalid_argument 1374 invalid_argument
1331 ("Invalid (FSF Emacs) key format (see doc of define-key)", 1375 ("Invalid (GNU Emacs) key format (see doc of define-key)",
1332 *keysym); 1376 *keysym);
1333 1377
1334 /* #### Ok, this is a bit more dubious - make people not lose if they 1378 /* #### Ok, this is a bit more dubious - make people not lose if they
1335 do things like (global-set-key 'RET 'something) because that would 1379 do things like (global-set-key 'RET 'something) because that would
1336 otherwise have the same problem as above. (Gag!) We silently 1380 otherwise have the same problem as above. (Gag!) We silently
1340 { 1384 {
1341 /* Likewise, the obsolete keysym binding of kp_.* should not lose. */ 1385 /* Likewise, the obsolete keysym binding of kp_.* should not lose. */
1342 DECLARE_EISTRING (temp); 1386 DECLARE_EISTRING (temp);
1343 eicpy_raw (temp, name, qxestrlen (name)); 1387 eicpy_raw (temp, name, qxestrlen (name));
1344 eisetch_char (temp, 2, '-'); 1388 eisetch_char (temp, 2, '-');
1345 *keysym = Fintern_soft (eimake_string (temp), Qnil); 1389 *keysym = Fintern_soft (eimake_string (temp), Qnil, Qnil);
1346 } 1390 }
1347 else if (EQ (*keysym, QLFD)) 1391 else if (EQ (*keysym, QLFD))
1348 *keysym = QKlinefeed; 1392 *keysym = QKlinefeed;
1349 else if (EQ (*keysym, QTAB)) 1393 else if (EQ (*keysym, QTAB))
1350 *keysym = QKtab; 1394 *keysym = QKtab;
1358 *keysym = QKspace; 1402 *keysym = QKspace;
1359 else if (EQ (*keysym, QBS)) 1403 else if (EQ (*keysym, QBS))
1360 *keysym = QKbackspace; 1404 *keysym = QKbackspace;
1361 /* Emacs compatibility */ 1405 /* Emacs compatibility */
1362 else if (EQ(*keysym, Qdown_mouse_1)) 1406 else if (EQ(*keysym, Qdown_mouse_1))
1363 *keysym = Qbutton1; 1407 *keysym = Qbutton1;
1364 else if (EQ(*keysym, Qdown_mouse_2)) 1408 else if (EQ(*keysym, Qdown_mouse_2))
1365 *keysym = Qbutton2; 1409 *keysym = Qbutton2;
1366 else if (EQ(*keysym, Qdown_mouse_3)) 1410 else if (EQ(*keysym, Qdown_mouse_3))
1367 *keysym = Qbutton3; 1411 *keysym = Qbutton3;
1368 else if (EQ(*keysym, Qdown_mouse_4)) 1412 else if (EQ(*keysym, Qdown_mouse_4))
1371 *keysym = Qbutton5; 1415 *keysym = Qbutton5;
1372 else if (EQ(*keysym, Qdown_mouse_6)) 1416 else if (EQ(*keysym, Qdown_mouse_6))
1373 *keysym = Qbutton6; 1417 *keysym = Qbutton6;
1374 else if (EQ(*keysym, Qdown_mouse_7)) 1418 else if (EQ(*keysym, Qdown_mouse_7))
1375 *keysym = Qbutton7; 1419 *keysym = Qbutton7;
1420 else if (EQ(*keysym, Qdown_mouse_8))
1421 *keysym = Qbutton8;
1422 else if (EQ(*keysym, Qdown_mouse_9))
1423 *keysym = Qbutton9;
1424 else if (EQ(*keysym, Qdown_mouse_10))
1425 *keysym = Qbutton10;
1426 else if (EQ(*keysym, Qdown_mouse_11))
1427 *keysym = Qbutton11;
1428 else if (EQ(*keysym, Qdown_mouse_12))
1429 *keysym = Qbutton12;
1430 else if (EQ(*keysym, Qdown_mouse_13))
1431 *keysym = Qbutton13;
1432 else if (EQ(*keysym, Qdown_mouse_14))
1433 *keysym = Qbutton14;
1434 else if (EQ(*keysym, Qdown_mouse_15))
1435 *keysym = Qbutton15;
1436 else if (EQ(*keysym, Qdown_mouse_16))
1437 *keysym = Qbutton16;
1438 else if (EQ(*keysym, Qdown_mouse_17))
1439 *keysym = Qbutton17;
1440 else if (EQ(*keysym, Qdown_mouse_18))
1441 *keysym = Qbutton18;
1442 else if (EQ(*keysym, Qdown_mouse_19))
1443 *keysym = Qbutton19;
1444 else if (EQ(*keysym, Qdown_mouse_20))
1445 *keysym = Qbutton20;
1446 else if (EQ(*keysym, Qdown_mouse_21))
1447 *keysym = Qbutton21;
1448 else if (EQ(*keysym, Qdown_mouse_22))
1449 *keysym = Qbutton22;
1450 else if (EQ(*keysym, Qdown_mouse_23))
1451 *keysym = Qbutton23;
1452 else if (EQ(*keysym, Qdown_mouse_24))
1453 *keysym = Qbutton24;
1454 else if (EQ(*keysym, Qdown_mouse_25))
1455 *keysym = Qbutton25;
1456 else if (EQ(*keysym, Qdown_mouse_26))
1457 *keysym = Qbutton26;
1376 else if (EQ(*keysym, Qmouse_1)) 1458 else if (EQ(*keysym, Qmouse_1))
1377 *keysym = Qbutton1up; 1459 *keysym = Qbutton1up;
1378 else if (EQ(*keysym, Qmouse_2)) 1460 else if (EQ(*keysym, Qmouse_2))
1379 *keysym = Qbutton2up; 1461 *keysym = Qbutton2up;
1380 else if (EQ(*keysym, Qmouse_3)) 1462 else if (EQ(*keysym, Qmouse_3))
1385 *keysym = Qbutton5up; 1467 *keysym = Qbutton5up;
1386 else if (EQ(*keysym, Qmouse_6)) 1468 else if (EQ(*keysym, Qmouse_6))
1387 *keysym = Qbutton6up; 1469 *keysym = Qbutton6up;
1388 else if (EQ(*keysym, Qmouse_7)) 1470 else if (EQ(*keysym, Qmouse_7))
1389 *keysym = Qbutton7up; 1471 *keysym = Qbutton7up;
1472 else if (EQ(*keysym, Qmouse_8))
1473 *keysym = Qbutton8up;
1474 else if (EQ(*keysym, Qmouse_9))
1475 *keysym = Qbutton9up;
1476 else if (EQ(*keysym, Qmouse_10))
1477 *keysym = Qbutton10up;
1478 else if (EQ(*keysym, Qmouse_11))
1479 *keysym = Qbutton11up;
1480 else if (EQ(*keysym, Qmouse_12))
1481 *keysym = Qbutton12up;
1482 else if (EQ(*keysym, Qmouse_13))
1483 *keysym = Qbutton13up;
1484 else if (EQ(*keysym, Qmouse_14))
1485 *keysym = Qbutton14up;
1486 else if (EQ(*keysym, Qmouse_15))
1487 *keysym = Qbutton15up;
1488 else if (EQ(*keysym, Qmouse_16))
1489 *keysym = Qbutton16up;
1490 else if (EQ(*keysym, Qmouse_17))
1491 *keysym = Qbutton17up;
1492 else if (EQ(*keysym, Qmouse_18))
1493 *keysym = Qbutton18up;
1494 else if (EQ(*keysym, Qmouse_19))
1495 *keysym = Qbutton19up;
1496 else if (EQ(*keysym, Qmouse_20))
1497 *keysym = Qbutton20up;
1498 else if (EQ(*keysym, Qmouse_21))
1499 *keysym = Qbutton21up;
1500 else if (EQ(*keysym, Qmouse_22))
1501 *keysym = Qbutton22up;
1502 else if (EQ(*keysym, Qmouse_23))
1503 *keysym = Qbutton23up;
1504 else if (EQ(*keysym, Qmouse_24))
1505 *keysym = Qbutton24up;
1506 else if (EQ(*keysym, Qmouse_25))
1507 *keysym = Qbutton25up;
1508 else if (EQ(*keysym, Qmouse_26))
1509 *keysym = Qbutton26up;
1390 } 1510 }
1391 } 1511 }
1392 1512
1393 1513
1394 /* Given any kind of key-specifier, return a keysym and modifier mask. 1514 /* Given any kind of key-specifier, return a keysym and modifier mask.
1405 { 1525 {
1406 Lisp_Object event = Fmake_event (Qnil, Qnil); 1526 Lisp_Object event = Fmake_event (Qnil, Qnil);
1407 struct gcpro gcpro1; 1527 struct gcpro gcpro1;
1408 GCPRO1 (event); 1528 GCPRO1 (event);
1409 character_to_event (XCHAR_OR_CHAR_INT (spec), XEVENT (event), 1529 character_to_event (XCHAR_OR_CHAR_INT (spec), XEVENT (event),
1410 XCONSOLE (Vselected_console), 0, 0); 1530 XCONSOLE (Vselected_console), high_bit_is_meta, 0);
1411 SET_KEY_DATA_KEYSYM (returned_value, XEVENT_KEY_KEYSYM (event)); 1531 SET_KEY_DATA_KEYSYM (returned_value, XEVENT_KEY_KEYSYM (event));
1412 SET_KEY_DATA_MODIFIERS (returned_value, 1532 SET_KEY_DATA_MODIFIERS (returned_value,
1413 XEVENT_KEY_MODIFIERS (event)); 1533 XEVENT_KEY_MODIFIERS (event));
1414 UNGCPRO; 1534 UNGCPRO;
1415 } 1535 }
1448 SET_KEY_DATA_KEYSYM (returned_value, (down ? Qbutton6 : Qbutton6up)); 1568 SET_KEY_DATA_KEYSYM (returned_value, (down ? Qbutton6 : Qbutton6up));
1449 break; 1569 break;
1450 case 7: 1570 case 7:
1451 SET_KEY_DATA_KEYSYM (returned_value, (down ? Qbutton7 : Qbutton7up)); 1571 SET_KEY_DATA_KEYSYM (returned_value, (down ? Qbutton7 : Qbutton7up));
1452 break; 1572 break;
1573 case 8:
1574 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton8 : Qbutton8up));
1575 break;
1576 case 9:
1577 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton9 : Qbutton9up));
1578 break;
1579 case 10:
1580 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton10 : Qbutton10up));
1581 break;
1582 case 11:
1583 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton11 : Qbutton11up));
1584 break;
1585 case 12:
1586 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton12 : Qbutton12up));
1587 break;
1588 case 13:
1589 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton13 : Qbutton13up));
1590 break;
1591 case 14:
1592 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton14 : Qbutton14up));
1593 break;
1594 case 15:
1595 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton15 : Qbutton15up));
1596 break;
1597 case 16:
1598 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton16 : Qbutton16up));
1599 break;
1600 case 17:
1601 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton17 : Qbutton17up));
1602 break;
1603 case 18:
1604 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton18 : Qbutton18up));
1605 break;
1606 case 19:
1607 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton19 : Qbutton19up));
1608 break;
1609 case 20:
1610 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton20 : Qbutton20up));
1611 break;
1612 case 21:
1613 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton21 : Qbutton21up));
1614 break;
1615 case 22:
1616 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton22 : Qbutton22up));
1617 break;
1618 case 23:
1619 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton23 : Qbutton23up));
1620 break;
1621 case 24:
1622 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton24 : Qbutton24up));
1623 break;
1624 case 25:
1625 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton25 : Qbutton25up));
1626 break;
1627 case 26:
1628 SET_KEY_DATA_KEYSYM(returned_value, (down ? Qbutton26 : Qbutton26up));
1629 break;
1453 default: 1630 default:
1454 SET_KEY_DATA_KEYSYM (returned_value, (down ? Qbutton0 : Qbutton0up)); 1631 SET_KEY_DATA_KEYSYM (returned_value, (down ? Qbutton0 : Qbutton0up));
1455 break; 1632 break;
1456 } 1633 }
1457 SET_KEY_DATA_MODIFIERS (returned_value, XEVENT_BUTTON_MODIFIERS (spec)); 1634 SET_KEY_DATA_MODIFIERS (returned_value, XEVENT_BUTTON_MODIFIERS (spec));
1547 EQ (raw_key.keysym, Qbutton2) || EQ (raw_key.keysym, Qbutton2up) || 1724 EQ (raw_key.keysym, Qbutton2) || EQ (raw_key.keysym, Qbutton2up) ||
1548 EQ (raw_key.keysym, Qbutton3) || EQ (raw_key.keysym, Qbutton3up) || 1725 EQ (raw_key.keysym, Qbutton3) || EQ (raw_key.keysym, Qbutton3up) ||
1549 EQ (raw_key.keysym, Qbutton4) || EQ (raw_key.keysym, Qbutton4up) || 1726 EQ (raw_key.keysym, Qbutton4) || EQ (raw_key.keysym, Qbutton4up) ||
1550 EQ (raw_key.keysym, Qbutton5) || EQ (raw_key.keysym, Qbutton5up) || 1727 EQ (raw_key.keysym, Qbutton5) || EQ (raw_key.keysym, Qbutton5up) ||
1551 EQ (raw_key.keysym, Qbutton6) || EQ (raw_key.keysym, Qbutton6up) || 1728 EQ (raw_key.keysym, Qbutton6) || EQ (raw_key.keysym, Qbutton6up) ||
1552 EQ (raw_key.keysym, Qbutton7) || EQ (raw_key.keysym, Qbutton7up)) 1729 EQ (raw_key.keysym, Qbutton7) || EQ (raw_key.keysym, Qbutton7up) ||
1730 EQ (raw_key.keysym, Qbutton8) || EQ (raw_key.keysym, Qbutton8up) ||
1731 EQ (raw_key.keysym, Qbutton9) || EQ (raw_key.keysym, Qbutton9up) ||
1732 EQ (raw_key.keysym, Qbutton10) || EQ (raw_key.keysym, Qbutton10up) ||
1733 EQ (raw_key.keysym, Qbutton11) || EQ (raw_key.keysym, Qbutton11up) ||
1734 EQ (raw_key.keysym, Qbutton12) || EQ (raw_key.keysym, Qbutton12up) ||
1735 EQ (raw_key.keysym, Qbutton13) || EQ (raw_key.keysym, Qbutton13up) ||
1736 EQ (raw_key.keysym, Qbutton14) || EQ (raw_key.keysym, Qbutton14up) ||
1737 EQ (raw_key.keysym, Qbutton15) || EQ (raw_key.keysym, Qbutton15up) ||
1738 EQ (raw_key.keysym, Qbutton16) || EQ (raw_key.keysym, Qbutton16up) ||
1739 EQ (raw_key.keysym, Qbutton17) || EQ (raw_key.keysym, Qbutton17up) ||
1740 EQ (raw_key.keysym, Qbutton18) || EQ (raw_key.keysym, Qbutton18up) ||
1741 EQ (raw_key.keysym, Qbutton19) || EQ (raw_key.keysym, Qbutton19up) ||
1742 EQ (raw_key.keysym, Qbutton20) || EQ (raw_key.keysym, Qbutton20up) ||
1743 EQ (raw_key.keysym, Qbutton21) || EQ (raw_key.keysym, Qbutton21up) ||
1744 EQ (raw_key.keysym, Qbutton22) || EQ (raw_key.keysym, Qbutton22up) ||
1745 EQ (raw_key.keysym, Qbutton23) || EQ (raw_key.keysym, Qbutton23up) ||
1746 EQ (raw_key.keysym, Qbutton24) || EQ (raw_key.keysym, Qbutton24up) ||
1747 EQ (raw_key.keysym, Qbutton25) || EQ (raw_key.keysym, Qbutton25up) ||
1748 EQ (raw_key.keysym, Qbutton26) || EQ (raw_key.keysym, Qbutton26up))
1553 invalid_operation ("Mouse-clicks can't appear in saved keyboard macros", 1749 invalid_operation ("Mouse-clicks can't appear in saved keyboard macros",
1554 Qunbound); 1750 Qunbound);
1555 1751
1556 XSET_EVENT_CHANNEL (event, Vselected_console); 1752 XSET_EVENT_CHANNEL (event, Vselected_console);
1557 XSET_EVENT_TYPE (event, key_press_event); 1753 XSET_EVENT_TYPE (event, key_press_event);
1775 } 1971 }
1776 1972
1777 DEFUN ("define-key", Fdefine_key, 3, 3, 0, /* 1973 DEFUN ("define-key", Fdefine_key, 3, 3, 0, /*
1778 Define key sequence KEYS, in KEYMAP, as DEF. 1974 Define key sequence KEYS, in KEYMAP, as DEF.
1779 KEYMAP is a keymap object. 1975 KEYMAP is a keymap object.
1780 KEYS is the sequence of keystrokes to bind, described below. 1976 KEYS is the key sequence to bind, described below.
1781 DEF is anything that can be a key's definition: 1977 DEF is anything that can be a key's definition:
1782 nil (means key is undefined in this keymap); 1978 nil (means key is undefined in this keymap);
1783 a command (a Lisp function suitable for interactive calling); 1979 a command (a Lisp function suitable for interactive calling);
1784 a string or key sequence vector (treated as a keyboard macro); 1980 a string or key sequence vector (treated as a keyboard macro);
1785 a keymap (to define a prefix key); 1981 a keymap (to define a prefix key);
1788 or another symbol whose function definition is used, and so on. 1984 or another symbol whose function definition is used, and so on.
1789 a cons (STRING . DEFN), meaning that DEFN is the definition 1985 a cons (STRING . DEFN), meaning that DEFN is the definition
1790 (DEFN should be a valid definition in its own right); 1986 (DEFN should be a valid definition in its own right);
1791 or a cons (KEYMAP . CHAR), meaning use definition of CHAR in map KEYMAP. 1987 or a cons (KEYMAP . CHAR), meaning use definition of CHAR in map KEYMAP.
1792 1988
1793 Contrary to popular belief, the world is not ASCII. When running under a 1989 A `key sequence' is a vector of one or more keystrokes.
1794 window system, XEmacs can tell the difference between, for example, the 1990 A `keystroke' is a list containing a key and zero or more modifiers. The
1795 keystrokes control-h, control-shift-h, and backspace. You can, in fact, 1991 key must be the last element of the list.
1796 bind different commands to each of these. 1992 A `key' is a symbol corresponding to a key on the keyboard, or to a mouse
1797 1993 gesture. Mouse clicks are denoted by symbols prefixed with "button",
1798 A `key sequence' is a set of keystrokes. A `keystroke' is a keysym and some 1994 followed by a digit for which button, and optionally "up". Thus `button1'
1799 set of modifiers (such as control and meta). A `keysym' is what is printed 1995 means the down-stroke and `button1up' means the up-stroke when clicking
1800 on the keys on your keyboard. 1996 mouse button 1.
1801 1997 A `modifier' is a symbol naming a physical key which is only "noticed" by
1802 A keysym may be represented by a symbol, or (if and only if it is equivalent 1998 XEmacs when chorded with another key. The `shift' modifier is a special
1803 to a character with a code in the range 32 - 255) by a character or its 1999 case. You cannot use `(meta shift a)' to mean `(meta A)', since for
1804 equivalent code. The `A' key may be represented by the symbol `A', the 2000 characters that have ASCII equivalents, the state of the shift key is
1805 character `?A', or by the number 65. The `break' key may be represented 2001 implicit in the keysym (a vs. A). You also cannot say `(shift =)' to mean
1806 only by the symbol `break'. 2002 `+', as that correspondence varies from keyboard to keyboard. The shift
1807 2003 modifier can only be applied to keys that do not have a second keysym on the
1808 A keystroke may be represented by a list: the last element of the list 2004 same key, such as `backspace' and `tab'. A mouse click may be combined with
1809 is the key (a symbol, character, or number, as above) and the 2005 modifiers to create a compound "keystroke".
1810 preceding elements are the symbolic names of modifier keys (control, 2006
1811 meta, super, hyper, alt, and shift). Thus, the sequence control-b is 2007 The keys, mouse gestures, and modifiers that are available depend on your
1812 represented by the forms `(control b)', `(control ?b)', and `(control 2008 console and its driver. At a minimum the ASCII graphic characters will be
1813 98)'. A keystroke may also be represented by an event object, as 2009 available as keys, and shift, control, and meta as modifiers.
1814 returned by the `next-command-event' and `read-key-sequence' 2010
1815 functions. 2011 To find out programmatically what a key is bound to, use `key-binding' to
1816 2012 check all applicable keymaps, or `lookup-key' to check a specific keymap.
1817 Note that in this context, the keystroke `control-b' is *not* represented 2013 The documentation for `key-binding' also contains a description of which
1818 by the number 2 (the ASCII code for ^B) or the character `?\^B'. See below. 2014 keymaps are applicable in various situations. `where-is-internal' does
1819 2015 the opposite of `key-binding', i.e. searches keymaps for the keys that
1820 The `shift' modifier is somewhat of a special case. You should not (and 2016 map to a particular binding.
1821 cannot) use `(meta shift a)' to mean `(meta A)', since for characters that 2017
1822 have ASCII equivalents, the state of the shift key is implicit in the 2018 If you are confused about why a particular key sequence is generating a
1823 keysym (a vs. A). You also cannot say `(shift =)' to mean `+', as that 2019 particular binding, and looking through the keymaps doesn't help, setting
1824 sort of thing varies from keyboard to keyboard. The shift modifier is for 2020 the variable `debug-emacs-events' may help. If not, try checking
1825 use only with characters that do not have a second keysym on the same key, 2021 what's in `function-key-map' and `key-translation-map'.
1826 such as `backspace' and `tab'. 2022
1827 2023 When running under a window system, typically the repertoire of keys is
1828 A key sequence is a vector of keystrokes. As a degenerate case, elements 2024 vastly expanded. XEmacs does its best to use the names defined on each
1829 of this vector may also be keysyms if they have no modifiers. That is, 2025 platform. Also, when running under a window system, XEmacs can tell the
1830 the `A' keystroke is represented by all of these forms: 2026 difference between the keystrokes control-h, control-shift-h, and backspace.
2027 If the symbols differ, you can bind different actions to each. For mouse
2028 clicks, different commands may be bound to the up and down strokes, though
2029 that is probably not what you want, so be careful.
2030
2031 Variant representations:
2032
2033 Besides the canonical representation as a vector of lists of symbols,
2034 `define-key' also accepts a number of abbreviations, aliases, and variants
2035 for convenience, compatibility, and internal use.
2036
2037 A keystroke may be represented by a key; this is treated as though it were a
2038 list containing that key as the only element. A keystroke may also be
2039 represented by an event object, as returned by the `next-command-event' and
2040 `read-key-sequence' functions. A key sequence may be represented by a
2041 single keystroke; this is treated as a vector containing that keystroke as
2042 its only element.
2043
2044 A key may be represented by a character or its equivalent integer code,
2045 if and only if it is equivalent to a character with a code in the range
2046 32 - 255.
2047
2048 For backward compatibility, a key sequence may also be represented by a
2049 string. In this case, it represents the key sequence(s) that would
2050 produce that sequence of ASCII characters in a purely ASCII world. An
2051 alternative string representation is keyboard macro notation, which can
2052 be translated to the canonical representation with `kbd'.
2053
2054 Examples:
2055
2056 The key sequence `A' (which invokes `self-insert-command') is represented
2057 by all of these forms:
1831 A ?A 65 (A) (?A) (65) 2058 A ?A 65 (A) (?A) (65)
1832 [A] [?A] [65] [(A)] [(?A)] [(65)] 2059 [A] [?A] [65] [(A)] [(?A)] [(65)]
1833 2060
1834 the `control-a' keystroke is represented by these forms: 2061 The key sequence `control-a' is represented by these forms:
1835 (control A) (control ?A) (control 65) 2062 (control A) (control ?A) (control 65)
1836 [(control A)] [(control ?A)] [(control 65)] 2063 [(control A)] [(control ?A)] [(control 65)]
1837 the key sequence `control-c control-a' is represented by these forms: 2064
2065 The key sequence `control-c control-a' is represented by these forms:
1838 [(control c) (control a)] [(control ?c) (control ?a)] 2066 [(control c) (control a)] [(control ?c) (control ?a)]
1839 [(control 99) (control 65)] etc. 2067 [(control 99) (control 65)] etc.
1840 2068
2069 The keystroke `control-b' *may not* be represented by the number 2 (the
2070 ASCII code for ^B) or the character `?\^B'.
2071
2072 The `break' key may be represented only by the symbol `break'.
2073
1841 Mouse button clicks work just like keypresses: (control button1) means 2074 Mouse button clicks work just like keypresses: (control button1) means
1842 pressing the left mouse button while holding down the control key. 2075 pressing the left mouse button while holding down the control key.
1843 \[(control c) (shift button3)] means control-c, hold shift, click right. 2076
1844 2077 A string containing the ASCII backspace character, "\\^H", would represent
1845 Commands may be bound to the mouse-button up-stroke rather than the down- 2078 two key sequences: `(control h)' and `backspace'. Binding a
1846 stroke as well. `button1' means the down-stroke, and `button1up' means the
1847 up-stroke. Different commands may be bound to the up and down strokes,
1848 though that is probably not what you want, so be careful.
1849
1850 For backward compatibility, a key sequence may also be represented by a
1851 string. In this case, it represents the key sequence(s) that would
1852 produce that sequence of ASCII characters in a purely ASCII world. For
1853 example, a string containing the ASCII backspace character, "\\^H", would
1854 represent two key sequences: `(control h)' and `backspace'. Binding a
1855 command to this will actually bind both of those key sequences. Likewise 2079 command to this will actually bind both of those key sequences. Likewise
1856 for the following pairs: 2080 for the following pairs:
1857 2081
1858 control h backspace 2082 control h backspace
1859 control i tab 2083 control i tab
1868 2092
1869 it is possible to redefine only one of those sequences like so: 2093 it is possible to redefine only one of those sequences like so:
1870 2094
1871 (define-key global-map [(control x) (control i)] \'command-2) 2095 (define-key global-map [(control x) (control i)] \'command-2)
1872 (define-key global-map [(control x) tab] \'command-3) 2096 (define-key global-map [(control x) tab] \'command-3)
1873
1874 Of course, all of this applies only when running under a window system. If
1875 you're talking to XEmacs through a TTY connection, you don't get any of
1876 these features.
1877
1878 To find out programmatically what a key is bound to, use `key-binding' to
1879 check all applicable keymaps, or `lookup-key' to check a specific keymap.
1880 The documentation for `key-binding' also contains a description of which
1881 keymaps are applicable in various situations. `where-is-internal' does
1882 the opposite of `key-binding', i.e. searches keymaps for the keys that
1883 map to a particular binding.
1884
1885 If you are confused about why a particular key sequence is generating a
1886 particular binding, and looking through the keymaps doesn't help, setting
1887 the variable `debug-emacs-events' may help. If not, try checking
1888 what's in `function-key-map' and `key-translation-map'.
1889 */ 2097 */
1890 (keymap, keys, def)) 2098 (keymap, keys, def))
1891 { 2099 {
1892 /* This function can GC */ 2100 /* This function can GC */
1893 int idx; 2101 int idx;
1920 When the user defines a key which, in a strictly ASCII world, would be 2128 When the user defines a key which, in a strictly ASCII world, would be
1921 produced by two different keys (^J and linefeed, or ^H and backspace, 2129 produced by two different keys (^J and linefeed, or ^H and backspace,
1922 for example) then the binding will be made for both keysyms. 2130 for example) then the binding will be made for both keysyms.
1923 2131
1924 This is done if the user binds a command to a string, as in 2132 This is done if the user binds a command to a string, as in
1925 (define-key map "\^H" 'something), but not when using one of the new 2133 (define-key map "\^H" 'something), but not when using the canonical
1926 syntaxes, like (define-key map '(control h) 'something). 2134 syntax (define-key map '(control h) 'something).
1927 */ 2135 */
1928 ascii_hack = (STRINGP (keys)); 2136 ascii_hack = (STRINGP (keys));
1929 2137
1930 keymap = get_keymap (keymap, 1, 1); 2138 keymap = get_keymap (keymap, 1, 1);
1931 2139
3314 if (!EVENTP (key)) 3522 if (!EVENTP (key))
3315 { 3523 {
3316 Lisp_Object event = Fmake_event (Qnil, Qnil); 3524 Lisp_Object event = Fmake_event (Qnil, Qnil);
3317 CHECK_CHAR_COERCE_INT (key); 3525 CHECK_CHAR_COERCE_INT (key);
3318 character_to_event (XCHAR (key), XEVENT (event), 3526 character_to_event (XCHAR (key), XEVENT (event),
3319 XCONSOLE (Vselected_console), 0, 1); 3527 XCONSOLE (Vselected_console),
3528 high_bit_is_meta, 1);
3320 format_event_object (buf, event, 1); 3529 format_event_object (buf, event, 1);
3321 Fdeallocate_event (event); 3530 Fdeallocate_event (event);
3322 } 3531 }
3323 else 3532 else
3324 format_event_object (buf, key, 1); 3533 format_event_object (buf, key, 1);
3457 3666
3458 DEFUN ("where-is-internal", Fwhere_is_internal, 1, 5, 0, /* 3667 DEFUN ("where-is-internal", Fwhere_is_internal, 1, 5, 0, /*
3459 Return list of keys that invoke DEFINITION in KEYMAPS. 3668 Return list of keys that invoke DEFINITION in KEYMAPS.
3460 KEYMAPS can be either a keymap (meaning search in that keymap and the 3669 KEYMAPS can be either a keymap (meaning search in that keymap and the
3461 current global keymap) or a list of keymaps (meaning search in exactly 3670 current global keymap) or a list of keymaps (meaning search in exactly
3462 those keymaps and no others). If KEYMAPS is nil, search in the currently 3671 those keymaps and no others).
3463 applicable maps for EVENT-OR-KEYS (this is equivalent to specifying
3464 `(current-keymaps EVENT-OR-KEYS)' as the argument to KEYMAPS).
3465 3672
3466 If optional 3rd arg FIRSTONLY is non-nil, return a vector representing 3673 If optional 3rd arg FIRSTONLY is non-nil, return a vector representing
3467 the first key sequence found, rather than a list of all possible key 3674 the first key sequence found, rather than a list of all possible key
3468 sequences. 3675 sequences.
3469 3676
3470 If optional 4th arg NOINDIRECT is non-nil, don't follow indirections 3677 Optional 4th argument NOINDIRECT is ignored. (GNU Emacs uses it to allow
3471 to other keymaps or slots. This makes it possible to search for an 3678 searching for an indirect keymap by inhibiting following of indirections to
3472 indirect definition itself. 3679 keymaps or slots, but XEmacs doesn't need it because keymaps are a type.)
3680
3681 If optional 5th argument EVENT-OR-KEYS is non-nil and KEYMAPS is nil,
3682 search in the currently applicable maps for EVENT-OR-KEYS (this is
3683 equivalent to specifying `(current-keymaps EVENT-OR-KEYS)' as the
3684 argument to KEYMAPS).
3473 */ 3685 */
3474 (definition, keymaps, firstonly, UNUSED (noindirect), event_or_keys)) 3686 (definition, keymaps, firstonly, UNUSED (noindirect), event_or_keys))
3475 { 3687 {
3476 /* This function can GC */ 3688 /* This function can GC */
3477 Lisp_Object maps[100]; 3689 Lisp_Object maps[100];
3734 if (! c->keys_so_far_malloced) 3946 if (! c->keys_so_far_malloced)
3735 { 3947 {
3736 Lisp_Key_Data *new_ = xnew_array (Lisp_Key_Data, size); 3948 Lisp_Key_Data *new_ = xnew_array (Lisp_Key_Data, size);
3737 memcpy ((void *)new_, (const void *)c->keys_so_far, 3949 memcpy ((void *)new_, (const void *)c->keys_so_far,
3738 c->keys_so_far_total_size * sizeof (Lisp_Key_Data)); 3950 c->keys_so_far_total_size * sizeof (Lisp_Key_Data));
3951 xfree (c->keys_so_far, Lisp_Key_Data);
3952 c->keys_so_far = new_;
3739 } 3953 }
3740 else 3954 else
3741 XREALLOC_ARRAY (c->keys_so_far, Lisp_Key_Data, size); 3955 XREALLOC_ARRAY (c->keys_so_far, Lisp_Key_Data, size);
3742 3956
3743 c->keys_so_far_total_size = size; 3957 c->keys_so_far_total_size = size;
4041 EQ (keysym, Qbutton3) || 4255 EQ (keysym, Qbutton3) ||
4042 EQ (keysym, Qbutton4) || 4256 EQ (keysym, Qbutton4) ||
4043 EQ (keysym, Qbutton5) || 4257 EQ (keysym, Qbutton5) ||
4044 EQ (keysym, Qbutton6) || 4258 EQ (keysym, Qbutton6) ||
4045 EQ (keysym, Qbutton7) || 4259 EQ (keysym, Qbutton7) ||
4260 EQ (keysym, Qbutton8) ||
4261 EQ (keysym, Qbutton9) ||
4262 EQ (keysym, Qbutton10) ||
4263 EQ (keysym, Qbutton11) ||
4264 EQ (keysym, Qbutton12) ||
4265 EQ (keysym, Qbutton13) ||
4266 EQ (keysym, Qbutton14) ||
4267 EQ (keysym, Qbutton15) ||
4268 EQ (keysym, Qbutton16) ||
4269 EQ (keysym, Qbutton17) ||
4270 EQ (keysym, Qbutton18) ||
4271 EQ (keysym, Qbutton19) ||
4272 EQ (keysym, Qbutton20) ||
4273 EQ (keysym, Qbutton21) ||
4274 EQ (keysym, Qbutton22) ||
4275 EQ (keysym, Qbutton23) ||
4276 EQ (keysym, Qbutton24) ||
4277 EQ (keysym, Qbutton25) ||
4278 EQ (keysym, Qbutton26) ||
4046 EQ (keysym, Qbutton0up) || 4279 EQ (keysym, Qbutton0up) ||
4047 EQ (keysym, Qbutton1up) || 4280 EQ (keysym, Qbutton1up) ||
4048 EQ (keysym, Qbutton2up) || 4281 EQ (keysym, Qbutton2up) ||
4049 EQ (keysym, Qbutton3up) || 4282 EQ (keysym, Qbutton3up) ||
4050 EQ (keysym, Qbutton4up) || 4283 EQ (keysym, Qbutton4up) ||
4051 EQ (keysym, Qbutton5up) || 4284 EQ (keysym, Qbutton5up) ||
4052 EQ (keysym, Qbutton6up) || 4285 EQ (keysym, Qbutton6up) ||
4053 EQ (keysym, Qbutton7up)))) 4286 EQ (keysym, Qbutton7up) ||
4287 EQ (keysym, Qbutton8up) ||
4288 EQ (keysym, Qbutton9up) ||
4289 EQ (keysym, Qbutton10up) ||
4290 EQ (keysym, Qbutton11up) ||
4291 EQ (keysym, Qbutton12up) ||
4292 EQ (keysym, Qbutton13up) ||
4293 EQ (keysym, Qbutton14up) ||
4294 EQ (keysym, Qbutton15up) ||
4295 EQ (keysym, Qbutton16up) ||
4296 EQ (keysym, Qbutton17up) ||
4297 EQ (keysym, Qbutton18up) ||
4298 EQ (keysym, Qbutton19up) ||
4299 EQ (keysym, Qbutton20up) ||
4300 EQ (keysym, Qbutton21up) ||
4301 EQ (keysym, Qbutton22up) ||
4302 EQ (keysym, Qbutton23up) ||
4303 EQ (keysym, Qbutton24up) ||
4304 EQ (keysym, Qbutton25up) ||
4305 EQ (keysym, Qbutton26up))))
4054 return; 4306 return;
4055 4307
4056 /* If this command in this map is shadowed by some other map, ignore it. */ 4308 /* If this command in this map is shadowed by some other map, ignore it. */
4057 { 4309 {
4058 Lisp_Object tail; 4310 Lisp_Object tail;
4360 DEFSYMBOL (Qbutton3); 4612 DEFSYMBOL (Qbutton3);
4361 DEFSYMBOL (Qbutton4); 4613 DEFSYMBOL (Qbutton4);
4362 DEFSYMBOL (Qbutton5); 4614 DEFSYMBOL (Qbutton5);
4363 DEFSYMBOL (Qbutton6); 4615 DEFSYMBOL (Qbutton6);
4364 DEFSYMBOL (Qbutton7); 4616 DEFSYMBOL (Qbutton7);
4617 DEFSYMBOL (Qbutton8);
4618 DEFSYMBOL (Qbutton9);
4619 DEFSYMBOL (Qbutton10);
4620 DEFSYMBOL (Qbutton11);
4621 DEFSYMBOL (Qbutton12);
4622 DEFSYMBOL (Qbutton13);
4623 DEFSYMBOL (Qbutton14);
4624 DEFSYMBOL (Qbutton15);
4625 DEFSYMBOL (Qbutton16);
4626 DEFSYMBOL (Qbutton17);
4627 DEFSYMBOL (Qbutton18);
4628 DEFSYMBOL (Qbutton19);
4629 DEFSYMBOL (Qbutton20);
4630 DEFSYMBOL (Qbutton21);
4631 DEFSYMBOL (Qbutton22);
4632 DEFSYMBOL (Qbutton23);
4633 DEFSYMBOL (Qbutton24);
4634 DEFSYMBOL (Qbutton25);
4635 DEFSYMBOL (Qbutton26);
4365 DEFSYMBOL (Qbutton0up); 4636 DEFSYMBOL (Qbutton0up);
4366 DEFSYMBOL (Qbutton1up); 4637 DEFSYMBOL (Qbutton1up);
4367 DEFSYMBOL (Qbutton2up); 4638 DEFSYMBOL (Qbutton2up);
4368 DEFSYMBOL (Qbutton3up); 4639 DEFSYMBOL (Qbutton3up);
4369 DEFSYMBOL (Qbutton4up); 4640 DEFSYMBOL (Qbutton4up);
4370 DEFSYMBOL (Qbutton5up); 4641 DEFSYMBOL (Qbutton5up);
4371 DEFSYMBOL (Qbutton6up); 4642 DEFSYMBOL (Qbutton6up);
4372 DEFSYMBOL (Qbutton7up); 4643 DEFSYMBOL (Qbutton7up);
4644 DEFSYMBOL (Qbutton8up);
4645 DEFSYMBOL (Qbutton9up);
4646 DEFSYMBOL (Qbutton10up);
4647 DEFSYMBOL (Qbutton11up);
4648 DEFSYMBOL (Qbutton12up);
4649 DEFSYMBOL (Qbutton13up);
4650 DEFSYMBOL (Qbutton14up);
4651 DEFSYMBOL (Qbutton15up);
4652 DEFSYMBOL (Qbutton16up);
4653 DEFSYMBOL (Qbutton17up);
4654 DEFSYMBOL (Qbutton18up);
4655 DEFSYMBOL (Qbutton19up);
4656 DEFSYMBOL (Qbutton20up);
4657 DEFSYMBOL (Qbutton21up);
4658 DEFSYMBOL (Qbutton22up);
4659 DEFSYMBOL (Qbutton23up);
4660 DEFSYMBOL (Qbutton24up);
4661 DEFSYMBOL (Qbutton25up);
4662 DEFSYMBOL (Qbutton26up);
4373 DEFSYMBOL (Qmouse_1); 4663 DEFSYMBOL (Qmouse_1);
4374 DEFSYMBOL (Qmouse_2); 4664 DEFSYMBOL (Qmouse_2);
4375 DEFSYMBOL (Qmouse_3); 4665 DEFSYMBOL (Qmouse_3);
4376 DEFSYMBOL (Qmouse_4); 4666 DEFSYMBOL (Qmouse_4);
4377 DEFSYMBOL (Qmouse_5); 4667 DEFSYMBOL (Qmouse_5);
4378 DEFSYMBOL (Qmouse_6); 4668 DEFSYMBOL (Qmouse_6);
4379 DEFSYMBOL (Qmouse_7); 4669 DEFSYMBOL (Qmouse_7);
4670 DEFSYMBOL (Qmouse_8);
4671 DEFSYMBOL (Qmouse_9);
4672 DEFSYMBOL (Qmouse_10);
4673 DEFSYMBOL (Qmouse_11);
4674 DEFSYMBOL (Qmouse_12);
4675 DEFSYMBOL (Qmouse_13);
4676 DEFSYMBOL (Qmouse_14);
4677 DEFSYMBOL (Qmouse_15);
4678 DEFSYMBOL (Qmouse_16);
4679 DEFSYMBOL (Qmouse_17);
4680 DEFSYMBOL (Qmouse_18);
4681 DEFSYMBOL (Qmouse_19);
4682 DEFSYMBOL (Qmouse_20);
4683 DEFSYMBOL (Qmouse_21);
4684 DEFSYMBOL (Qmouse_22);
4685 DEFSYMBOL (Qmouse_23);
4686 DEFSYMBOL (Qmouse_24);
4687 DEFSYMBOL (Qmouse_25);
4688 DEFSYMBOL (Qmouse_26);
4380 DEFSYMBOL (Qdown_mouse_1); 4689 DEFSYMBOL (Qdown_mouse_1);
4381 DEFSYMBOL (Qdown_mouse_2); 4690 DEFSYMBOL (Qdown_mouse_2);
4382 DEFSYMBOL (Qdown_mouse_3); 4691 DEFSYMBOL (Qdown_mouse_3);
4383 DEFSYMBOL (Qdown_mouse_4); 4692 DEFSYMBOL (Qdown_mouse_4);
4384 DEFSYMBOL (Qdown_mouse_5); 4693 DEFSYMBOL (Qdown_mouse_5);
4385 DEFSYMBOL (Qdown_mouse_6); 4694 DEFSYMBOL (Qdown_mouse_6);
4386 DEFSYMBOL (Qdown_mouse_7); 4695 DEFSYMBOL (Qdown_mouse_7);
4696 DEFSYMBOL (Qdown_mouse_8);
4697 DEFSYMBOL (Qdown_mouse_9);
4698 DEFSYMBOL (Qdown_mouse_10);
4699 DEFSYMBOL (Qdown_mouse_11);
4700 DEFSYMBOL (Qdown_mouse_12);
4701 DEFSYMBOL (Qdown_mouse_13);
4702 DEFSYMBOL (Qdown_mouse_14);
4703 DEFSYMBOL (Qdown_mouse_15);
4704 DEFSYMBOL (Qdown_mouse_16);
4705 DEFSYMBOL (Qdown_mouse_17);
4706 DEFSYMBOL (Qdown_mouse_18);
4707 DEFSYMBOL (Qdown_mouse_19);
4708 DEFSYMBOL (Qdown_mouse_20);
4709 DEFSYMBOL (Qdown_mouse_21);
4710 DEFSYMBOL (Qdown_mouse_22);
4711 DEFSYMBOL (Qdown_mouse_23);
4712 DEFSYMBOL (Qdown_mouse_24);
4713 DEFSYMBOL (Qdown_mouse_25);
4714 DEFSYMBOL (Qdown_mouse_26);
4387 DEFSYMBOL (Qmenu_selection); 4715 DEFSYMBOL (Qmenu_selection);
4388 DEFSYMBOL (QLFD); 4716 DEFSYMBOL (QLFD);
4389 DEFSYMBOL (QTAB); 4717 DEFSYMBOL (QTAB);
4390 DEFSYMBOL (QRET); 4718 DEFSYMBOL (QRET);
4391 DEFSYMBOL (QESC); 4719 DEFSYMBOL (QESC);