From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Endless Story" Newsgroups: gmane.emacs.help Subject: What's wrong with this seemingly simple function for unwrapping text? Date: 12 Jan 2007 03:00:07 -0800 Organization: http://groups.google.com Message-ID: <1168599607.154137.166990@q2g2000cwa.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: sea.gmane.org 1168602080 14799 80.91.229.12 (12 Jan 2007 11:41:20 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 12 Jan 2007 11:41:20 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jan 12 12:41:18 2007 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1H5Kma-0003e9-1i for geh-help-gnu-emacs@m.gmane.org; Fri, 12 Jan 2007 12:41:16 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1H5KmZ-0008Bz-TI for geh-help-gnu-emacs@m.gmane.org; Fri, 12 Jan 2007 06:41:15 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!q2g2000cwa.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 20 Original-NNTP-Posting-Host: 70.18.58.165 Original-X-Trace: posting.google.com 1168599614 21621 127.0.0.1 (12 Jan 2007 11:00:14 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Fri, 12 Jan 2007 11:00:14 +0000 (UTC) User-Agent: G2/1.0 X-HTTP-UserAgent: Opera/9.02 (Windows NT 5.1; U; en),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: q2g2000cwa.googlegroups.com; posting-host=70.18.58.165; posting-account=JP8pbg0AAADYDr61n41ZYs45c0xuivey Original-Xref: shelby.stanford.edu gnu.emacs.help:144652 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:40256 Archived-At: I like autofill mode, but it has one disadvantage: the filled lines require unfilling if I want to copy the text over into a Word processor, e.g. Word or OpenOffice. This can be rather tedious, so I thought I would write a simple function and put it in my .init file to make everything easy: (defun unwrap-text () (interactive) (setq fill-column 5000) (mark-whole-buffer) (fill-region) (setq fill-column '70) ) When the function gets to fill-region, it bombs out, complaining about 'wrong number of variables.' So my questions are: 1) For any lisp experts, what's going wrong here? 2) Is there some built-in way for doing what I want to do?