36 |
;;; Internal defines |
;;; Internal defines |
37 |
;;; |
;;; |
38 |
|
|
39 |
(defmap sml-bindings |
(defmap sml-mode-map |
40 |
;; smarter cursor movement |
;; smarter cursor movement |
41 |
'((forward-sexp . sml-user-forward-sexp) |
'((forward-sexp . sml-user-forward-sexp) |
42 |
(backward-sexp . sml-user-backward-sexp) |
(backward-sexp . sml-user-backward-sexp) |
44 |
("\C-c\C-m" . sml-insert-form) |
("\C-c\C-m" . sml-insert-form) |
45 |
("\C-c\C-i" . sml-mode-info) |
("\C-c\C-i" . sml-mode-info) |
46 |
("\M-|" . sml-electric-pipe) |
("\M-|" . sml-electric-pipe) |
47 |
("\M-\ " . sml-electric-pipe) |
("\M-\ " . sml-electric-space) |
48 |
("\;" . sml-electric-semi) |
("\;" . sml-electric-semi) |
49 |
("\M-\t" . sml-back-to-outer-indent) |
("\M-\t" . sml-back-to-outer-indent) |
|
;;("\C-\M-\\" . sml-indent-region) |
|
|
;;("\t" . sml-indent-line) ; ...except this one |
|
50 |
;; Process commands added to sml-mode-map -- these should autoload |
;; Process commands added to sml-mode-map -- these should autoload |
51 |
("\C-c\C-l" . sml-load-file) |
("\C-c\C-l" . sml-load-file) |
52 |
;;("\C-c`" . sml-next-error) |
("\C-c\C-c" . sml-compile) |
|
) |
|
|
"Generic bindings used in `sml-mode' and `inferior-sml-mode'." |
|
|
:group 'sml) |
|
|
|
|
|
(defmap sml-mode-map |
|
|
'(("\C-c\C-c" . sml-compile) |
|
53 |
("\C-c\C-s" . switch-to-sml) |
("\C-c\C-s" . switch-to-sml) |
54 |
("\C-c\C-r" . sml-send-region) |
("\C-c\C-r" . sml-send-region) |
55 |
("\C-c\C-b" . sml-send-buffer) |
("\C-c\C-b" . sml-send-buffer) |
56 |
([(meta shift down-mouse-1)] . sml-drag-region)) |
([(meta shift down-mouse-1)] . sml-drag-region)) |
57 |
"The keymap used in `sml-mode'." |
"The keymap used in `sml-mode'." |
58 |
:inherit sml-bindings |
;; :inherit sml-bindings |
59 |
:group 'sml) |
:group 'sml) |
60 |
|
|
61 |
(defsyntax sml-mode-syntax-table |
(defsyntax sml-mode-syntax-table |
67 |
;; `!' is not really a prefix-char, oh well! |
;; `!' is not really a prefix-char, oh well! |
68 |
("~#!" . "'") |
("~#!" . "'") |
69 |
("%&$+-/:<=>?@`^|" . ".")) |
("%&$+-/:<=>?@`^|" . ".")) |
70 |
"The syntax table used in sml-mode.") |
"The syntax table used in `sml-mode'.") |
|
|
|
71 |
|
|
72 |
|
|
73 |
(easy-menu-define sml-mode-menu sml-mode-map "Menu used in sml-mode." |
(easy-menu-define sml-mode-menu sml-mode-map "Menu used in sml-mode." |
85 |
;;["goto next error" sml-next-error (featurep 'sml-proc)] |
;;["goto next error" sml-next-error (featurep 'sml-proc)] |
86 |
["goto next error" next-error (featurep 'sml-proc)] |
["goto next error" next-error (featurep 'sml-proc)] |
87 |
["---" nil nil] |
["---" nil nil] |
88 |
["Standard ML of New Jersey" sml-smlnj (fboundp 'sml-smlnj)] |
;; ["Standard ML of New Jersey" sml-smlnj (fboundp 'sml-smlnj)] |
89 |
["Poly/ML" sml-poly-ml (fboundp 'sml-poly-ml)] |
;; ["Poly/ML" sml-poly-ml (fboundp 'sml-poly-ml)] |
90 |
["Moscow ML" sml-mosml (fboundp 'sml-mosml)] |
;; ["Moscow ML" sml-mosml (fboundp 'sml-mosml)] |
91 |
["Help for Inferior ML" (describe-function 'inferior-sml-mode) :active (featurep 'sml-proc)]) |
["Help for Inferior ML" (describe-function 'inferior-sml-mode) :active (featurep 'sml-proc)]) |
92 |
["electric pipe" sml-electric-pipe t] |
["electric pipe" sml-electric-pipe t] |
93 |
["insert SML form" sml-insert-form t] |
["insert SML form" sml-insert-form t] |