Custom View not having Outlets?


Hi folks,
First off want to say that the book has been working well for me so far.

Just hit a problem in the this chapter where I a finding that the “BigLetterView”, being a custom view does not have any Outlets at all, so I cannot even get past setting it into the responder loop since it doesn’t have the “nextKeyView” Outlet. I did NOT create it as document based project either.

Do I assume I should be using a TextView?

Am running Xcode 4.2.1 on Lion 10.7.2 on a MacBook Pro.

Thanks in advance.


OK, Have now got it working.
It looks like until you have created the BigLetterView class h/m files you don’t get the Outlets.
However it will let me set the nextKeyView if I do it BEFORE renaming the Custom View to BigLetterView in the Identity Inspector.
Makes sense I guess since once you rename it to BigLetterView it doesn’t know the inheritance hierarchy for the class?
Anyway back to enjoying Cocoa.



Right, until you have created the BigLetterView header file, the Interface Builder editor doesn’t know what a BigLetterView is (or that it’s a subclass of NSView).