From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Taylor Jones" Newsgroups: gmane.emacs.help Subject: Newbie to Emacs-Lisp: Using the fill-paragraph function Date: Tue, 24 Apr 2007 14:20:36 -0700 Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1716948127==" X-Trace: sea.gmane.org 1177449657 4130 80.91.229.12 (24 Apr 2007 21:20:57 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 24 Apr 2007 21:20:57 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Apr 24 23:20:56 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 1HgSRU-0004wu-3z for geh-help-gnu-emacs@m.gmane.org; Tue, 24 Apr 2007 23:20:56 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HgSX1-0005sD-Sh for geh-help-gnu-emacs@m.gmane.org; Tue, 24 Apr 2007 17:26:39 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HgSWo-0005s8-I9 for help-gnu-emacs@gnu.org; Tue, 24 Apr 2007 17:26:26 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HgSWm-0005pk-2J for help-gnu-emacs@gnu.org; Tue, 24 Apr 2007 17:26:25 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HgSWl-0005ph-Ss for help-gnu-emacs@gnu.org; Tue, 24 Apr 2007 17:26:23 -0400 Original-Received: from nz-out-0506.google.com ([64.233.162.225]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1HgSRD-0001uh-8T for help-gnu-emacs@gnu.org; Tue, 24 Apr 2007 17:20:39 -0400 Original-Received: by nz-out-0506.google.com with SMTP id 12so594498nzp for ; Tue, 24 Apr 2007 14:20:38 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type; b=nPdItbNfhD3eJCl6gnS+5dKqjbpPc6sy+BI4BCFdhV5sb6/R0nMSLTViB+GPuFm70b3Ep3dlWkNVU0fHwDuX2TDcb0Vjy4x2Rlwtp2QljUpFImohEXtQsC8pkR92zBLo9QxTTwksTbvXtGlUU8tEwvyqaW1I1syWFgSNUA6Xhws= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:mime-version:content-type; b=GN6gwIGFvjtYzyh5/qzY/Ln6lg8y5nk2F3QjzftdDvxQG0T97Jtdhbtw2sqhVedx2y0UnLAzMgmcEPLtKeGN+H4jt5GZVzrtm8vzLiGHyHOatkROIyl+m7vVo+IUG9ixZO67MxA0NmQaFUZZQtzJQCsbpvIIvHdvwTYd3CIfzGI= Original-Received: by 10.115.106.7 with SMTP id i7mr678634wam.1177449636836; Tue, 24 Apr 2007 14:20:36 -0700 (PDT) Original-Received: by 10.115.106.20 with HTTP; Tue, 24 Apr 2007 14:20:36 -0700 (PDT) X-detected-kernel: Linux 2.4-2.6 (Google crawlbot) 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:43126 Archived-At: --===============1716948127== Content-Type: multipart/alternative; boundary="----=_Part_7683_8795521.1177449636797" ------=_Part_7683_8795521.1177449636797 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline I'm trying to write a function that inserts C function headers for me with a little interactive prompting. This is a snippet of what I'm trying to do: (if (> (length return) 0) (progn (insert " *\n") (insert " * @return ") (insert return) (insert "\n") (fill-paragraph)) ) As you can see, after I insert the " * @return " I want to use the fill-paragraph function, just as I would do if I were manually typing the line and using the M-q keybinding. When the fill-parargraph function runs, I get an error message "wrong number of arguments" and a bunch of gibberish. I've tried a bunch of different combinations of things and checked the C-h f help page for the fill-paragraph function, but I'm still stuck. Any help would be greatly appreciated! Taylor ------=_Part_7683_8795521.1177449636797 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline I'm trying to write a function that inserts C function headers for me with a little interactive prompting. This is a snippet of what I'm trying to do:

    (if (> (length return) 0)
    (progn
     (insert " *\n")
     (insert " * @return ")
     (insert return)
     (insert "\n")
     (fill-paragraph))
    )

As you can see, after I insert the " * @return <description of return value>" I want to use the fill-paragraph function, just as I would do if I were manually typing the line and using the M-q keybinding. When the fill-parargraph function runs, I get an error message "wrong number of arguments" and a bunch of gibberish. I've tried a bunch of different combinations of things and checked the C-h f help page for the fill-paragraph function, but I'm still stuck.

Any help would be greatly appreciated!

Taylor ------=_Part_7683_8795521.1177449636797-- --===============1716948127== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ help-gnu-emacs mailing list help-gnu-emacs@gnu.org http://lists.gnu.org/mailman/listinfo/help-gnu-emacs --===============1716948127==--