Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread Display Modes
Old Sep 10, 2010, 05:11 PM   #1
macrumors 6502a
Join Date: Dec 2009
Edit Window in Document Based Application

This is my first time making a document application and I am trying to set it so all the windows have an orange background. Here is my code:

 [window setBackgroundColor:[NSColor orangeColor]];
I get an error saying 'window' is undeclared. By the way I am putting this code in the Xcode generated MyDocument.m file. My question is how is the default window it gives you declared(the one that says your document contents here)? I know in a regular Cocoa application it is declared as window. What is it called in a document based application? Or how do I change the background of it programmatically?
Blakeasd is offline   0 Reply With Quote
Old Sep 10, 2010, 06:40 PM   #2
macrumors 68030
Catfish_Man's Avatar
Join Date: Sep 2001
Location: Portland, OR
Send a message via AIM to Catfish_Man
Document-based apps have more than one window; you'll need to access them via the window controllers for your documents.
Catfish_Man is offline   0 Reply With Quote

MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
Document based application, use folders (of any type) as documents printz Mac Programming 0 Oct 30, 2013 01:02 PM
text edit document Jennseay Mac OS X 10.7 Lion 0 Sep 15, 2013 08:11 PM
View based vs Window based application Vishwas Gagrani iPhone/iPad Programming 1 Oct 14, 2012 05:25 PM
Threading of Core Data in a document based application bitdoctor Mac Programming 0 Sep 25, 2012 01:30 AM
Package-based document trouble Starfox Mac Programming 1 Jun 7, 2012 02:59 AM

Forum Jump

All times are GMT -5. The time now is 04:52 AM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013,, LLC