diff options
| author | Chong Yidong | 2006-07-12 23:52:18 +0000 |
|---|---|---|
| committer | Chong Yidong | 2006-07-12 23:52:18 +0000 |
| commit | 6991960bf796139833ccc6158c745f9a8ca03aef (patch) | |
| tree | c7c7c0a7c61a2e23d737f044cb1853345b4f4c15 | |
| parent | fe5a02b3688971317d3f474d37b00048f75e07f9 (diff) | |
| download | emacs-6991960bf796139833ccc6158c745f9a8ca03aef.tar.gz emacs-6991960bf796139833ccc6158c745f9a8ca03aef.zip | |
* longlines.el (longlines-post-command-function): Handle open-line
too.
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/longlines.el | 16 |
2 files changed, 16 insertions, 5 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 57a591374ab..b23e8b538b0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2006-07-12 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * longlines.el (longlines-post-command-function): Handle open-line | ||
| 4 | too. | ||
| 5 | |||
| 1 | 2006-07-12 Richard Stallman <rms@gnu.org> | 6 | 2006-07-12 Richard Stallman <rms@gnu.org> |
| 2 | 7 | ||
| 3 | * progmodes/grep.el (grep-last-buffer): Doc fix. | 8 | * progmodes/grep.el (grep-last-buffer): Doc fix. |
diff --git a/lisp/longlines.el b/lisp/longlines.el index b11d4e6faba..943ee80cc0b 100644 --- a/lisp/longlines.el +++ b/lisp/longlines.el | |||
| @@ -401,11 +401,17 @@ This is called by `post-command-hook' after each command." | |||
| 401 | (longlines-decode-region (point) (mark t)) | 401 | (longlines-decode-region (point) (mark t)) |
| 402 | (if longlines-showing | 402 | (if longlines-showing |
| 403 | (longlines-show-region (point) (mark t)))) | 403 | (longlines-show-region (point) (mark t)))) |
| 404 | ((and (eq this-command 'newline) longlines-showing) | 404 | (longlines-showing |
| 405 | (save-excursion | 405 | (cond ((eq this-command 'newline) |
| 406 | (if (search-backward "\n" nil t) | 406 | (save-excursion |
| 407 | (longlines-show-region | 407 | (if (search-backward "\n" nil t) |
| 408 | (match-beginning 0) (match-end 0)))))) | 408 | (longlines-show-region |
| 409 | (match-beginning 0) (match-end 0))))) | ||
| 410 | ((eq this-command 'open-line) | ||
| 411 | (save-excursion | ||
| 412 | (if (search-forward "\n" nil t) | ||
| 413 | (longlines-show-region | ||
| 414 | (match-beginning 0) (match-end 0)))))))) | ||
| 409 | (unless (or (eq this-command 'fill-paragraph) | 415 | (unless (or (eq this-command 'fill-paragraph) |
| 410 | (eq this-command 'fill-region)) | 416 | (eq this-command 'fill-region)) |
| 411 | (longlines-wrap-region longlines-wrap-beg longlines-wrap-end)) | 417 | (longlines-wrap-region longlines-wrap-beg longlines-wrap-end)) |