1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-12-18 10:17:03 +00:00

currently not even trying to find the table if it's in another file

(but this probably wouldn't be too much work)
This commit is contained in:
Eric Schulte 2009-03-28 14:25:26 -07:00
parent 9b2e4f2257
commit 5805507dc3

View File

@ -100,12 +100,16 @@ representation of the value of the variable."
(t (t
(goto-char (point-min)) (goto-char (point-min))
(setq direction 1) (setq direction 1)
(unless (re-search-forward (unless (let ((regexp (concat "^#\\+TBLNAME:[ \t]*"
(concat "^#\\+TBLNAME:[ \t]*" (regexp-quote ref) "[ \t]*$") nil t) (regexp-quote ref) "[ \t]*$")))
(setq id-loc (org-id-find name-or-id 'marker) (or (re-search-forward regexp nil t)
buffer (marker-buffer id-loc) (re-search-backward regexp nil t)))
loc (marker-position id-loc)) ;; ;; TODO: allow searching for table in other buffers
(move-marker id-loc nil)))) ;; (setq id-loc (org-id-find ref 'marker)
;; buffer (marker-buffer id-loc)
;; loc (marker-position id-loc))
;; (move-marker id-loc nil)
(error (format "table '%s' not found in this buffer" ref)))))
(while (not (org-at-table-p)) (while (not (org-at-table-p))
(forward-line direction) (forward-line direction)
(if (or (= (point) (point-min)) (= (point) (point-max))) (if (or (= (point) (point-min)) (= (point) (point-max)))