[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 3f3d98e: Make truncate-lines permanently local (bug
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] master 3f3d98e: Make truncate-lines permanently local (bug#15396) |
Date: |
Thu, 30 Nov 2017 12:40:52 -0500 (EST) |
branch: master
commit 3f3d98ee5851840228786390ee7dbf851d144eb8
Author: Glenn Morris <address@hidden>
Commit: Glenn Morris <address@hidden>
Make truncate-lines permanently local (bug#15396)
Width of lines relative to display is rarely a function of major mode.
* src/buffer.c (init_buffer_once) <truncate-lines>:
Flag as permanently local.
* lisp/bindings.el (truncate-lines): Add permanent-local property.
---
lisp/bindings.el | 2 +-
src/buffer.c | 4 +++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/lisp/bindings.el b/lisp/bindings.el
index 2b66404..2bad903 100644
--- a/lisp/bindings.el
+++ b/lisp/bindings.el
@@ -699,7 +699,7 @@ okay. See `mode-line-format'.")
buffer-file-format buffer-auto-save-file-format
buffer-display-count buffer-display-time
enable-multibyte-characters
- buffer-file-coding-system))
+ buffer-file-coding-system truncate-lines))
;; We have base64, md5 and sha1 functions built in now.
(provide 'base64)
diff --git a/src/buffer.c b/src/buffer.c
index c6f9eb2..12a467d 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -5134,7 +5134,9 @@ init_buffer_once (void)
XSETFASTINT (BVAR (&buffer_local_flags, selective_display), idx); ++idx;
XSETFASTINT (BVAR (&buffer_local_flags, selective_display_ellipses), idx);
++idx;
XSETFASTINT (BVAR (&buffer_local_flags, tab_width), idx); ++idx;
- XSETFASTINT (BVAR (&buffer_local_flags, truncate_lines), idx); ++idx;
+ XSETFASTINT (BVAR (&buffer_local_flags, truncate_lines), idx);
+ /* Make this one a permanent local. */
+ buffer_permanent_local_flags[idx++] = 1;
XSETFASTINT (BVAR (&buffer_local_flags, word_wrap), idx); ++idx;
XSETFASTINT (BVAR (&buffer_local_flags, ctl_arrow), idx); ++idx;
XSETFASTINT (BVAR (&buffer_local_flags, fill_column), idx); ++idx;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 3f3d98e: Make truncate-lines permanently local (bug#15396),
Glenn Morris <=