Avoid problems with table alignment an overlays.

We now first insert a new aligned table, and then remove to old one,
this helps to keep overlays after the table from covering table text
as well.
This commit is contained in:
Carsten Dominik 2009-08-27 12:50:36 +02:00
parent 210251347c
commit 8160044f2e
3 changed files with 8 additions and 4 deletions

View File

@ -1,6 +1,10 @@
2009-08-27 Carsten Dominik <carsten.dominik@gmail.com>
* org-table.el (org-table-align): Change the order of reinsertion
and deletion, to avoid problems with overlays following the table.
* org.el (org-parse-time-string): Better error message.
(org-show-subtree): Use org-end-of-subtree.
* org-macs.el (org-goto-line): New defsubst.

View File

@ -719,9 +719,6 @@ When nil, simply write \"#ERROR\" in corrupted fields.")
(append (pop fields) emptystrings))
hfmt))
lines ""))
;; Replace the old one
(delete-region beg end)
(move-marker end nil)
(if (equal (char-before) ?\n)
;; This hack is for org-indent, to force redisplay of the
;; line prefix of the first line. Apparently the redisplay
@ -734,6 +731,9 @@ When nil, simply write \"#ERROR\" in corrupted fields.")
(insert "\n")))
(move-marker org-table-aligned-begin-marker (point))
(insert new)
;; Replace the old one
(delete-region (point) end)
(move-marker end nil)
(move-marker org-table-aligned-end-marker (point))
(when (and orgtbl-mode (not (org-mode-p)))
(goto-char org-table-aligned-begin-marker)

View File

@ -16796,7 +16796,7 @@ Stop at the first and last subheadings of a superior heading."
(outline-flag-region
(point)
(save-excursion
(outline-end-of-subtree) (outline-next-heading) (point))
(org-end-of-subtree t t))
nil))
(defun org-show-entry ()