CLCascade icon indicating copy to clipboard operation
CLCascade copied to clipboard

Wide Views from Nibs

Open jeffmcfadden opened this issue 14 years ago • 2 comments

How do you get a wide view to load from a Nib?

In CLViewController::loadView the view is set as Nib object 0. But the default viewSize property is CLViewSizeNormal, and it's a read only property, so you can't set it after the view has been pulled out of the nib.

Am I missing something or does this functionality not exist?

jeffmcfadden avatar Nov 02 '11 20:11 jeffmcfadden

And yes, a solution is to subclass CLSegmentedView and override initWithCoder, but this seems lame.

jeffmcfadden avatar Nov 02 '11 21:11 jeffmcfadden

use this method:

  • (id) initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil size:(CLViewSize)size;

emilwojtaszek avatar Nov 05 '11 12:11 emilwojtaszek