开发者

Interface Builder layout ViewController with its own nib

I would like to be able to decide where a sub view is placed, when that view is controlled by its own view controller. This happens frequently on th开发者_开发百科e iPad when you have a semi-complicated view that doesn't fill the entire screen.

So, imagine that I want the sub view controller's nib to decide its own width, components, connections, etc, while the parent nib would decide where that view/nib would be placed.

I'd really like to lay it out visually instead of programatically. How can I?


Create a view in the parent nib. Connect it to a "subViewContainer" outlet. When you add the SubViewController, add its view to the container instead of self.view.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜