Mercurial > emacs
comparison lisp/bs.el @ 88123:375f2633d815
New directory
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Mon, 08 Sep 2003 11:56:09 +0000 |
parents | 695cf19ef79e |
children | 68c22ea6027c |
comparison
equal
deleted
inserted
replaced
52428:27bc8b966642 | 88123:375f2633d815 |
---|---|
455 Used internally, only.") | 455 Used internally, only.") |
456 | 456 |
457 (defvar bs--marked-buffers nil | 457 (defvar bs--marked-buffers nil |
458 "Currently marked buffers in Buffer Selection Menu.") | 458 "Currently marked buffers in Buffer Selection Menu.") |
459 | 459 |
460 (defvar bs-mode-map | 460 (defvar bs-mode-map () |
461 (let ((map (make-sparse-keymap))) | |
462 (define-key map " " 'bs-select) | |
463 (define-key map "f" 'bs-select) | |
464 (define-key map "v" 'bs-view) | |
465 (define-key map "!" 'bs-select-in-one-window) | |
466 (define-key map [mouse-2] 'bs-mouse-select) ;; for GNU EMACS | |
467 (define-key map [button2] 'bs-mouse-select) ;; for XEmacs | |
468 (define-key map "F" 'bs-select-other-frame) | |
469 (let ((key ?1)) | |
470 (while (<= key ?9) | |
471 (define-key map (char-to-string key) 'digit-argument) | |
472 (setq key (1+ key)))) | |
473 (define-key map "-" 'negative-argument) | |
474 (define-key map "\e-" 'negative-argument) | |
475 (define-key map "o" 'bs-select-other-window) | |
476 (define-key map "\C-o" 'bs-tmp-select-other-window) | |
477 ;; for GNU EMACS | |
478 (define-key map [mouse-3] 'bs-mouse-select-other-frame) | |
479 ;; for XEmacs | |
480 (define-key map [button3] 'bs-mouse-select-other-frame) | |
481 (define-key map [up] 'bs-up) | |
482 (define-key map "n" 'bs-down) | |
483 (define-key map "p" 'bs-up) | |
484 (define-key map [down] 'bs-down) | |
485 (define-key map "\C-m" 'bs-select) | |
486 (define-key map "b" 'bs-bury-buffer) | |
487 (define-key map "s" 'bs-save) | |
488 (define-key map "S" 'bs-show-sorted) | |
489 (define-key map "a" 'bs-toggle-show-all) | |
490 (define-key map "d" 'bs-delete) | |
491 (define-key map "\C-d" 'bs-delete-backward) | |
492 (define-key map "k" 'bs-delete) | |
493 (define-key map "g" 'bs-refresh) | |
494 (define-key map "C" 'bs-set-configuration-and-refresh) | |
495 (define-key map "c" 'bs-select-next-configuration) | |
496 (define-key map "q" 'bs-kill) | |
497 ;; (define-key map "z" 'bs-kill) | |
498 (define-key map "\C-c\C-c" 'bs-kill) | |
499 (define-key map "\C-g" 'bs-abort) | |
500 (define-key map "\C-]" 'bs-abort) | |
501 (define-key map "%" 'bs-toggle-readonly) | |
502 (define-key map "~" 'bs-clear-modified) | |
503 (define-key map "M" 'bs-toggle-current-to-show) | |
504 (define-key map "+" 'bs-set-current-buffer-to-show-always) | |
505 ;;(define-key map "-" 'bs-set-current-buffer-to-show-never) | |
506 (define-key map "t" 'bs-visit-tags-table) | |
507 (define-key map "m" 'bs-mark-current) | |
508 (define-key map "u" 'bs-unmark-current) | |
509 (define-key map ">" 'scroll-right) | |
510 (define-key map "<" 'scroll-left) | |
511 (define-key map "?" 'bs-help) | |
512 map) | |
513 "Keymap of `bs-mode'.") | 461 "Keymap of `bs-mode'.") |
462 | |
463 (if bs-mode-map | |
464 () | |
465 (setq bs-mode-map (make-sparse-keymap)) | |
466 (define-key bs-mode-map " " 'bs-select) | |
467 (define-key bs-mode-map "f" 'bs-select) | |
468 (define-key bs-mode-map "v" 'bs-view) | |
469 (define-key bs-mode-map "!" 'bs-select-in-one-window) | |
470 (define-key bs-mode-map [mouse-2] 'bs-mouse-select) ;; for GNU EMACS | |
471 (define-key bs-mode-map [button2] 'bs-mouse-select) ;; for XEmacs | |
472 (define-key bs-mode-map "F" 'bs-select-other-frame) | |
473 | |
474 (let ((key ?1)) | |
475 (while (<= key ?9) | |
476 (define-key bs-mode-map (char-to-string key) 'digit-argument) | |
477 (setq key (1+ key)))) | |
478 | |
479 (define-key bs-mode-map "-" 'negative-argument) | |
480 (define-key bs-mode-map "\e-" 'negative-argument) | |
481 | |
482 (define-key bs-mode-map "o" 'bs-select-other-window) | |
483 (define-key bs-mode-map "\C-o" 'bs-tmp-select-other-window) | |
484 ;; for GNU EMACS | |
485 (define-key bs-mode-map [mouse-3] 'bs-mouse-select-other-frame) | |
486 ;; for XEmacs | |
487 (define-key bs-mode-map [button3] 'bs-mouse-select-other-frame) | |
488 (define-key bs-mode-map [up] 'bs-up) | |
489 (define-key bs-mode-map "n" 'bs-down) | |
490 (define-key bs-mode-map "p" 'bs-up) | |
491 (define-key bs-mode-map [down] 'bs-down) | |
492 (define-key bs-mode-map "\C-m" 'bs-select) | |
493 (define-key bs-mode-map "b" 'bs-bury-buffer) | |
494 (define-key bs-mode-map "s" 'bs-save) | |
495 (define-key bs-mode-map "S" 'bs-show-sorted) | |
496 (define-key bs-mode-map "a" 'bs-toggle-show-all) | |
497 (define-key bs-mode-map "d" 'bs-delete) | |
498 (define-key bs-mode-map "\C-d" 'bs-delete-backward) | |
499 (define-key bs-mode-map "k" 'bs-delete) | |
500 (define-key bs-mode-map "g" 'bs-refresh) | |
501 (define-key bs-mode-map "C" 'bs-set-configuration-and-refresh) | |
502 (define-key bs-mode-map "c" 'bs-select-next-configuration) | |
503 (define-key bs-mode-map "q" 'bs-kill) | |
504 ;; (define-key bs-mode-map "z" 'bs-kill) | |
505 (define-key bs-mode-map "\C-c\C-c" 'bs-kill) | |
506 (define-key bs-mode-map "\C-g" 'bs-abort) | |
507 (define-key bs-mode-map "\C-]" 'bs-abort) | |
508 (define-key bs-mode-map "%" 'bs-toggle-readonly) | |
509 (define-key bs-mode-map "~" 'bs-clear-modified) | |
510 (define-key bs-mode-map "M" 'bs-toggle-current-to-show) | |
511 (define-key bs-mode-map "+" 'bs-set-current-buffer-to-show-always) | |
512 ;;(define-key bs-mode-map "-" 'bs-set-current-buffer-to-show-never) | |
513 (define-key bs-mode-map "t" 'bs-visit-tags-table) | |
514 (define-key bs-mode-map "m" 'bs-mark-current) | |
515 (define-key bs-mode-map "u" 'bs-unmark-current) | |
516 (define-key bs-mode-map ">" 'scroll-right) | |
517 (define-key bs-mode-map "<" 'scroll-left) | |
518 (define-key bs-mode-map "\e\e" nil) | |
519 (define-key bs-mode-map "\e\e\e" 'bs-kill) | |
520 (define-key bs-mode-map [escape escape escape] 'bs-kill) | |
521 (define-key bs-mode-map "?" 'bs-help)) | |
514 | 522 |
515 ;; ---------------------------------------------------------------------- | 523 ;; ---------------------------------------------------------------------- |
516 ;; Functions | 524 ;; Functions |
517 ;; ---------------------------------------------------------------------- | 525 ;; ---------------------------------------------------------------------- |
518 | 526 |
1505 (bs--show-with-configuration (bs--configuration-name-for-prefix-arg arg))) | 1513 (bs--show-with-configuration (bs--configuration-name-for-prefix-arg arg))) |
1506 | 1514 |
1507 ;; Now provide feature bs | 1515 ;; Now provide feature bs |
1508 (provide 'bs) | 1516 (provide 'bs) |
1509 | 1517 |
1510 ;;; arch-tag: c0d9ab34-bf06-4368-ae9d-af88878e6802 | |
1511 ;;; bs.el ends here | 1518 ;;; bs.el ends here |