From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Markus Triska Newsgroups: gmane.emacs.help Subject: Re: recognizing "end" correctly in Octave mode Date: Fri, 01 Dec 2006 18:32:24 +0100 Message-ID: <87psb3r07r.fsf@gmx.at> References: <873b82e9vv.fsf@ma-patru.mathematik.uni-karlsruhe.de> <87irgwrlr4.fsf@ma-patru.mathematik.uni-karlsruhe.de> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1164994903 19468 80.91.229.2 (1 Dec 2006 17:41:43 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 1 Dec 2006 17:41:43 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Dec 01 18:41:41 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GqCO7-00079K-Sa for geh-help-gnu-emacs@m.gmane.org; Fri, 01 Dec 2006 18:41:28 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GqCO7-0005uj-FA for geh-help-gnu-emacs@m.gmane.org; Fri, 01 Dec 2006 12:41:27 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!news-fra1.dfn.de!newscore.univie.ac.at!aconews-feed.univie.ac.at!aconews.univie.ac.at!not-for-mail Original-Newsgroups: gnu.emacs.help Cancel-Lock: sha1:/Rj0UBZb7+yZgDNtgTdEbUNL2oI= Original-Lines: 29 Original-NNTP-Posting-Host: news-access-from.tuwien.ac.at Original-X-Trace: 1164994273 tunews.univie.ac.at 28520 192.35.241.118 Original-X-Complaints-To: abuse@tuwien.ac.at Original-Xref: shelby.stanford.edu gnu.emacs.help:143578 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:39180 Archived-At: Nicolas Neuss writes: > This is how Octave mode wants to indent: > > function A = LR3 (A0) > A=A0; > m=rows(A); n=columns(A); > for i=1:min(m,n) > A(i+1:m,i)=A(i+1:m,i)/A(i,i); > A(i+1:m,i+1:n) = A(i+1:m,i+1:n)-A(i+1:m,i)*A(i,i+1:n); > end > end indent-region on this gives: function A = LR3 (A0) A=A0; m=rows(A); n=columns(A); for i=1:min(m,n) A(i+1:m,i)=A(i+1:m,i)/A(i,i); A(i+1:m,i+1:n) = A(i+1:m,i+1:n)-A(i+1:m,i)*A(i,i+1:n); end end in GNU Emacs 22.0.90.10. All the best, Markus Triska