 (defconst yacas-menu-process
   (list
    "Process"
-   ["Start a Yacas process"   yacas-start-process 
-                                  (not (processp yacas-process))]
+   ["Start a Yacas process"   yacas-start
+                                  (not (processp inferior-yacas-process))]
    ["Run Yacas on buffer"   yacas-buffer]
    ["Run Yacas on region"  yacas-region ]
    ["Run Yacas on line"  yacas-line]
-   ["Recenter the output buffer"  yacas-recenter-output-buffer]
+   ["Display the output buffer"  yacas-display-buffer]
    ["Toggle PrettyForm" yacas-toggle-prettyform ]
    ["Reset the Yacas process" yacas-reset]
    ["Send string to Yacas" yacas-eval-string]
-   ["Kill Yacas process"  yacas-kill-job  (processp yacas-process)])
+   ["Kill Yacas process"  yacas-stop  (processp inferior-yacas-process)])
   "Yacas process commands")
 
 (defconst yacas-menu-formatting

(defconst yacas-menu-help
  (list
   "Help"
   ["Yacas help" yacas-help yacas-have-w3]
   ["Yacas mode help" yacas-info-help]))

(defconst yacas-menu-yacas


(require 'font-lock)
(require 'yacas-names)
(require 'yacas-functions)
(require 'comint)
(provide 'yacas)


;; First of all, some values that the user might wish to change

(defgroup yacas nil
  "Yacas mode"
  :prefix "yacas-"
  :tag "Yacas")

(defcustom yacas-documentation-directory
  "/usr/share/yacas/documentation/"
  "Path where the yacas documentation is kept."
  :group 'yacas
  :type 'directory)

(defcustom yacas-command "yacas"
  "The command to run Yacas on a file."
  :group 'yacas
  :type 'string)

(defcustom yacas-args "-p"
  "Arguments passed to yacas-command."
  :group 'yacas
  :type 'string)

(defcustom yacas-indent 3 
  "*The indentation in yacas-mode"
  :group 'yacas
  :type 'integer)

;(defcustom yacas-prompt-regexp "^\\(In> \\|Out> \\)"
;  "A regular expression for the Yacas prompt."
;  :group 'yacas
;  :type 'string)

(defcustom yacas-input-prompt-string "In> "
  "A string for the standard Yacas prompt."
  :group 'yacas
  :type 'string)

;(defcustom yacas-output-prompt-string "Out> "
;  "A string for the standard Yacas prompt."
;  :group 'yacas
;  :type 'string)

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

(defvar yacas-running-xemacs (string-match "XEmacs\\|Lucid" emacs-version))

(defvar inferior-yacas-process nil)

(defvar yacas-input-end nil
  "The position of the last part of the last input.")

(setq yacas-prettyform nil)

