I've come across an interesting problem with a window manager I'm writing using the xpyb library. With or without me handling EnterNotifyEvents, gtk3 apps like gnome-terminal, sakura, and gedit all fail to either show a focused text cursor (gnome-terminal and sakura) or no text cursor at all (gedit). I know that it is possible since under twm it works properly. When I receive an EnterNotifyEvent I call this method:<div>
<div> def handle_enter_event(self, evt):</div><div> window = self.get_window(evt.window)</div><div> if evt.mode != xproto.NotifyMode.Normal:</div><div> return</div><div> window.focus()</div>
</div><div><br></div><div>window.focus() is defined as:</div><div><div> def focus(self):</div><div> self.conn.core.SetInputFocus(xproto.InputFocus.PointerRoot, self.win)</div><div> ewmh.set_active_window(self.win)</div>
<div><br></div><div>I am setting _NET_ACTIVE_WINDOW, and from all that I can tell, I'm doing pretty much the same thing as twm.</div>-- <br>Praising my Savior all the day long,<div>
Micah Nordland</div><br>
</div>