aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTom Tromey1994-05-26 05:06:14 +0000
committerTom Tromey1994-05-26 05:06:14 +0000
commitdc509e648d6f9d4486063d5b0c9b34987d50abc3 (patch)
tree403461ad130654a3242b214fa9dae70d49ca1556
parent65d5c6de9f58a1d45ced5efe3f2ac5131a699ec7 (diff)
downloademacs-dc509e648d6f9d4486063d5b0c9b34987d50abc3.tar.gz
emacs-dc509e648d6f9d4486063d5b0c9b34987d50abc3.zip
Menu items now sensitive as appropriate.
-rw-r--r--lisp/progmodes/tcl.el36
1 files changed, 26 insertions, 10 deletions
diff --git a/lisp/progmodes/tcl.el b/lisp/progmodes/tcl.el
index 98aa190a220..ea1e85ebe62 100644
--- a/lisp/progmodes/tcl.el
+++ b/lisp/progmodes/tcl.el
@@ -6,7 +6,7 @@
6;; Author: Tom Tromey <tromey@busco.lanl.gov> 6;; Author: Tom Tromey <tromey@busco.lanl.gov>
7;; Chris Lindblad <cjl@lcs.mit.edu> 7;; Chris Lindblad <cjl@lcs.mit.edu>
8;; Keywords: languages tcl modes 8;; Keywords: languages tcl modes
9;; Version: $Revision: 1.14 $ 9;; Version: $Revision: 1.15 $
10 10
11;; This file is part of GNU Emacs. 11;; This file is part of GNU Emacs.
12 12
@@ -51,7 +51,7 @@
51;; LCD Archive Entry: 51;; LCD Archive Entry:
52;; tcl|Tom Tromey|tromey@busco.lanl.gov| 52;; tcl|Tom Tromey|tromey@busco.lanl.gov|
53;; Major mode for editing Tcl| 53;; Major mode for editing Tcl|
54;; $Date: 1994/05/22 20:18:28 $|$Revision: 1.14 $|~/modes/tcl.el.Z| 54;; $Date: 1994/05/22 20:38:11 $|$Revision: 1.15 $|~/modes/tcl.el.Z|
55 55
56;; CUSTOMIZATION NOTES: 56;; CUSTOMIZATION NOTES:
57;; * tcl-proc-list can be used to customize a list of things that 57;; * tcl-proc-list can be used to customize a list of things that
@@ -65,6 +65,9 @@
65 65
66;; Change log: 66;; Change log:
67;; $Log: tcl.el,v $ 67;; $Log: tcl.el,v $
68; Revision 1.15 1994/05/22 20:38:11 tromey
69; Added bug-report keybindings and menu entries.
70;
68; Revision 1.14 1994/05/22 20:18:28 tromey 71; Revision 1.14 1994/05/22 20:18:28 tromey
69; Even more compile stuff. 72; Even more compile stuff.
70; 73;
@@ -210,6 +213,7 @@
210;; * Consider writing code to find help files automatically (for 213;; * Consider writing code to find help files automatically (for
211;; common cases). 214;; common cases).
212;; * `#' shouldn't insert `\#' when point is in string. 215;; * `#' shouldn't insert `\#' when point is in string.
216;; * '}' doesn't seem to reindent.
213 217
214 218
215 219
@@ -239,7 +243,7 @@
239 (require 'imenu)) 243 (require 'imenu))
240 ())) 244 ()))
241 245
242(defconst tcl-version "$Revision: 1.14 $") 246(defconst tcl-version "$Revision: 1.15 $")
243(defconst tcl-maintainer "Tom Tromey <tromey@busco.lanl.gov>") 247(defconst tcl-maintainer "Tom Tromey <tromey@busco.lanl.gov>")
244 248
245;; 249;;
@@ -362,17 +366,20 @@ quoted for Tcl.")
362 ["Beginning of function" tcl-beginning-of-defun t] 366 ["Beginning of function" tcl-beginning-of-defun t]
363 ["End of function" tcl-end-of-defun t] 367 ["End of function" tcl-end-of-defun t]
364 ["Mark function" tcl-mark-defun t] 368 ["Mark function" tcl-mark-defun t]
365 ["Indent region" indent-region t] 369 ["Indent region" indent-region (tcl-mark)]
366 ["Comment region" comment-region t] 370 ["Comment region" comment-region (tcl-mark)]
367 ["Uncomment region" tcl-uncomment-region t] 371 ["Uncomment region" tcl-uncomment-region (tcl-mark)]
368 "----" 372 "----"
369 ["Show Tcl process buffer" inferior-tcl t] 373 ["Show Tcl process buffer" inferior-tcl t]
370 ["Send function to Tcl process" tcl-eval-defun t] 374 ["Send function to Tcl process" tcl-eval-defun
371 ["Send region to Tcl process" tcl-eval-region t] 375 (get-buffer inferior-tcl-buffer)]
372 ["Send file to Tcl process" tcl-load-file t] 376 ["Send region to Tcl process" tcl-eval-region
377 (get-buffer inferior-tcl-buffer)]
378 ["Send file to Tcl process" tcl-load-file
379 (get-buffer inferior-tcl-buffer)]
373 ["Restart Tcl process with file" tcl-restart-with-file t] 380 ["Restart Tcl process with file" tcl-restart-with-file t]
374 "----" 381 "----"
375 ["Tcl help" tcl-help-on-word t] 382 ["Tcl help" tcl-help-on-word tcl-help-directory-list]
376 ["Send bug report" tcl-submit-bug-report t]) 383 ["Send bug report" tcl-submit-bug-report t])
377 "Lucid Emacs menu for Tcl mode.") 384 "Lucid Emacs menu for Tcl mode.")
378 385
@@ -706,6 +713,15 @@ An end of a defun is found by moving forward from the beginning of one."
706 'mark-defun 713 'mark-defun
707 'tcl-internal-mark-defun)) 714 'tcl-internal-mark-defun))
708 715
716;; In GNU Emacs 19, mark takes an additional "force" argument. I
717;; don't know about Lucid Emacs, so I'm just assuming it is the same.
718;; Emacs 18 doesn't have this argument.
719(defun tcl-mark ()
720 "Return mark, or nil if none."
721 (if tcl-using-emacs-19
722 (mark t)
723 (mark)))
724
709 725
710 726
711;; 727;;