diff options
| author | Martin Rudalics | 2016-10-05 10:28:36 +0200 |
|---|---|---|
| committer | Martin Rudalics | 2016-10-05 10:28:36 +0200 |
| commit | b8fd71d5709650c1aced92c772f70595c51881d2 (patch) | |
| tree | c40e7b3a63e7168d5bb337d5d19a9643fe1901f9 /etc | |
| parent | 13ba5af7427bdbd022a9d449dc2987d6a96591eb (diff) | |
| download | emacs-b8fd71d5709650c1aced92c772f70595c51881d2.tar.gz emacs-b8fd71d5709650c1aced92c772f70595c51881d2.zip | |
Document and fix some bugs with side windows
Add a documentation for side windows and fix some bugs
found when testing their behavior. Also add a new window
parameter `no-delete-other-window', a new `display-buffer'
alist member called `window-parameters', and functions to
toggle and reverse side windows on a frame. Add new function
`window-swap-states' to exchange states of two live windows.
* lisp/window.el (display-buffer-in-atom-window): Use
`split-window-no-error'.
(window-sides-vertical): Maybe change layouts when setting this
variable.
(window-sides-reversed): New option.
(window-sides-slots): Rewrite doc-string and help echoes.
(window-sides-shown): New buffer-local variable set when showing
a buffer in a side window.
(window--sides-inhibit-check): New variable.
(window--sides-reverse-on-frame-p, window-toggle-side-windows)
(window--sides-reverse-all, window--sides-reverse-frame)
(window--sides-reverse-side, window--sides-reverse)
(window--sides-verticalize-frame, window--sides-verticalize)
(window--sides-check-failed): New functions.
(window--side-window-p): Remove function.
(window--major-non-side-window): Rename to `window-main-window',
adjust callers, rewrite doc-string.
(window--major-side-window): Rename to
`window--make-major-side-window-next-to', adjust caller, fix
doc-string.
(display-buffer-in-major-side-window): Rename to
`window--make-major-side-window', adjust
caller, rewrite doc-string. Make `window-side' and
`window-slot' parameters persistent (Bug#23858). Don't set
`delete-window' parameter. Add `preserve-size' entry to ALIST.
(delete-side-window): Remove function.
(display-buffer-in-side-window): Fix doc-string. Don't set
`delete-window' parameter. Add `preserve-size' entry to ALIST.
(window--side-check): Rename to window--sides-check. Rewrite
completely. Adjust caller.
(window-resize-no-error): Don't describe PIXELWISE argument.
(adjust-window-trailing-edge): Fix bug that disallowed
re-enlarging windows that were too small.
(window-deletable-p): Don't tell that a minibuffer window on a
non-minibuffer-only frame can be deleted. Fix doc-string.
(delete-window): Handle deleting a side window here (the
`delete-window' parameter is no more set for side windows).
(delete-other-windows): Handle ‘no-delete-other-window'
parameter. Don't treat side windows separately (see discussion
of Bug#24368) but keep optimization that makes the main window
the root window of its frame.
(switch-to-prev-buffer, switch-to-next-buffer): Handle side
windows and buffers shown in side windows separately.
(split-window-no-error): New function.
(window--state-get-1): Use right buffer when storing window
point and start positions and WRITABLE is nil (Bug#24368).
(window--state-put-1): Fix handling of `window-combination-limit'.
Use `split-window-no-error'.
(window--state-put-2): Try to restore windows with preserved
size to their original size. Fix bug where a fixed window's width
was not preserved.
(window-state-put): When reducing an internal window to a live
one, don't choose a side window.
(window-swap-states): New function.
(window-splittable-p): Don't call `window--side-window-p'.
(window--display-buffer): Handle `window-parameters' ALIST entry.
Minor rewrite.
(display-buffer): Mention `window-parameters' entry in
doc-string.
(display-buffer-at-bottom): Call `split-window-no-error'.
* doc/lispref/elisp.texi (Top): New section "Side Windows".
* doc/lispref/windows.texi (Deleting Windows): Fix descriptions
of `delete-window' and `delete-other-windows' wrt window
parameters and side windows.
(Display Action Functions): Mention `window-parameters' ALIST
entry.
(Side Windows): New section (Bug#18170).
(Window Configurations): Describe new function `window-swap-states'.
(Window Parameters): Say that functions may behave specially when
their homonymous window parameter has been set. Mention new
parameter `no-delete-other-window'. Add cross reference for
`window-side' and `window-slot' parameters.
Diffstat (limited to 'etc')
| -rw-r--r-- | etc/NEWS | 21 |
1 files changed, 21 insertions, 0 deletions
| @@ -611,6 +611,27 @@ collection). | |||
| 611 | ** The new functions 'make-nearby-temp-file' and 'temporary-file-directory' | 611 | ** The new functions 'make-nearby-temp-file' and 'temporary-file-directory' |
| 612 | can be used for creation of temporary files of remote or mounted directories. | 612 | can be used for creation of temporary files of remote or mounted directories. |
| 613 | 613 | ||
| 614 | ** Changes in Frame- and Window- Handling | ||
| 615 | |||
| 616 | +++ | ||
| 617 | *** Support for side windows is now official. The display action | ||
| 618 | function `display-buffer-in-side-window' will display its buffer in a | ||
| 619 | side window. Functions for toggling all side windows on a frame, | ||
| 620 | changing and reversing the layout of side windows and returning the main | ||
| 621 | (major non-side) window of a frame are provided. For details consult | ||
| 622 | the section "Side Windows" in the Elisp manual. | ||
| 623 | |||
| 624 | +++ | ||
| 625 | *** New `display-buffer' alist entry `window-parameters' allows to | ||
| 626 | assign window parameters to the window used for displaying the buffer. | ||
| 627 | |||
| 628 | +++ | ||
| 629 | *** New window parameter `no-delete-other-window' prevents that | ||
| 630 | its window gets deleted by `delete-other-windows'. | ||
| 631 | |||
| 632 | +++ | ||
| 633 | *** New command `window-swap-states' swaps the states of two live | ||
| 634 | windows. | ||
| 614 | 635 | ||
| 615 | * Changes in Emacs 26.1 on Non-Free Operating Systems | 636 | * Changes in Emacs 26.1 on Non-Free Operating Systems |
| 616 | 637 | ||