unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#40069: gnus-summary-exit does not restore windows
@ 2020-03-15  9:26 Juan José García Ripoll
  2020-07-19 13:47 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 2+ messages in thread
From: Juan José García Ripoll @ 2020-03-15  9:26 UTC (permalink / raw)
  To: 40069

I have set Gnus with the following configuration excerpt

(use-package gnus
  ;; Arrange windows:
  ;; - Group list left window
  ;; - Summary first quarter of right window
  ;; - Article bottom 3/4 of right window
  (gnus-use-full-window nil)
  (gnus-kill-summary-on-exit t)
  (gnus-buffer-configuration
    '((group (horizontal 1.0 (group 1.0 point)))
      (summary (horizontal 1.0
                           (group 0.3)
                           (summary 1.0 point)))
      (article (horizontal 1.0
                           (vertical 0.3 (group 1.0))
                           (vertical 1.0  (summary 0.25 point)
                                          (article 1.0))))))
  )

The process is as follows
1. Open gnus
2. Move on top of a group and enter
3. The window is split horizontally, with a group buffer on the left and
a summary buffer on the right
4. Press 'q' to exit the summary buffer
5. The summary buffer is killed and replaced with a group buffer
6. Now I have two windows displaying the summary buffer

What should have happened
5. Gnus activates the 'group' window configuration
6. It then kills the summary buffer and I am left with one window
showing the groups

A workaround is to add
  :hook
  (gnus-summary-exit . (lambda () (gnus-configure-windows 'group 'force)))

A fix would be to reorder the code in gnus-summary-exit, so that the
code related to group windows is placed before the code related to
burying / deleting summary buffers.

Gnus v5.13
GNU Emacs 26.3 (build 1, x86_64-w64-mingw32)
 of 2019-08-29

-- 
Juan José García Ripoll

Quantum Information and Foundations Group
Institute of Fundamental Physics IFF-CSIC
Calle Serrano 113b, Madrid 28006 Spain
http://quinfog.hbar.es - http://juanjose.garcia.ripoll





^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#40069: gnus-summary-exit does not restore windows
  2020-03-15  9:26 bug#40069: gnus-summary-exit does not restore windows Juan José García Ripoll
@ 2020-07-19 13:47 ` Lars Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Ingebrigtsen @ 2020-07-19 13:47 UTC (permalink / raw)
  To: Juan José García Ripoll; +Cc: 40069

juanjose.garcia.ripoll@csic.es (Juan José García Ripoll) writes:

> What should have happened
> 5. Gnus activates the 'group' window configuration
> 6. It then kills the summary buffer and I am left with one window
> showing the groups
>
> A workaround is to add
>   :hook
>   (gnus-summary-exit . (lambda () (gnus-configure-windows 'group 'force)))
>
> A fix would be to reorder the code in gnus-summary-exit, so that the
> code related to group windows is placed before the code related to
> burying / deleting summary buffers.

I've now reordered the exit code as you suggest in Emacs 28.1, and that
seems to make your use case work better, and doesn't seem to have any
adverse affect on the default configuration.

This code is ticklish, though, so I guess we'll just have to see whether
it has adverse effects on other setups.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-07-19 13:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-15  9:26 bug#40069: gnus-summary-exit does not restore windows Juan José García Ripoll
2020-07-19 13:47 ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).