[Ipe-discuss] prevent transients from grabbing focus

Otfried Cheong ipe at otfried.org
Sun Feb 14 18:55:42 CET 2021

On Sat, Feb 13, 2021, at 19:07, Mandar Mitra via Ipe-discuss wrote:
> When editing text / paragraphs in ipe, I use emacsclient as my editor. 
> Ipe pops up a little transient window that says "Waiting for external 
> editor" when going from ipe to emacs. On the way back, it pops up 
> another transient that says "Compiling LaTeX". These transients grab 
> the focus during their brief lifetimes, and I have to manually give 
> back focus to either the ipe or the emacs window.
> I'm sure I need to fix some setting in my window manager, but I'm 
> wondering if I can disable the transients from within ipe as a quick 
> fix.

The transient windows are essential - they guarantee that the Ipe event loop can keep running while the external program is running.

Are you on Linux?   Do you use `prefs.editor_closes_dialog` ?

The first issue is that when you go from Ipe to Emacs, focus is not passed to Emacs.  It seems I can easily fix this, Ipe just has to make sure that it calls emacsclient only after the small dialog has been shown.

The other direction is trickier and is quite specific to Emacs:  Since Emacs does not terminate when you are finished editing the text, Ipe does not become the active window again.  This has actually nothing to do with the transient window (try calling emacsclient from a terminal - the terminal does not receive keyboard focus back when Emacs is done editing).    What exactly would you expect (or want) to happen?    Would you want the "Edit text" dialog to be the active window again?


More information about the Ipe-discuss mailing list