Update of /project/clim-desktop/cvsroot/clim-desktop In directory clnet:/tmp/cvs-serv30644
Modified Files: swine-cmds.lisp Log Message: Added feeble docstrings.
--- /project/clim-desktop/cvsroot/clim-desktop/swine-cmds.lisp 2006/05/02 18:07:16 1.9 +++ /project/clim-desktop/cvsroot/clim-desktop/swine-cmds.lisp 2006/05/15 14:18:57 1.10 @@ -25,7 +25,9 @@
(in-package :climacs-lisp-syntax)
-(define-command (com-eval-last-expression :name t :command-table lisp-table) () +(define-command (com-eval-last-expression :name t :command-table lisp-table) + () + "Evaluate the expression before point." (eval-last-expression-with-swank (point (current-window)) (syntax (buffer (current-window)))))
@@ -33,7 +35,12 @@ 'lisp-table '((#\c :control) (#\e :control)))
-(define-command (com-macroexpand-1 :name t :command-table lisp-table) () +(define-command (com-macroexpand-1 :name t :command-table lisp-table) + () + "Macroexpand-1 the expression at point. + +The expanded expression will be displayed in a +"*Macroexpansion*"-buffer." (macroexpand-with-swank (point (current-window)) (syntax (buffer (current-window)))))
@@ -45,15 +52,18 @@ 'lisp-table '((#\c :control) (#\m :control)))
-(define-command (com-macroexpand-all :name t :command-table lisp-table) () - (macroexpand-with-swank (point (current-window)) - (syntax (buffer (current-window))))) +(define-command (com-macroexpand-all :name t :command-table lisp-table) + () + "Completely macroexpand the expression at point.
-(esa:set-key 'com-macroexpand-all - 'lisp-table - '((#\c :control) (#\m :meta))) +The expanded expression will be displayed in a +"*Macroexpansion*"-buffer." + (macroexpand-with-swank (point (current-window)) + (syntax (buffer (current-window))) t))
-(define-command (com-eval-region :name t :command-table lisp-table) () +(define-command (com-eval-region :name t :command-table lisp-table) + () + "Evaluate the current region." (eval-region-with-swank (point (current-window)) (mark (current-window)) (syntax (buffer (current-window))))) @@ -62,30 +72,46 @@ 'lisp-table '((#\c :control) (#\r :control)))
-(define-command (com-compile-definition :name t :command-table lisp-table) () - (compile-defun-with-swank (point (current-window)) - (current-window) - (syntax (buffer (current-window))))) +(define-command (com-compile-definition :name t :command-table lisp-table) + () + "Compile and load definition at point." + (compile-defun-with-swank (point (current-window)) + (current-window) + (syntax (buffer (current-window)))))
(esa:set-key 'com-compile-definition 'lisp-table '((#\c :control) (#\c :control)))
-(define-command (com-compile-and-load-file :name t :command-table lisp-table) () +(define-command (com-compile-and-load-file :name t :command-table lisp-table) + () + "Compile and load the current file. + +Compiler notes will be displayed in a seperate buffer." (compile-file-with-swank (buffer (current-window)) t))
(esa:set-key 'com-compile-and-load-file 'lisp-table '((#\c :control) (#\k :control)))
-(define-command (com-compile-file :name t :command-table lisp-table) () - (compile-file-with-swank (buffer (current-window)) nil)) +(define-command (com-compile-file :name t :command-table lisp-table) + () + "Compile the file open in the current buffer. + +This command does not load the file after it has been compiled." + (compile-file-with-swank (buffer (current-window)) nil))
(esa:set-key 'com-compile-file 'lisp-table '((#\c :control) (#\k :meta)))
-(define-command (com-goto-location :name t :command-table lisp-table) ((note 'swine-compiler-note)) +(define-command (com-goto-location :name t :command-table lisp-table) + ((note 'swine-compiler-note)) + "Move point to the part of a given file that caused the +compiler note. + +If the file is not already open, a new buffer will be opened with +that file." (goto-swine-location (location note)))
(define-presentation-to-command-translator swine-compiler-note-to-goto-location-translator @@ -93,8 +119,10 @@ (presentation) (list (presentation-object presentation)))
-(define-command (com-goto-xref :name t :command-table lisp-table) ((xref 'swine-xref)) - (goto-swine-location xref)) +(define-command (com-goto-xref :name t :command-table lisp-table) + ((xref 'swine-xref)) + "Go to the referenced location of a code cross-reference." + (goto-swine-location xref))
(define-presentation-to-command-translator swine-xref-to-goto-location-translator (swine-xref com-goto-xref lisp-table) @@ -108,6 +136,12 @@ ;; symbol at the current point in the buffer. (define-command (com-edit-definition :name t :command-table lisp-table) ((symbol 'symbol :prompt "Edit symbol")) + "Edit the definition of a symbol. + +If the symbol has been defined more than once (eg. to a function +as well as a class, or as numerous methods), a +mouse-click-sensitive list of available definitions will be +displayed." (flet ((fully-qualified-symbol-name (symbol) (let ((*package* (find-package :keyword))) (format nil "~S" symbol)))) @@ -124,14 +158,19 @@ 'lisp-table '((#. :meta)))
-(define-command (com-return-from-definition :name t :command-table lisp-table) () +(define-command (com-return-from-definition :name t :command-table lisp-table) + () + "Return point to where it was before the previous Edit +Definition command was issued." (pop-find-definition-stack))
(esa:set-key 'com-return-from-definition 'lisp-table '((#, :meta)))
-(define-command (com-hyperspec-lookup :name t :command-table lisp-table) () +(define-command (com-hyperspec-lookup :name t :command-table lisp-table) + () + "Look up a symbol in the Common Lisp HyperSpec." (let* ((name (or (symbol-name-at-mark (point (current-window)) (syntax (buffer (current-window)))) (accept 'string :prompt "Hyperspec lookup for symbol"))) @@ -163,8 +202,9 @@ 'lisp-table '((#\c :control) (#\d :control) (#\a)))
-(define-command (com-swine-space :name t :command-table lisp-table) +(define-command (com-swine-space :command-table lisp-table) () + "Insert a space and display argument hints in the minibuffer." (let* ((window (current-window)) (mark (point window)) (syntax (syntax (buffer window)))) @@ -190,7 +230,12 @@ 'lisp-table '((#\Space)))
-(define-command (com-swine-simple-completion :name t :command-table lisp-table) () +(define-command (com-swine-simple-completion :name t :command-table lisp-table) + () + "Attempt a simple symbol-completion for the symbol at mark. + +If more than one completion is available, a list of possible +completions will be displayed." (let* ((point-current-window (point (current-window))) (name (symbol-name-at-mark point-current-window (syntax (buffer (current-window)))))) @@ -203,6 +248,10 @@ (insert-sequence point-current-window difference)))))
(define-command (com-swine-completion :name t :command-table lisp-table) () + "Attempt to complete the symbol at mark. + +If more than one completion is available, a list of possible +completions will be displayed." (let* ((point-current-window (point (current-window))) (name (symbol-name-at-mark point-current-window (syntax (buffer (current-window)))))) @@ -215,6 +264,11 @@ (insert-sequence point-current-window completion))))))
(define-command (com-swine-fuzzy-completion :name t :command-table lisp-table) () + "Attempt to fuzzily complete the abbreviation at mark. + +Fuzzy completion tries to guess which symbol is abbreviated. If +the abbreviation is ambiguous, a list of possible completions +will be displayed." (let* ((point-current-window (point (current-window))) (name (symbol-name-at-mark point-current-window (syntax (buffer (current-window))))))
clim-desktop-cvs@common-lisp.net