How can I set focus to Glyphs window within other floating window?(in script)

Hi,

I’m developing a plugin which is similar to Preview panel.
In Preview panel, double click sets focus to editing window. But, in my case, I need to click editing window to activate or set focus to it.

please let me know if you have any idea.
Thanks in advance!

Something like this?

doc = Glyphs.currentDocument
if doc:
	doc.windowController().window().orderFront_(None)
1 Like

for me, makeKeyAndOrderFront_() seems to work.

Really thanks for your hint!