Commit 0aabb82c authored by Pontus Freyhult's avatar Pontus Freyhult
Browse files

Point old markers to nowhere before forgetting them.

parent ef58fad4
2004-10-27 Pontus Freyhult <pont@soua.net>
* mship-edit.el (lp--erase-entry): Point old markers to nil before
forgetting them.
(lp--print-entry): Dito.
2004-10-26 Pontus Freyhult <pont@soua.net>
* mship-edit.el (lp--redraw-entry-mark): Use lyskom-face-background,
......
......@@ -405,8 +405,12 @@ The start and end markers of the entry are adjusted"
(let ((buffer-read-only nil))
(insert-before-markers "\n")
(forward-char -1)
(if (lp--entry->start-marker entry)
(set-marker (lp--entry->start-marker entry) nil))
(set-lp--entry->start-marker entry (point-marker))
(lp--format-insert-entry entry)
(if (lp--entry->end-marker entry)
(set-marker (lp--entry->end-marker entry) nil))
(set-lp--entry->end-marker entry (point-marker))
(lp--entry-update-extents entry)
(forward-char 1))
......@@ -419,7 +423,11 @@ The start and end markers of the entry are adjusted"
(lp--entry->end-marker entry))
(delete-region (lp--entry->start-marker entry)
(1+ (lp--entry->end-marker entry))))
(if (lp--entry->start-marker entry)
(set-marker (lp--entry->start-marker entry) nil))
(set-lp--entry->start-marker entry nil)
(if (lp--entry->end-marker entry)
(set-marker (lp--entry->end-marker entry) nil))
(set-lp--entry->end-marker entry nil)
(lp--entry-update-extents entry)))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment