[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Customize ‘window-state-get/put’

From: Juri Linkov
Subject: Re: Customize ‘window-state-get/put’
Date: Tue, 15 Oct 2019 21:14:08 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)

>> By placeholder do you mean some default text contents to show when
>> tmp buffer is not restored?  Something like “tmp buffer was here”.
> I mean a dummy buffer for window-state-get to save. This buffer is not
> visible to the user in theory: I create it and put it in every window and
> call window-state-get, then swap back buffers and remove this
> placeholder. Then before window-state-put create this buffer, and
> window-state-put will put it in every window. Once I restored every
> windows’ buffer from their window parameter, I can kill the
> placeholder. The sole purpose of the placeholder is for
> window-state-get/put to have /something/ to save/display.

Yes, this is a good solution for gdb-mi.

As for the desktop, we need to find a solution what to show in a saved
window when the file was deleted before restoring the saved file buffer.

Or maybe this problem is not specific to the desktop: even during the
same session, when a buffer (saved in the window configuration) was killed,
then restoring this window configuration just removes the window where
this buffer was before.  Often this has surprising effect.

What is the alternative?  Maybe to show an empty buffer in its previous
window with text like “killed buffer was here” and a button to restore it:
in case of file buffers it could call 'find-file'.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]