I'm new to Cocoa, and I'm just experimenting with creating a window programmatically (without using Interface Builder).
I launch a new Cocoa application in Xcode, then I remove the window from the nib file in Interface Builder to replace it with my own.
In the main function, I add the code:
NSWindow* myWindow; myWindow = [[NSWindow alloc] initWithContentRect:NSMakeRect(10,100,400,300) styleMask:NSTitledWindowMask backing:NSBackingStoreBuffered defer:NO];
When I try to create and run the application, I get the following error message:
Error (1002) creating CGSWindow
Why is this happening??? What is CGSWindow, by the way?
Rainer
source share