]> code.delx.au - gnu-emacs/blobdiff - lisp/array.el
(font-lock-keywords): Fix spelling in docstrings.
[gnu-emacs] / lisp / array.el
index 404629689513f7bbd5b45f5f7e6b2c9252430b77..2f270d0f0860a94ce2cd4efd89414c5ba9b9bc3c 100644 (file)
@@ -607,7 +607,7 @@ If optional ARG is given, copy through ARG rows up."
   (let ((check t)
        (len))
     (while check
-      (setq array-init-field (read-input "Initial field value: "))
+      (setq array-init-field (read-string "Initial field value: "))
       (setq len (length array-init-field))
       (if (/= len array-field-width)
          (if (y-or-n-p (format "Change field width to %d? " len))
@@ -647,8 +647,8 @@ of array-rows-numbered."
               (<= new-columns-per-line array-max-column))
          (setq check nil)
        (setq new-columns-per-line
-             (string-to-int
-              (read-input
+             (string-to-number
+              (read-string
                (format "Columns per line (1 - %d): " array-max-column)))))))
   ;; Check on new-rows-numbered.  It has to be done this way
   ;;  because interactive does not have y-or-n-p.
@@ -872,6 +872,7 @@ take a numeric prefix argument):
 Entering array mode calls the function `array-mode-hook'."
 
   (interactive)
+  (kill-all-local-variables)
   ;; Number of rows in the array.
   (make-local-variable 'array-max-row)
   ;; Number of columns in the array.
@@ -907,7 +908,7 @@ Entering array mode calls the function `array-mode-hook'."
   (setq truncate-lines t)
   (setq overwrite-mode 'overwrite-mode-textual)
   (use-local-map array-mode-map)
-  (run-hooks 'array-mode-hook))
+  (run-mode-hooks 'array-mode-hook))
 
 \f
 
@@ -927,22 +928,22 @@ Entering array mode calls the function `array-mode-hook'."
 (defun array-init-max-row (&optional arg)
   "Initialize the value of `array-max-row'."
   (setq array-max-row
-       (or arg (string-to-int (read-input "Number of array rows: ")))))
+       (or arg (string-to-number (read-string "Number of array rows: ")))))
 
 (defun array-init-max-column (&optional arg)
   "Initialize the value of `array-max-column'."
   (setq array-max-column
-       (or arg (string-to-int (read-input "Number of array columns: ")))))
+       (or arg (string-to-number (read-string "Number of array columns: ")))))
 
 (defun array-init-columns-per-line (&optional arg)
   "Initialize the value of `array-columns-per-line'."
   (setq array-columns-per-line
-       (or arg (string-to-int (read-input "Array columns per line: ")))))
+       (or arg (string-to-number (read-string "Array columns per line: ")))))
 
 (defun array-init-field-width (&optional arg)
   "Initialize the value of `array-field-width'."
   (setq array-field-width
-       (or arg (string-to-int (read-input "Field width: ")))))
+       (or arg (string-to-number (read-string "Field width: ")))))
 
 (defun array-init-rows-numbered (&optional arg)
   "Initialize the value of `array-rows-numbered'."
@@ -964,4 +965,5 @@ Entering array mode calls the function `array-mode-hook'."
 
 (provide 'array)
 
+;;; arch-tag: 0086605d-79fe-4a1a-992a-456417261f80
 ;;; array.el ends here