Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First page doesn't have padding and other UI tweaks applied to it, but all others do #126

Open
samheather opened this issue May 11, 2016 · 1 comment

Comments

@samheather
Copy link

samheather commented May 11, 2016

I have a OnboardingViewController with six OnboardingContentViewControllers. When I apply layout tweaks such as:

ovc.bodyFontSize = 26
ovc.titleFontSize = 36
ovc.iconSize = 350
ovc.underIconPadding = 100
ovc.underTitlePadding = 100
ovc.topPadding = 150

they are applied to the 2nd -> 6th page, but not the first. Screenshot from an iPad attached below.

My complete code for the OnboardingViewController is below: any ideas? Is this perhaps a known bug?

    var onboardingVC = OnboardingViewController(backgroundImage: UIImage(named: "onboardBackground"), contents: [firstPage, secondPage, thirdPage, fourthPage, fifthPage, sixthPage])

    // Configuration properties of the VC
    onboardingVC.shouldFadeTransitions = true
    onboardingVC.fadePageControlOnLastPage = false
    onboardingVC.shouldBlurBackground = true
    onboardingVC.shouldMaskBackground = false
    onboardingVC.allowSkipping = false
    onboardingVC.hidePageControl = false
    onboardingVC.swipingEnabled = false
    onboardingVC.bodyFontSize = 22
    onboardingVC.iconSize = 250
    onboardingVC.view.clipsToBounds = true // Stop bits been shown on pop

    if (iPad) {
        onboardingVC.bodyFontSize = 26
        onboardingVC.titleFontSize = 36
        onboardingVC.iconSize = 350
        onboardingVC.underIconPadding = 100
        onboardingVC.underTitlePadding = 100
        onboardingVC.topPadding = 150
    }

    onboardingVC = adjustOnboardingForScreenSizes(onboardingVC)

    // Push the Onboarding View Controller and flip the Status Bar Colour
    self.navigationController?.pushViewController(onboardingVC, animated: false)

Any ideas anybody?

@mamaral
Copy link
Owner

mamaral commented Jul 10, 2016

Is this still an issue with the most recent version?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants