diff options
| author | Chong Yidong | 2005-11-20 05:17:27 +0000 |
|---|---|---|
| committer | Chong Yidong | 2005-11-20 05:17:27 +0000 |
| commit | cee723fbf90394a695e87ef9348d2907aa1cac65 (patch) | |
| tree | 5224531f3e984bd925da77773f88b09643e694c4 | |
| parent | 1271a058af5d3290abfde5b564a41df40881f5f2 (diff) | |
| download | emacs-cee723fbf90394a695e87ef9348d2907aa1cac65.tar.gz emacs-cee723fbf90394a695e87ef9348d2907aa1cac65.zip | |
longlines.el (longlines-wrap-line): Preserve marker positions.
| -rw-r--r-- | lisp/ChangeLog | 1 | ||||
| -rw-r--r-- | lisp/longlines.el | 7 |
2 files changed, 5 insertions, 3 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 57d6d885534..082c37f3365 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -5,6 +5,7 @@ | |||
| 5 | (longlines-mode): Turn off longlines temporarily when reverting. | 5 | (longlines-mode): Turn off longlines temporarily when reverting. |
| 6 | Add a message-setup-hook. | 6 | Add a message-setup-hook. |
| 7 | (longlines-decode-buffer): New function. | 7 | (longlines-decode-buffer): New function. |
| 8 | (longlines-wrap-line): Preserve marker positions. | ||
| 8 | 9 | ||
| 9 | 2005-11-19 Andreas Schwab <schwab@suse.de> | 10 | 2005-11-19 Andreas Schwab <schwab@suse.de> |
| 10 | 11 | ||
diff --git a/lisp/longlines.el b/lisp/longlines.el index 85358207a2b..93f3daa4ee8 100644 --- a/lisp/longlines.el +++ b/lisp/longlines.el | |||
| @@ -239,9 +239,10 @@ end of the buffer." | |||
| 239 | If wrapping is performed, point remains on the line. If the line does | 239 | If wrapping is performed, point remains on the line. If the line does |
| 240 | not need to be wrapped, move point to the next line and return t." | 240 | not need to be wrapped, move point to the next line and return t." |
| 241 | (if (longlines-set-breakpoint) | 241 | (if (longlines-set-breakpoint) |
| 242 | (progn (backward-char 1) | 242 | (progn (insert-before-markers ?\n) |
| 243 | (delete-char 1) | 243 | (backward-char 1) |
| 244 | (insert-char ?\n 1) | 244 | (delete-char -1) |
| 245 | (forward-char 1) | ||
| 245 | nil) | 246 | nil) |
| 246 | (if (longlines-merge-lines-p) | 247 | (if (longlines-merge-lines-p) |
| 247 | (progn (end-of-line) | 248 | (progn (end-of-line) |