From: Matt Price <moptop99@gmail.com>
To: Jack Kamm <jackkamm@gmail.com>, Org Mode <emacs-orgmode@gnu.org>,
Richard Kim <Richard.Kim1@synopsys.com>
Subject: Re: [PATCH] restore window configuration after org-edit-src-exit
Date: Thu, 9 Jan 2020 10:03:18 -0500 [thread overview]
Message-ID: <CAN_Dec-M7bLrAB0W1sQod7H2p58OmKfgnA1iNRMSAzYHVoW5Uw@mail.gmail.com> (raw)
In-Reply-To: <8736crslbi.fsf@nicolasgoaziou.fr>
[-- Attachment #1: Type: text/plain, Size: 1850 bytes --]
Hi, sorry I missed this thread in the peri-holiday rush, just want to say
thank you all for ironing out the difficulties arsing from that change
earlier.
On Tue, Jan 7, 2020 at 4:06 AM Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> Hello,
>
> Jack Kamm <jackkamm@gmail.com> writes:
>
> > Attached is a patch to restore the window configuration after exiting an
> > org source buffer, when org-src-window-setup is one of reorganize-frame,
> > split-window-below, or split-window-right.
>
> Thank you for the patch! Some comments follow.
>
> > @@ -156,8 +156,7 @@ split-window-right Show edit buffer to the right of
> the current window,
> > keeping all other windows.
> > other-window Use `switch-to-buffer-other-window' to display edit
> buffer.
> > reorganize-frame Show only two windows on the current frame, the
> current
> > - window and the edit buffer. When exiting the edit
> buffer,
> > - return to one window.
> > + window and the edit buffer.
> > other-frame Use `switch-to-buffer-other-frame' to display edit
> buffer.
> > Also, when exiting the edit buffer, kill that
> > frame."
>
> It would be useful to also explain what happens when the value is
> `reorganize-frame', `split-window-right', or `split-window-right', e.g.,
> that previous window configuration is restored.
>
> > + (when org-src--saved-temp-window-config
> > + (set-window-configuration org-src--saved-temp-window-config)
> > + (setq org-src--saved-temp-window-config nil))))
>
> It may be useful to wrap `set-window-configuration' within
> `unwind-protect' so we can still reset the
> `org-src--saved-temp-window-config' variable even though something went
> wrong.
>
> WDYT?
>
> Regards,
>
> --
> Nicolas Goaziou
>
>
[-- Attachment #2: Type: text/html, Size: 2492 bytes --]
next prev parent reply other threads:[~2020-01-09 15:03 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-14 19:06 restore window configuration after org-edit-src-exit Richard Kim
2019-12-16 16:30 ` Nicolas Goaziou
2019-12-17 1:51 ` Kyle Meyer
2019-12-17 14:11 ` Jack Kamm
2019-12-17 14:28 ` Jack Kamm
2019-12-17 15:16 ` Fraga, Eric
2019-12-22 14:45 ` Nicolas Goaziou
2019-12-23 1:46 ` Jack Kamm
2019-12-23 8:17 ` Nicolas Goaziou
2019-12-23 17:15 ` Jack Kamm
2019-12-23 17:20 ` Nicolas Goaziou
2019-12-23 18:18 ` [PATCH] " Jack Kamm
2020-01-07 8:49 ` Nicolas Goaziou
2020-01-09 15:03 ` Matt Price [this message]
2020-01-09 17:43 ` Jack Kamm
2020-01-14 23:10 ` Jack Kamm
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAN_Dec-M7bLrAB0W1sQod7H2p58OmKfgnA1iNRMSAzYHVoW5Uw@mail.gmail.com \
--to=moptop99@gmail.com \
--cc=Richard.Kim1@synopsys.com \
--cc=emacs-orgmode@gnu.org \
--cc=jackkamm@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.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).