From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel E. Doherty Subject: Alignment Regexp Should Recognize Currencies Date: Fri, 09 Sep 2011 10:01:52 -0500 Message-ID: <871uvp4v4v.wl%ded-law@ddoherty.net> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Return-path: Received: from eggs.gnu.org ([140.186.70.92]:50159) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R22at-0005vV-Et for emacs-orgmode@gnu.org; Fri, 09 Sep 2011 11:02:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R22ar-0006uP-45 for emacs-orgmode@gnu.org; Fri, 09 Sep 2011 11:02:15 -0400 Received: from mail-vx0-f169.google.com ([209.85.220.169]:44949) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R22ar-0006uD-1l for emacs-orgmode@gnu.org; Fri, 09 Sep 2011 11:02:13 -0400 Received: by vxk12 with SMTP id 12so1601676vxk.0 for ; Fri, 09 Sep 2011 08:02:12 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org-mode List All, I noticed that the regular expression for recognizing what columns are numeric in a table for purposes of right-aligning does not pick up dollar values with commas. For example, $23,821,415.18 would be treated as "text" and left-aligned, which I don't believe is what one would expect. It can be fixed by customizing the variable org-table-number-regexp, like so: ^\([<>]?\(\$ *\)?[-+^.,0-9]*[0-9][-+^.0-9eEdDx()%:]*\| ... \)$ ^^^^^^^^ ^ Adding the underlined parts. My question is should this not be the default, perhaps with the Euro symbol and other likely currency symbols added in? Regards, -- ==================================================== Daniel E. Doherty Up the airy mountain, Down the rushy glen, We daren't go a-hunting, For fear of little men. --- William Allingham (Donegal, Ireland)