Initial Commit
[packages] / xemacs-packages / ocaml / caml-compat.el
1 ;; function definitions for old versions of emacs
2
3 ;; indent-line-to
4
5 (if (not (fboundp 'indent-line-to))
6     (defun indent-line-to (column)
7       "Indent current line to COLUMN.
8
9 This function removes or adds spaces and tabs at beginning of line
10 only if necessary.  It leaves point at end of indentation."
11       (if (= (current-indentation) column)
12           (back-to-indentation)
13         (beginning-of-line 1)
14         (delete-horizontal-space)
15         (indent-to column))))
16
17 ;; buffer-substring-no-properties
18
19 (cond
20  ((fboundp 'buffer-substring-no-properties))
21  ((fboundp 'buffer-substring-without-properties)
22   (defalias 'buffer-substring-no-properties
23     'buffer-substring-without-properties))
24  (t
25   (defalias 'buffer-substring-no-properties 'buffer-substring)))
26
27 (provide 'caml-compat)
28