[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] Bug: TBLFM regexp doesn't account for possible white space after the
From: |
Oleg Sivokon |
Subject: |
[O] Bug: TBLFM regexp doesn't account for possible white space after the pipe [8.2.2 (release_8.2.2-188-gc57372 @ /home/wvxvw/Projects/org-mode/lisp/)] |
Date: |
Fri, 08 May 2015 00:35:18 +0300 |
Remember to cover the basics, that is, what you expected to happen and
what in fact did happen. You don't know how to make a good report? See
http://orgmode.org/manual/Feedback.html#Feedback
Your bug report will be posted to the Org-mode mailing list.
------------------------------------------------------------------------
When evaluating a formula, the regular expression used to locate the
formula will miss, if there is a white space after the rightmost pipe in
the last row, i.e.
|1|*
#+tblfm: vsum($1)
asterisk is where the extra space character appears. Attached is my
attempt at patching it.
Best,
Oleg
Emacs : GNU Emacs 25.0.50.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.14.12)
of 2015-05-03 on wvxvvw-laptop
Package: Org-mode version 8.2.2 (release_8.2.2-188-gc57372 @
/home/wvxvw/Projects/org-mode/lisp/)
>From b91aeaf01f8f4a11f55cc60bbfd9c75e64d73554 Mon Sep 17 00:00:00 2001
From: wvxvw <address@hidden>
Date: Fri, 8 May 2015 00:09:21 +0300
Subject: [PATCH] TBLFM regex account for white space after last column.
---
lisp/org-table.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lisp/org-table.el b/lisp/org-table.el
index a644008..3ca0e76 100644
--- a/lisp/org-table.el
+++ b/lisp/org-table.el
@@ -56,7 +56,7 @@ This can be used to add additional functionality after the
table is sent
to the receiver position, otherwise, if table is not sent, the functions
are not run.")
-(defvar org-table-TBLFM-begin-regexp "|\n[ \t]*#\\+TBLFM: ")
+(defvar org-table-TBLFM-begin-regexp "|\s-*\n[ \t]*#\\+TBLFM: ")
(defcustom orgtbl-optimized (eq org-enable-table-editor 'optimized)
"Non-nil means use the optimized table editor version for `orgtbl-mode'.
--
2.1.0
- [O] Bug: TBLFM regexp doesn't account for possible white space after the pipe [8.2.2 (release_8.2.2-188-gc57372 @ /home/wvxvw/Projects/org-mode/lisp/)],
Oleg Sivokon <=