aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2018-11-20 09:38:42 -0800
committerGlenn Morris2018-11-20 09:38:42 -0800
commitbb7b75d7110c7a46407aa4efc33446ace0cba631 (patch)
tree110ea4c557a39818da2ed8ebcea40f237b48a0f6
parente1b2c21b431accc397219b432a76a716acc6dbc2 (diff)
parent070e82b96bfadb5a3622607a8c5c97c127ec62db (diff)
downloademacs-bb7b75d7110c7a46407aa4efc33446ace0cba631.tar.gz
emacs-bb7b75d7110c7a46407aa4efc33446ace0cba631.zip
Merge from origin/emacs-26
070e82b ; * src/window.c (window_scroll): Improve commentary. 60457d7 Improve documentation of the window tree ea1a014 Fix window scrolling on TTY frames when there's no mode line df7ed10 Fix decoding XML files encoded in ISO-8859 7851ae8 (tag: emacs-26.1.90) ; ChangeLog.3 update 1958808 * etc/AUTHORS: Update. 7252507 Fix description of some window hooks 88762b4 Run 'window--adjust-process-windows' when frame size changes ... d6542ea Avoid errors in zone.el when there's overlay at EOB
-rw-r--r--ChangeLog.3103
-rw-r--r--doc/lispref/windows.texi45
-rw-r--r--etc/AUTHORS8
-rw-r--r--lisp/international/mule.el6
-rw-r--r--lisp/play/zone.el2
-rw-r--r--lisp/window.el7
-rw-r--r--src/window.c24
-rw-r--r--src/window.h12
8 files changed, 160 insertions, 47 deletions
diff --git a/ChangeLog.3 b/ChangeLog.3
index 6e1f68fe994..194fa685c91 100644
--- a/ChangeLog.3
+++ b/ChangeLog.3
@@ -1,3 +1,104 @@
12018-11-18 Martin Rudalics <rudalics@gmx.at>
2
3 Fix description of some window hooks
4
5 * doc/lispref/windows.texi (Window Hooks): Remove text that
6 warns against using 'save-window-excursion' while running
7 'window-size-change-functions', it's no more relevant.
8 Clarify description of 'window-configuration-change-hook'.
9
102018-11-18 Gary Fredericks <fredericksgary@gmail.com> (tiny change)
11
12 Run 'window--adjust-process-windows' when frame size changes (Bug#32720)
13
14 * lisp/window.el (window-size-change-functions): Run
15 'window--adjust-process-windows' from
16 'window-size-change-functions' too (Bug#32720, "another issue"
17 in Bug#33230).
18
192018-11-16 Eli Zaretskii <eliz@gnu.org>
20
21 Avoid errors in zone.el when there's overlay at EOB
22
23 * lisp/play/zone.el (zone): Make sure the window-end position
24 is calculated accurately, to avoid errors from
25 buffer-substring. (Bug#33384)
26
272018-11-16 Eli Zaretskii <eliz@gnu.org>
28
29 Document Emacs 26 behavior of Dired's 'Z' on directories
30
31 * doc/emacs/dired.texi (Operating on Files): Document behavior
32 of 'Z' on directories.
33
34 * etc/NEWS: Belatedly announce the new behavior of Dired's 'Z'
35 on directory names and on .tar.gz archives.
36
372018-11-15 Eli Zaretskii <eliz@gnu.org>
38
39 Fix a typo in the Emacs manual
40
41 * doc/emacs/rmail.texi (Rmail Deletion): Fix a typo.
42 Reported by Jorge P. de Morais Neto <jorge+list@disroot.org>
43 in emacs-manual-bugs@gnu.org
44
452018-11-15 Paul Eggert <eggert@cs.ucla.edu>
46
47 Fix tempfile creation when byte compiling
48
49 This improves on the recent fix for master failing to build
50 on FreeBSD. Suggested by Stefan Monnier in:
51 https://lists.gnu.org/r/emacs-devel/2018-01/msg00600.html
52 * lisp/emacs-lisp/bytecomp.el (byte-compile-file):
53 Put tempfile next to the target file, as was the original intent.
54
55 (cherry picked from commit 64c846738617d1d037eac0cefb6586c04317b0a1)
56
572018-11-14 Markus Triska <triska@metalevel.at>
58
59 Small documentation correction.
60
61 * doc/lispref/windows.texi (Textual Scrolling): In the description of
62 scroll-up-aggressively, refer to scroll-down-aggressively instead of
63 a recursive reference to scroll-up-aggressively. (Bug#33369)
64
652018-11-14 Eli Zaretskii <eliz@gnu.org>
66
67 * src/coding.c (Fcheck_coding_systems_region): Doc fix. (Bug#33372)
68
692018-11-14 Michael Albinus <michael.albinus@gmx.de>
70
71 Fix Bug#33364
72
73 * lisp/net/tramp.el (tramp-parse-sconfig-group): Support also
74 "Host host1 host2 ..." syntax. (Bug#33364)
75
762018-11-13 Michael Albinus <michael.albinus@gmx.de>
77
78 * test/README: Explain $REMOTE_TEMPORARY_FILE_DIRECTORY.
79
802018-11-12 Glenn Morris <rgm@gnu.org>
81
82 Avoid kill-emacs-hook errors hanging batch mode
83
84 * src/emacs.c (Fkill_emacs): Prevent errors from kill-emacs-hook
85 hanging Emacs in batch mode. (Bug#29955)
86
87 (cherry picked from commit 109da684c5124e22505917fe0255ca66f2a6bfc9)
88
892018-11-12 Nicolas Petton <nicolas@petton.fr>
90
91 Bump Emacs version to 26.1.90
92
93 * README:
94 * configure.ac:
95 * msdos/sed2v2.inp:
96 * nt/README.W32: Bump Emacs version to 26.1.90.
97
982018-11-12 Nicolas Petton <nicolas@petton.fr>
99
100 * etc/AUTHORS: Update.
101
12018-11-12 Paul Eggert <eggert@cs.ucla.edu> 1022018-11-12 Paul Eggert <eggert@cs.ucla.edu>
2 103
3 Work around dumping bug on GNU/Linux ppc64le 104 Work around dumping bug on GNU/Linux ppc64le
@@ -63347,7 +63448,7 @@
63347 63448
63348This file records repository revisions from 63449This file records repository revisions from
63349commit 9d56a21e6a696ad19ac65c4b405aeca44785884a (exclusive) to 63450commit 9d56a21e6a696ad19ac65c4b405aeca44785884a (exclusive) to
63350commit 1d79c2ebd9bd9aa36586e57463502373c0296d11 (inclusive). 63451commit 72525076996cd709086b1afb47ab0d095322e9b7 (inclusive).
63351See ChangeLog.1 for earlier changes. 63452See ChangeLog.1 for earlier changes.
63352 63453
63353;; Local Variables: 63454;; Local Variables:
diff --git a/doc/lispref/windows.texi b/doc/lispref/windows.texi
index af497cf6af9..b86bccab202 100644
--- a/doc/lispref/windows.texi
+++ b/doc/lispref/windows.texi
@@ -198,12 +198,13 @@ relationships between live windows. The root node of a window tree is
198called the @dfn{root window}. It can be either a live window (if the 198called the @dfn{root window}. It can be either a live window (if the
199frame has just one window), or an internal window. 199frame has just one window), or an internal window.
200 200
201 A minibuffer window (@pxref{Minibuffer Windows}) is not part of its 201 A minibuffer window (@pxref{Minibuffer Windows}) that is not alone
202frame's window tree unless the frame is a minibuffer-only frame. 202on its frame does not have a parent window, so it strictly speaking is
203Nonetheless, most of the functions in this section accept the 203not part of its frame's window tree. Nonetheless, it is a sibling
204minibuffer window as an argument. Also, the function 204window of the frame's root window, and thus can be reached via
205@code{window-tree} described at the end of this section lists the 205@code{window-next-sibling}. Also, the function @code{window-tree}
206minibuffer window alongside the actual window tree. 206described at the end of this section lists the minibuffer window
207alongside the actual window tree.
207 208
208@defun frame-root-window &optional frame-or-window 209@defun frame-root-window &optional frame-or-window
209This function returns the root window for @var{frame-or-window}. The 210This function returns the root window for @var{frame-or-window}. The
@@ -6037,26 +6038,24 @@ size and has to check out these windows by using the method described
6037in the previous paragraph. 6038in the previous paragraph.
6038 6039
6039These function are usually only called when at least one window was 6040These function are usually only called when at least one window was
6040added or has changed size since the last time this hook was run for the 6041added or has changed size since the last time this hook was run for
6041associated frame. In some rare cases this hook also runs when a window 6042the associated frame. In some rare cases this hook also runs when a
6042that was added intermittently has been deleted afterwards. In these 6043window that was added intermittently has been deleted afterwards. In
6043cases none of the windows on the frame will appear to have changed its 6044these cases none of the windows on the frame will appear to have
6044size. 6045changed its size.
6045
6046You may use @code{save-selected-window} in these functions
6047(@pxref{Selecting Windows}). However, do not use
6048@code{save-window-excursion} (@pxref{Window Configurations}); exiting
6049that macro counts as a size change, which would cause these functions to
6050be called again.
6051@end defvar 6046@end defvar
6052 6047
6053@defvar window-configuration-change-hook 6048@defvar window-configuration-change-hook
6054A normal hook that is run every time the window configuration of a frame 6049A normal hook that is run every time the window configuration of a
6055changes. Window configuration changes include splitting and deleting 6050frame changes. Window configuration changes include splitting and
6056windows, and the display of a different buffer in a window. Resizing the 6051deleting windows, and the display of a different buffer in a window.
6057frame or individual windows do not count as configuration changes. Use 6052
6058@code{window-size-change-functions}, see above, when you want to track 6053The hook can be also used for tracking changes of window sizes. It
6059size changes that are not caused by the deletion or creation of windows. 6054is, however, not run when the size of a frame changes or automatic
6055resizing of a minibuffer window (@pxref{Minibuffer Windows}) changes
6056the size of another window. As a rule, adding a function to
6057@code{window-size-change-functions}, see above, is the recommended way
6058for reliably tracking size changes of any window.
6060 6059
6061The buffer-local value of this hook is run once for each window on the 6060The buffer-local value of this hook is run once for each window on the
6062affected frame, with the relevant window selected and its buffer 6061affected frame, with the relevant window selected and its buffer
diff --git a/etc/AUTHORS b/etc/AUTHORS
index 23c88d55909..07cdf0acfcf 100644
--- a/etc/AUTHORS
+++ b/etc/AUTHORS
@@ -1658,6 +1658,8 @@ Gary Delp: wrote mailpost.el (public domain)
1658Gary D. Foster: wrote crisp.el scroll-all.el 1658Gary D. Foster: wrote crisp.el scroll-all.el
1659and changed gnus-group.el gnus-topic.el 1659and changed gnus-group.el gnus-topic.el
1660 1660
1661Gary Fredericks: changed window.el
1662
1661Gary Howell: changed server.el 1663Gary Howell: changed server.el
1662 1664
1663Gary Oberbrunner: changed gud.el 1665Gary Oberbrunner: changed gud.el
@@ -3124,7 +3126,7 @@ Markus Triska: wrote linum.el
3124and changed bytecomp.el byte-opt.el doctor.el image-mode.el 3126and changed bytecomp.el byte-opt.el doctor.el image-mode.el
3125 processes.texi calc-math.el emacs.c expand.el flymake.el flymake.texi 3127 processes.texi calc-math.el emacs.c expand.el flymake.el flymake.texi
3126 flyspell.el handwrite.el internals.texi proced.el prolog.el ps-mode.el 3128 flyspell.el handwrite.el internals.texi proced.el prolog.el ps-mode.el
3127 speedbar.el subr.el tumme.el widget.texi xterm.c 3129 speedbar.el subr.el tumme.el widget.texi windows.texi xterm.c
3128 3130
3129Mark W. Eichin: changed keyboard.c xterm.c 3131Mark W. Eichin: changed keyboard.c xterm.c
3130 3132
@@ -3584,8 +3586,8 @@ Nicolas Graner: changed message.el
3584Nicolas Petton: wrote map-tests.el map.el seq-tests.el seq.el 3586Nicolas Petton: wrote map-tests.el map.el seq-tests.el seq.el
3585 thunk-tests.el thunk.el 3587 thunk-tests.el thunk.el
3586and co-wrote auth-source-pass.el auth-source-tests.el subr-tests.el 3588and co-wrote auth-source-pass.el auth-source-tests.el subr-tests.el
3587and changed sequences.texi README configure.ac sed2v2.inp authors.el 3589and changed README sequences.texi configure.ac sed2v2.inp authors.el
3588 emacs.png README.W32 emacs23.png arc-mode.el cl-extra.el emacs.svg 3590 README.W32 emacs.png emacs23.png arc-mode.el cl-extra.el emacs.svg
3589 manoj-dark-theme.el Emacs.icns HISTORY Makefile.in auth-source.el 3591 manoj-dark-theme.el Emacs.icns HISTORY Makefile.in auth-source.el
3590 emacs.ico fns.c make-tarball.txt obarray-tests.el obarray.el 3592 emacs.ico fns.c make-tarball.txt obarray-tests.el obarray.el
3591 and 35 other files 3593 and 35 other files
diff --git a/lisp/international/mule.el b/lisp/international/mule.el
index a4f344192cd..31003d1a323 100644
--- a/lisp/international/mule.el
+++ b/lisp/international/mule.el
@@ -2501,7 +2501,11 @@ This function is intended to be added to `auto-coding-functions'."
2501 (let ((sym-type (coding-system-type sym)) 2501 (let ((sym-type (coding-system-type sym))
2502 (bfcs-type 2502 (bfcs-type
2503 (coding-system-type buffer-file-coding-system))) 2503 (coding-system-type buffer-file-coding-system)))
2504 (if (and (coding-system-equal 'utf-8 sym-type) 2504 ;; 'charset' will signal an error in
2505 ;; coding-system-equal, since it isn't a
2506 ;; coding-system. So test that up front.
2507 (if (and (not (equal sym-type 'charset))
2508 (coding-system-equal 'utf-8 sym-type)
2505 (coding-system-equal 'utf-8 bfcs-type)) 2509 (coding-system-equal 'utf-8 bfcs-type))
2506 buffer-file-coding-system 2510 buffer-file-coding-system
2507 sym)) 2511 sym))
diff --git a/lisp/play/zone.el b/lisp/play/zone.el
index 4584d26f385..75f13646190 100644
--- a/lisp/play/zone.el
+++ b/lisp/play/zone.el
@@ -109,7 +109,7 @@ If the element is a function or a list of a function and a number,
109 (save-window-excursion 109 (save-window-excursion
110 (let ((f (selected-frame)) 110 (let ((f (selected-frame))
111 (outbuf (get-buffer-create "*zone*")) 111 (outbuf (get-buffer-create "*zone*"))
112 (text (buffer-substring (window-start) (window-end))) 112 (text (buffer-substring (window-start) (window-end nil t)))
113 (wp (1+ (- (window-point) 113 (wp (1+ (- (window-point)
114 (window-start))))) 114 (window-start)))))
115 (put 'zone 'orig-buffer (current-buffer)) 115 (put 'zone 'orig-buffer (current-buffer))
diff --git a/lisp/window.el b/lisp/window.el
index 172ee729978..43a742b2d8c 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -9353,8 +9353,15 @@ displaying that processes's buffer."
9353 (when size 9353 (when size
9354 (set-process-window-size process (cdr size) (car size)))))))))) 9354 (set-process-window-size process (cdr size) (car size))))))))))
9355 9355
9356;; Remove the following call in Emacs 27, running
9357;; 'window-size-change-functions' should suffice.
9356(add-hook 'window-configuration-change-hook 'window--adjust-process-windows) 9358(add-hook 'window-configuration-change-hook 'window--adjust-process-windows)
9357 9359
9360;; Catch any size changes not handled by
9361;; 'window-configuration-change-hook' (Bug#32720, "another issue" in
9362;; Bug#33230).
9363(add-hook 'window-size-change-functions (lambda (_frame)
9364 (window--adjust-process-windows)))
9358 9365
9359;; Some of these are in tutorial--default-keys, so update that if you 9366;; Some of these are in tutorial--default-keys, so update that if you
9360;; change these. 9367;; change these.
diff --git a/src/window.c b/src/window.c
index 20084a15c16..31e9782b4a8 100644
--- a/src/window.c
+++ b/src/window.c
@@ -4970,25 +4970,21 @@ window_wants_header_line (struct window *w)
4970 : 0); 4970 : 0);
4971} 4971}
4972 4972
4973/* Return number of lines of text (not counting mode lines) in W. */ 4973/* Return number of lines of text in window W, not counting the mode
4974 line and header line, if any. Do NOT use this for windows on GUI
4975 frames; use window_body_height instead. This function is only for
4976 windows on TTY frames, where it is much more efficient. */
4974 4977
4975int 4978int
4976window_internal_height (struct window *w) 4979window_internal_height (struct window *w)
4977{ 4980{
4978 int ht = w->total_lines; 4981 int ht = w->total_lines;
4979 4982
4980 if (!MINI_WINDOW_P (w)) 4983 if (window_wants_mode_line (w))
4981 { 4984 --ht;
4982 if (!NILP (w->parent)
4983 || WINDOWP (w->contents)
4984 || !NILP (w->next)
4985 || !NILP (w->prev)
4986 || window_wants_mode_line (w))
4987 --ht;
4988 4985
4989 if (window_wants_header_line (w)) 4986 if (window_wants_header_line (w))
4990 --ht; 4987 --ht;
4991 }
4992 4988
4993 return ht; 4989 return ht;
4994} 4990}
@@ -5017,8 +5013,8 @@ window_scroll (Lisp_Object window, EMACS_INT n, bool whole, bool noerror)
5017 if (whole && Vfast_but_imprecise_scrolling) 5013 if (whole && Vfast_but_imprecise_scrolling)
5018 specbind (Qfontification_functions, Qnil); 5014 specbind (Qfontification_functions, Qnil);
5019 5015
5020 /* If we must, use the pixel-based version which is much slower than 5016 /* On GUI frames, use the pixel-based version which is much slower
5021 the line-based one but can handle varying line heights. */ 5017 than the line-based one but can handle varying line heights. */
5022 if (FRAME_WINDOW_P (XFRAME (XWINDOW (window)->frame))) 5018 if (FRAME_WINDOW_P (XFRAME (XWINDOW (window)->frame)))
5023 window_scroll_pixel_based (window, n, whole, noerror); 5019 window_scroll_pixel_based (window, n, whole, noerror);
5024 else 5020 else
diff --git a/src/window.h b/src/window.h
index cc0b6b6667d..b3673a0b454 100644
--- a/src/window.h
+++ b/src/window.h
@@ -93,12 +93,14 @@ struct window
93 /* The frame this window is on. */ 93 /* The frame this window is on. */
94 Lisp_Object frame; 94 Lisp_Object frame;
95 95
96 /* Following (to right or down) and preceding (to left or up) child 96 /* Following (to right or down) and preceding (to left or up)
97 at same level of tree. */ 97 child at same level of tree. Whether this is left/right or
98 up/down is determined by the 'horizontal' flag, see below.
99 A minibuffer window has the frame's root window pointed by 'prev'. */
98 Lisp_Object next; 100 Lisp_Object next;
99 Lisp_Object prev; 101 Lisp_Object prev;
100 102
101 /* The window this one is a child of. */ 103 /* The window this one is a child of. For a minibuffer window: nil. */
102 Lisp_Object parent; 104 Lisp_Object parent;
103 105
104 /* The normal size of the window. These are fractions, but we do 106 /* The normal size of the window. These are fractions, but we do
@@ -113,7 +115,9 @@ struct window
113 Lisp_Object new_normal; 115 Lisp_Object new_normal;
114 Lisp_Object new_pixel; 116 Lisp_Object new_pixel;
115 117
116 /* May be buffer, window, or nil. */ 118 /* For a leaf window: a buffer; for an internal window: a window;
119 for a pseudo-window (such as menu bar or tool bar): nil. It is
120 a buffer for a minibuffer window as well. */
117 Lisp_Object contents; 121 Lisp_Object contents;
118 122
119 /* A marker pointing to where in the text to start displaying. 123 /* A marker pointing to where in the text to start displaying.