diff options
| author | Eli Zaretskii | 2011-02-18 19:51:15 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2011-02-18 19:51:15 +0200 |
| commit | 61aa93ed0d083435c6fef9ab85d5776f233376e1 (patch) | |
| tree | c3f834c8252e63b5dec4d315944cba74bfc93063 | |
| parent | a167e505d53ca8a971e38fd85f757ca2e2cebda8 (diff) | |
| download | emacs-61aa93ed0d083435c6fef9ab85d5776f233376e1.tar.gz emacs-61aa93ed0d083435c6fef9ab85d5776f233376e1.zip | |
Fix bug #8047 with require-final-newline and image file display.
image-mode.el (image-toggle-display-image): Disable
require-final-newline in buffers visiting binary image files.
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/image-mode.el | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index da5b9ebbda2..8caa24c1f40 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,9 @@ | |||
| 1 | 2011-02-18 Eli Zaretskii <eliz@gnu.org> | 1 | 2011-02-18 Eli Zaretskii <eliz@gnu.org> |
| 2 | 2 | ||
| 3 | * image-mode.el (image-toggle-display-image): Disable | ||
| 4 | require-final-newline in buffers visiting binary image files. | ||
| 5 | (Bug#8047) | ||
| 6 | |||
| 3 | * international/mule-cmds.el (read-char-by-name, ucs-insert): | 7 | * international/mule-cmds.el (read-char-by-name, ucs-insert): |
| 4 | Document completion with asterisk and a substring. | 8 | Document completion with asterisk and a substring. |
| 5 | 9 | ||
diff --git a/lisp/image-mode.el b/lisp/image-mode.el index b30a43080d6..191e347330d 100644 --- a/lisp/image-mode.el +++ b/lisp/image-mode.el | |||
| @@ -507,6 +507,11 @@ was inserted." | |||
| 507 | ;; This just makes the arrow displayed in the right fringe | 507 | ;; This just makes the arrow displayed in the right fringe |
| 508 | ;; area look correct when the image is wider than the window. | 508 | ;; area look correct when the image is wider than the window. |
| 509 | (setq truncate-lines t) | 509 | (setq truncate-lines t) |
| 510 | ;; Disable adding a newline at the end of the image file when it | ||
| 511 | ;; is written with, e.g., C-x C-w. | ||
| 512 | (if (coding-system-equal (coding-system-base buffer-file-coding-system) | ||
| 513 | 'no-conversion) | ||
| 514 | (set (make-local-variable 'require-final-newline) nil)) | ||
| 510 | ;; Allow navigation of large images | 515 | ;; Allow navigation of large images |
| 511 | (set (make-local-variable 'auto-hscroll-mode) nil) | 516 | (set (make-local-variable 'auto-hscroll-mode) nil) |
| 512 | (setq image-type type) | 517 | (setq image-type type) |