diff options
| -rw-r--r-- | lisp/window.el | 4 | ||||
| -rw-r--r-- | src/window.c | 14 |
2 files changed, 10 insertions, 8 deletions
diff --git a/lisp/window.el b/lisp/window.el index 50aec86a427..4e72d343674 100644 --- a/lisp/window.el +++ b/lisp/window.el | |||
| @@ -4278,7 +4278,7 @@ WINDOW must be a live window and defaults to the selected one." | |||
| 4278 | (list (copy-marker start) | 4278 | (list (copy-marker start) |
| 4279 | (copy-marker | 4279 | (copy-marker |
| 4280 | ;; Preserve window-point-insertion-type | 4280 | ;; Preserve window-point-insertion-type |
| 4281 | ;; (Bug#12588). | 4281 | ;; (Bug#12855). |
| 4282 | point window-point-insertion-type))))) | 4282 | point window-point-insertion-type))))) |
| 4283 | (set-window-prev-buffers | 4283 | (set-window-prev-buffers |
| 4284 | window (cons entry (window-prev-buffers window))))) | 4284 | window (cons entry (window-prev-buffers window))))) |
| @@ -6110,7 +6110,7 @@ element is BUFFER." | |||
| 6110 | (list 'other | 6110 | (list 'other |
| 6111 | ;; A quadruple of WINDOW's buffer, start, point and height. | 6111 | ;; A quadruple of WINDOW's buffer, start, point and height. |
| 6112 | (list (current-buffer) (window-start window) | 6112 | (list (current-buffer) (window-start window) |
| 6113 | ;; Preserve window-point-insertion-type (Bug#12588). | 6113 | ;; Preserve window-point-insertion-type (Bug#12855). |
| 6114 | (copy-marker | 6114 | (copy-marker |
| 6115 | (window-point window) window-point-insertion-type) | 6115 | (window-point window) window-point-insertion-type) |
| 6116 | (if (window-combined-p window) | 6116 | (if (window-combined-p window) |
diff --git a/src/window.c b/src/window.c index 14b3364477e..a69b115e4bb 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -6965,6 +6965,12 @@ save_window_save (Lisp_Object window, struct Lisp_Vector *vector, ptrdiff_t i) | |||
| 6965 | 6965 | ||
| 6966 | if (BUFFERP (w->contents)) | 6966 | if (BUFFERP (w->contents)) |
| 6967 | { | 6967 | { |
| 6968 | Lisp_Object buffer_local_window_point_insertion_type | ||
| 6969 | = (buffer_local_value (Qwindow_point_insertion_type, w->contents)); | ||
| 6970 | bool window_point_insertion_type | ||
| 6971 | = (!NILP (buffer_local_window_point_insertion_type) | ||
| 6972 | && !EQ (buffer_local_window_point_insertion_type, Qunbound)); | ||
| 6973 | |||
| 6968 | /* Save w's value of point in the window configuration. If w | 6974 | /* Save w's value of point in the window configuration. If w |
| 6969 | is the selected window, then get the value of point from | 6975 | is the selected window, then get the value of point from |
| 6970 | the buffer; pointm is garbage in the selected window. */ | 6976 | the buffer; pointm is garbage in the selected window. */ |
| @@ -6975,12 +6981,8 @@ save_window_save (Lisp_Object window, struct Lisp_Vector *vector, ptrdiff_t i) | |||
| 6975 | else | 6981 | else |
| 6976 | p->pointm = Fcopy_marker (w->pointm, Qnil); | 6982 | p->pointm = Fcopy_marker (w->pointm, Qnil); |
| 6977 | p->old_pointm = Fcopy_marker (w->old_pointm, Qnil); | 6983 | p->old_pointm = Fcopy_marker (w->old_pointm, Qnil); |
| 6978 | XMARKER (p->pointm)->insertion_type | 6984 | XMARKER (p->pointm)->insertion_type = window_point_insertion_type; |
| 6979 | = !NILP (buffer_local_value /* Don't signal error if void. */ | 6985 | XMARKER (p->old_pointm)->insertion_type = window_point_insertion_type; |
| 6980 | (Qwindow_point_insertion_type, w->contents)); | ||
| 6981 | XMARKER (p->old_pointm)->insertion_type | ||
| 6982 | = !NILP (buffer_local_value /* Don't signal error if void. */ | ||
| 6983 | (Qwindow_point_insertion_type, w->contents)); | ||
| 6984 | 6986 | ||
| 6985 | p->start = Fcopy_marker (w->start, Qnil); | 6987 | p->start = Fcopy_marker (w->start, Qnil); |
| 6986 | p->start_at_line_beg = w->start_at_line_beg ? Qt : Qnil; | 6988 | p->start_at_line_beg = w->start_at_line_beg ? Qt : Qnil; |