On Fri, May 23, 2008 at 12:33 PM, vince <[EMAIL PROTECTED]> wrote: > How do I set my document based application to omit the filename reference at > the top of each opened document window?
It sounds like you need a little more education about how this works. NSDocument has a window outlet, but the document itself doesn't manage the window(s). Instead, it creates one or more NSWindowController objects. Now, in the simple case, you override -[NSDocument windowNibName] and NSDocument takes care of creating an NSWindowController for you. NSWindowController has some special logic for dealing with document-based applications, including the method -synchronizeWindowTitleWithDocumentName, which as its name implies is responsible for deciding whether to replace the window title with the result of -[NSWindowController windowTitleForDocumentDisplayName:]. By default, -[NSWindowController synchronizeWindowTitleWithDocumentName] returns YES. In your case, you will want to subclass NSWindowController and override this method to return NO. That means that you can no longer take advantage of NSDocument's default controller creation, of course; you will need to instead override -[NSDocument makeWindowControllers] to instantiate your custom window controller instead. HTH, --Kyle Sluder _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]