From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: Table rows and ranges as LHS of formulas Date: Fri, 4 Mar 2011 06:41:34 +0100 Message-ID: <06BFC6C6-A4A6-46F8-8ADC-6D20E194B576@gmail.com> References: <5A22097F-A1F9-480E-B2E5-030CD6493B2F@gmail.com> <878vwx5tgl.fsf@gnu.org> <907667C9-5D38-4DF4-B0CE-BEFEFE40A192@gmail.com> <24402.1299092049@alphaville.dokosmarshall.org> <31535.1299125895@alphaville.dokosmarshall.org> <20110303140151.3737c6a4@bhishma.homelinux.net> <5233.1299190260@alphaville.usa.hp.com> Mime-Version: 1.0 (Apple Message framework v1078) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=43351 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PvNlm-0000AL-Q6 for emacs-orgmode@gnu.org; Fri, 04 Mar 2011 00:41:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PvNll-0004Uu-9Z for emacs-orgmode@gnu.org; Fri, 04 Mar 2011 00:41:42 -0500 Received: from mail-ey0-f169.google.com ([209.85.215.169]:35081) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PvNll-0004Ui-2b for emacs-orgmode@gnu.org; Fri, 04 Mar 2011 00:41:41 -0500 Received: by eyh6 with SMTP id 6so624688eyh.0 for ; Thu, 03 Mar 2011 21:41:40 -0800 (PST) In-Reply-To: <5233.1299190260@alphaville.usa.hp.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: nicholas.dokos@hp.com Cc: emacs-orgmode List On 3.3.2011, at 23:11, Nick Dokos wrote: > Suvayu Ali wrote: >=20 >> Hi, >>=20 >> On Thu, 3 Mar 2011 22:19:32 +0100 >> Carsten Dominik wrote: >>=20 >>>=20 >>> On 3.3.2011, at 05:18, Nick Dokos wrote: >>>=20 >>>> Carsten Dominik wrote: >>>>=20 >>>>> Maybe we should use something else to achieve symmetry, like @> >>>>> and $>. >>>>>=20 >>>>> Comments? >>>>>=20 >>>>=20 >>>> Perfect. Mirrors the keybinding for end-of-buffer, so there is >>>> mnemonic value there, and it naturally flows from the @N$N = notation. >>>=20 >>> OK, this is how it works now. @L no longer works. >>>=20 >>=20 >> I updated org just now. But when I try this, >>=20 >> | Expense | Amount (CAD) | >> |----------+--------------| >> | Tickets | 1191.82 | >> | hostel | 838.49 | >> | per diem | 1050.00 | >> |----------+--------------| >> | Total | | >> #+TBLFM: @>$>=3Dvsum(@I..@II);%.2f >>=20 >> It doesn't work. Whereas this does: >>=20 >> | Expense | Amount (CAD) | >> |----------+--------------| >> | Tickets | 1191.82 | >> | hostel | 838.49 | >> | per diem | 1050.00 | >> |----------+--------------| >> | Total | 3080.31 | >> #+TBLFM: @5$2=3Dvsum(@I..@II);%.2f >>=20 >> Am I doing something wrong? >>=20 >=20 > I don't think so: I don't see Carsten's change even though I just = pulled, so > I guess he has not pushed it yet (or forgot to): Hmm, indeed, seems like I forgot to push. Did that just now, and tested Suvayu's example. - Carsten >=20 > ,---- > | $ git log -3 lisp/org-table.el > | commit dc60852d24b16555466214712181351e11b68e7c > | Author: Bastien Guerry > | Date: Thu Mar 3 09:34:34 2011 +0100 > |=20 > | Fix small typo in docstring. > |=20 > | commit 8892fe3f0404dd608452dd8203f2783a212e8120 > | Author: Bastien Guerry > | Date: Thu Mar 3 09:30:16 2011 +0100 > |=20 > | Fix small typo in docstring. > |=20 > | commit 8237c9ae6d587a22646333e0315683675e2db538 > | Author: Carsten Dominik > | Date: Tue Mar 1 09:05:56 2011 +0100 > |=20 > | Implement table formulas that apply to field ranges, fix minor = issues > | =20 > | * lisp/org-table.el (org-table-fedit-finish): Read more general = LHS of formulas. > | (org-table-formula-handle-@L): New function to hanle @L = references. > | (org-table-current-ncol): New variable. > | (org-table-line-to-dline): New function. > | (org-table-get-stored-formulas): Accept range formulas as = matches. > | (org-table-get-specials): Compute and store the number of = columns. > | (org-table-get-range): New optional argument CORNERS-ONLY, to = retrieve > | only the region marked by the range, not the content. > | (org-table-recalculate): Call `org-table-expand-lhs-ranges' to = expand > | range targets. Also check for duplicate access to fields. > | (org-table-expand-lhs-ranges): New funktion. > | (org-table-get-remote-range): Bind `org-table-current-ncol' to = protect > | the caller's value. > | (org-table-edit-formulas): Support highlighting of range = targets. > | (org-table-field-info): Handle renge formulas. > | =20 > | * doc/org.texi (Field and range formulas): Renamed from "Field = formulas". > | Document the use of range operators as targets. > | (References): Document the new @L reference. > `---- >=20 > Nick