I am making an application that is a tab-view controller. For the first tab, I have a UIPageViewController that is scrolling through pictures. Everything works properly, except for that the picture is not showing full screen. I have constraints set up for the image view to cover the whole view controller but when it gets loaded into the page view, it doesn't cover all the way to the bottom. The image gets cut off by the scrolling dot indicators and then it is just white.
I'm sure it is simple, but is there a way that the images will cover the full screen like I have the constraints set up to do?
There's quite a simple solution for this problem on that page: http://tunesoftware.com/?p=3363
It is done by overriding the viewDidLayoutSubviews method of UIPageViewController and basically doing two things:
Here's the code he provides (in case the link gets broken):
All you have to do after that, is:
Cheers, Joe
Here's the Objective-C version. Create a new class (2 files):
(1) BasePageViewController.h extending UIPageViewController
(2) BasePageViewController.m containing
viewDidLayoutSubviews
override