 (defun cscope-find-called-functions (symbol)
   "Display functions called by a function."
   (interactive (list
-		(cscope-prompt-for-symbol "Find functions called by this function: "
-					  nil)
+		(cscope-prompt-for-symbol
+		 "Find functions called by this function: " nil)
 		))
   (let ()
     (cscope-call (format "Finding functions called by: %s" symbol)

		      :style toggle :selected cscope-no-mouse-prompts ]
		    ))


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(defun cscope-show-message (file line-number &optional desired-window)
  "Display FILE in some window, and move to LINE-NUMBER."
  (let (buffer window)
    (setq buffer (find-file-noselect file))
    (setq window (if desired-window
		     (progn
		       (set-window-buffer desired-window buffer)
		       desired-window
		       )
		   (display-buffer buffer)))
    (set-buffer buffer)
    (if (> line-number 0)
	(progn
	  (goto-line line-number)
	  (set-window-point window (point))
	  ))
    (select-window window)
    ))


(defun cscope-show-message-key ()
  "Display the file/line number under the text cursor."
  (interactive)
  (let* ( (extent (extent-at (point) (current-buffer) 'cscope))
	  (file (extent-property extent 'cscope-file))
	  (line-number (extent-property extent 'cscope-line-number))
	 )
    (cscope-show-message file line-number)
    ))


(defun cscope-show-message-event (event)
  "Display the file/line number highlighted by the mouse."
  (interactive "e")
  (let* ( (ep (event-point event))
	  (buffer (window-buffer (event-window event)))
	  (extent (extent-at ep buffer 'cscope))
	  (file (extent-property extent 'cscope-file))
	  (line-number (extent-property extent 'cscope-line-number))
	  )
    (set-buffer buffer)		;; needed for the current directory
    (select-window (event-window event))
    (cscope-show-message file line-number)
    ))


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(defun cscope-canonicalize-directory (dir)
  (progn
    (if (not dir)
	(setq dir default-directory))
    (setq dir (file-name-as-directory
	       (expand-file-name (substitute-in-file-name dir))))
    dir
    ))


(defun cscope-search-directory-hierarchy (directory)

;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; This is a cscope interface for (X)Emacs.
;; It currently runs under Unix only.
;;
;; Using cscope, you can easily search for where symbols are used and defined.
