1

I mean a window which will not be accessible via Cocoa, Carbon or other CoreGraphics API for obtaining NSWindow *, WindowRef and others.

Like X11 application on Mac does.

Such a window that if you pass its window ID to [NSApp windowWithWindowID] or HIWindowFromCGWindowID() they both return NULL.

Thanks!

Community
  • 1
  • 1
shoumikhin
  • 1,327
  • 15
  • 23
  • Perhaps, anybody is acquainted with libXplugin.dylib and Xplugin.h? It uses undocumented CoreGraphics API CGSNewWindow(), etc in its function xp_create_window(). – shoumikhin Jun 24 '10 at 17:52
  • Because I need to get Graphics Port of X11 emulated window, but it does not respond on [NSApp windowWithWindowNumber: ] or HIWindowFromCGWindowID() from the very same process. And I'm curious how it creates its windows in such way? – shoumikhin Jun 25 '10 at 09:22

1 Answers1

1

There's CoreGraphics Private API. Its definition is available thanks to reverse engineering. If some window is created with such API it won't be accessible via [NSApp windowWithWindowNumber: (NSInteger)windowID] or HIWindowFromCGWindowID() functions.

Xquartz uses Xplugin library, which in turn uses CoreGraphics Private API.

shoumikhin
  • 1,327
  • 15
  • 23
  • shoumikhin, were you able to use it?, did it solve your problem? - I'm in the same situation and wondering if this is THE path to the solution. – subzero Aug 26 '15 at 13:26