How do I position a subview in UIPageViewController using Auto Layout?
问题 I have a UIPageViewController subclass, and in its viewDidLoad I want to add a UILabel to its self.view . This works fine if I set its position using frames, but if I try to position it using Auto Layout, I get: * Assertion failure in -[_UIPageViewControllerContentView layoutSublayersOfLayer:], /SourceCache/UIKit_Sim/UIKit-2935.58/UIView.m:8742 How am I supposed to position this UILabel to show up in the UIPageViewController ? 回答1: This seems to be happening because UIPageViewController 's