Mercurial > emacs
comparison lisp/simple.el @ 93662:3f94f995598c
(set-fill-column): Prompt rather than error by default.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Fri, 04 Apr 2008 16:16:23 +0000 |
parents | fbde6ee8b428 |
children | 22a31e3179e0 |
comparison
equal
deleted
inserted
replaced
93661:0e46418a00ea | 93662:3f94f995598c |
---|---|
4695 | 4695 |
4696 (defun set-fill-column (arg) | 4696 (defun set-fill-column (arg) |
4697 "Set `fill-column' to specified argument. | 4697 "Set `fill-column' to specified argument. |
4698 Use \\[universal-argument] followed by a number to specify a column. | 4698 Use \\[universal-argument] followed by a number to specify a column. |
4699 Just \\[universal-argument] as argument means to use the current column." | 4699 Just \\[universal-argument] as argument means to use the current column." |
4700 (interactive "P") | 4700 (interactive |
4701 (list (or current-prefix-arg | |
4702 ;; We used to use current-column silently, but C-x f is too easily | |
4703 ;; typed as a typo for C-x C-f, so we turned it into an error and | |
4704 ;; now an interactive prompt. | |
4705 (read-number "Set fill-column to: " (current-column))))) | |
4701 (if (consp arg) | 4706 (if (consp arg) |
4702 (setq arg (current-column))) | 4707 (setq arg (current-column))) |
4703 (if (not (integerp arg)) | 4708 (if (not (integerp arg)) |
4704 ;; Disallow missing argument; it's probably a typo for C-x C-f. | 4709 ;; Disallow missing argument; it's probably a typo for C-x C-f. |
4705 (error "set-fill-column requires an explicit argument") | 4710 (error "set-fill-column requires an explicit argument") |