NSWindow (Revised since February 2009 seed) You can now ask if a window is on the active space. If the window is offscreen, due to being minimized or hidden for example, -isOnActiveSpace will return YES if ordering the window onscreen will order it on to the active space. - (BOOL)isOnActiveSpace; There is an NSWindow class method, +windowNumbersWithOptions:, to retrieve window numbers for all onscreen windows. By default, +windowNumbersWithOptions: returns the window numbers for the visible windows belonging to the calling process on the active space. You can also request the window numbers for all visible windows, regardless of owner, and for windows on all spaces. enum { NSWindowNumberListAllApplications = 1 << 0, NSWindowNumberListAllSpaces = 1 << 4 }; + (NSArray *)windowNumbersWithOptions:(NSWindowNumberListOptions)options; |