-;; Mim (MDL in MDL) mode.
+;;; mim-mode.el --- Mim (MDL in MDL) mode.
+
;; Copyright (C) 1985 Free Software Foundation, Inc.
-;; Principal author K. Shane Hartman
+
+;; Author: K. Shane Hartman
+;; Maintainer: FSF
+;; Keywords: languages
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 1, or (at your option)
+;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
;; GNU Emacs is distributed in the hope that it will be useful,
;; along with GNU Emacs; see the file COPYING. If not, write to
;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;;; Code:
(autoload 'fast-syntax-check-mim "mim-syntax"
"Checks Mim syntax quickly.
<FOO ...> will be indented n spaces from start of form.
\(put 'FOO 'indent-mim-function 'DEFINE\) is like above but means use
value of mim-body-indent as offset from start of form.
-\(put 'FOO 'indent-mim-function <cons>\) where <cons> is a list or pointted list
+\(put 'FOO 'indent-mim-function <cons>\) where <cons> is a list or pointed list
of integers, means indent each form in <FOO ...> by the amount specified
in <cons>. When <cons> is exhausted, indent remaining forms by
`mim-body-indent' unless <cons> is a pointed list, in which case the last
non-whitespace character in column 0 to be a toplevel object, otherwise
only open paren syntax characters will be considered.")
-(fset 'mdl-mode 'mim-mode)
+(defalias 'mdl-mode 'mim-mode)
(defun mim-mode ()
"Major mode for editing Mim (MDL in MDL) code.
(use-local-map mim-mode-map)
(set-syntax-table mim-mode-syntax-table)
(make-local-variable 'paragraph-start)
- (setq paragraph-start (concat "^$\\|" page-delimiter))
+ (setq paragraph-start (concat "$\\|" page-delimiter))
(make-local-variable 'paragraph-separate)
(setq paragraph-separate paragraph-start)
(make-local-variable 'paragraph-ignore-fill-prefix)
(setq comment-end "\"")
(make-local-variable 'comment-column)
(setq comment-column 40)
- (make-local-variable 'comment-indent-hook)
- (setq comment-indent-hook 'indent-mim-comment)
+ (make-local-variable 'comment-indent-function)
+ (setq comment-indent-function 'indent-mim-comment)
;; tell generic indenter how to indent.
(make-local-variable 'indent-line-function)
(setq indent-line-function 'indent-mim-line)
"Move forward across Mim object.
With ARG, move forward that many objects."
(interactive "p")
- ;; this function is wierd because it emulates the behavior of the old
+ ;; this function is weird because it emulates the behavior of the old
;; (gosling) mim-mode - if the arg is 1 and we are `inside' an ADECL,
;; more than one character into the ATOM part and not sitting on the
;; colon, then we move to the DECL part (just past colon) instead of
"Move down a level of Mim structure forwards.
With ARG, move down that many levels forwards (backwards, ARG < 0)."
(interactive "p")
- ;; another wierdo - going down `inside' an ADECL or ATOM trailer
+ ;; another weirdo - going down `inside' an ADECL or ATOM trailer
;; depends on the value of mim-down-parens-only. if nil, treat
;; ADECLs and trailers as structured objects.
(let ((direction (sign (or arg (setq arg 1)))))
(+ method start))
(goto-char current-indent)
(if (consp method)
- ;; list or pointted list of explicit indentations
+ ;; list or pointed list of explicit indentations
(indent-mim-offset state indent-point)
(if (and (symbolp method) (fboundp method))
;; luser function - s/he better know what's going on.
(last-sexp (car (nthcdr 2 state)))
indentation)
(goto-char (1+ containing-sexp))
- ;; determine wheich of the indentations to use.
+ ;; determine which of the indentations to use.
(while (and (< (point) indent-point)
(condition-case nil
(progn (forward-sexp 1)
(provide 'mim-mode)
+;;; mim-mode.el ends here