From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Burkhard Schultheis Newsgroups: gmane.emacs.help Subject: Re: Spaces please! Date: Tue, 01 Dec 2009 19:26:12 +0100 Message-ID: <7nl5eaF3jmhkkU1@mid.individual.net> References: <7nl54mF3mcig6U1@mid.individual.net> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1259696961 32162 80.91.229.12 (1 Dec 2009 19:49:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 1 Dec 2009 19:49:21 +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 Dec 01 20:49:14 2009 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 1NFYin-0001sy-8a for geh-help-gnu-emacs@m.gmane.org; Tue, 01 Dec 2009 20:49:13 +0100 Original-Received: from localhost ([127.0.0.1]:47782 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NFYim-0001J7-Ps for geh-help-gnu-emacs@m.gmane.org; Tue, 01 Dec 2009 14:49:12 -0500 Original-Path: news.stanford.edu!usenet.stanford.edu!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 27 Original-X-Trace: individual.net x2Qx4nbWSZjbb9mYoAbyPQ7nyFdZDWtDLPijIzwEITz5AOQIAS Cancel-Lock: sha1:kVVaXYSFh3mm6VHZ0CD4fCLXHXI= User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.5) Gecko/20091121 Thunderbird/3.0 In-Reply-To: <7nl54mF3mcig6U1@mid.individual.net> Original-Xref: news.stanford.edu gnu.emacs.help:175215 X-Mailman-Approved-At: Tue, 01 Dec 2009 14:47:40 -0500 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:70292 Archived-At: Am 01.12.2009 19:21, schrieb Burkhard Schultheis: > Am 01.12.2009 17:19, schrieb andrea: >> >> I get sick sometimes to read something like >> x=y+1*(2-3*a^2) >> but I get even more sick to add spaces manually every time. >> I ask help to you elisp gurus, should I use a regexp or a macro-like >> function (go-here, do-this)? >> >> I think I should define some rules like: >> - which operators want spaces (and if before or after) >> - what is the arity of them >> >> One problem for example could arise from things like >> >> (-2)^10 >> but we could have some operators that could be binary or unary and check >> that somehow. > > I would do it with a beautifier like uncrustify with GUI universalident > (. It can do that and > much, much more! > > Regards > Burkhard ... but these programs do it for source code files, I think. ;-)