I have an odd intermittent problem with Emacs disappearing from view. I haven't quite figured out the trigger for this. It doesn't happen often and I can't reproduce it on purpose. Sometimes it happens when losing focus, sometimes while navigating the menu bar, sometimes seemingly random. I'm hoping someone else has seen this and can shed some light on what is going on.
What I mean by "disappearing" is just that, the frame is no longer drawn and cannot be raised into view. The task bar still indicates an Emacs instance and I can interact with that to minimize/maximize it. When the click into the task bar should maximize/raise the frame, the window manager does change to indicate that there is something in the desktop, but nothing is shown. Occasionally I can see the contents of the Emacs frame flash on screen before disappearing again. When I click the task bar again to minimize the window manager changes to reflect an empty desktop again. The only way I've found to fix this is to kill the emacs process and start it back up.
I'm hesitant to blame this on the window manager because I can put other things onto that desktop and interact with them normally. Even other Emacs frames continue to behave normally. I've also never observed the behavior with anything but Emacs frames.
- Emacs 24.4 (gtk3 toolkit) compiled from source w/ gcc 5.1.0 (.emacs)
- Awesome WM 3.4.15
- Xorg 7.4 w/ nvidia-drivers 352.21
I run X across three displays at 5760x1080. The Emacs frame that disappears is generally running maximized on the primary display (the center monitor). The WM is set to floating windows on the desktop that the Emacs frame is on so it shouldn't be some odd interaction from the WM tiling.
Does anyone have any ideas what might be causing this? Has anyone seen this themselves? One second the Emacs frame is in view, then it is just gone, never to reappear.
Some additional details:
When the window is invisible,
wmctrl reports its resolution as 1918x1059 which is full screen (minus window decoration and taskbar).
I have also just discovered the invisible window (Emacs frame) can still be interacted with. If I load up another emacsclient somewhere else and then unminimize the invisible window, position the mouse so it would have focus and type I see the text on the buffer I have open elsewhere. Clearly X11 keyboard events are being sent to the window and it is seen as having focus by X.
If the disappearing frame is part an emacsclient GUI frame, I can still connect to the server (started as
emacs --daemon) and access all of the buffers and interact with the invisible frame.
As this is likely a bug in emacs, I have filed a bug report and should a solution be found through that channel, I'll post an answer here.