diff options
Diffstat (limited to 'lisp/org/org-table.el')
-rw-r--r-- | lisp/org/org-table.el | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/org/org-table.el b/lisp/org/org-table.el index c9522341106..30a66c9c234 100644 --- a/lisp/org/org-table.el +++ b/lisp/org/org-table.el @@ -2712,7 +2712,8 @@ not overwrite the stored one." (or (fboundp 'calc-eval) (user-error "Calc does not seem to be installed, and is needed to evaluate the formula")) ;; Use <...> time-stamps so that Calc can handle them - (setq form (replace-regexp-in-string org-ts-regexp3 "<\\1>" form)) + (while (string-match (concat "\\[" org-ts-regexp1 "\\]") form) + (setq form (replace-match "<\\1>" nil nil form))) ;; I18n-ize local time-stamps by setting (system-time-locale "C") (when (string-match org-ts-regexp2 form) (let* ((ts (match-string 0 form)) @@ -3862,9 +3863,10 @@ With prefix ARG, apply the new formulas to the table." (push org-table-current-begin-pos org-show-positions) (let ((min (apply 'min org-show-positions)) (max (apply 'max org-show-positions))) - (goto-char min) (recenter 0) + (set-window-start (selected-window) min) (goto-char max) - (or (pos-visible-in-window-p max) (recenter -1)))) + (or (pos-visible-in-window-p max) + (set-window-start (selected-window) max)))) (select-window win)))) (defun org-table-force-dataline () |