I've noticed on a few apps, the app (prior to login) begins with a tutorial screen. I know that UIPageViewController can be used to build a tutorial screen, but the format of these other app screens' seem to have a much more aesthetically pleasing "swipe to preview" functionality built in. They all look similar to this:
Is this done with a specific view controller that I'm not seeing? Or is it a Page View Controller embedded in a container in another view controller? I feel as though there's a simple way of doing this that I'm not seeing.
Related
I'm starting a new iOS project in Swift, and my experience programming native iOS applications is minimal, so please bear with me if I use some whacky terminology or overlook some simple solutions.
I'm looking to replicate a pattern in the Instagram application, as seen here:
Selected Tab
Swiping Transition
For those who don't use Instagram, what's essentially going on here is something like a UIPageViewController (with swiping functionality), but with the tabs on top indicating the selected page.
Like in Instagram, I'm planning to have this functionality within a child UIViewController of a UITabBarController (you can see the "main" tabs on the bottom).
What I started out doing was creating static tabs and adding left and right gesture recognizers to the child UIViewController, which would change the page and update the indicator of the selected page on the tabs.
This works but I'm not really loving the way it looks, nor the way it's written. I don't like the idea of needing 2 instances of the tabs, and that certainly doesn't seem to be the way Instagram is doing it, because as shown in the second image, the indicator slides between the tabs.
I've searched a fair bit, but all references to replicating Instagram patterns seem to be outdated and don't address this specific element. Like I said, though, I haven't been programming native iOS for very long (I'm an Android developer and have used Xamarin for iOS), so it's possible I'm just not using the right keywords.
I'd appreciate any help y'all can offer!
Thanks
I would like to implement a floating view into my iOS app. Something like the one in Apple´s stock mail app on iPad when you write a new mail or the one you see in some apps as introduction (with the ability to be a fullscreen view on iPhone). Unfortunately, I cannot find any tutorials (maybe because I´m not sure if they´re really called "floating views"?). Does anyone know a good tutorial or a simple code fragment? thx.
The Mail compose UI on iPad is an example of a view controller being shown as a modal view. You can get this style by presenting a view controller modally using either the PageSheet or FormSheet style.
You could simply place a UIView on top of your currently showing view. If you place it correctly you should get the desired effect. The animation likely comes from [UIView animateWithDuration... or some UIKitDynamics
Can an app delegate act the as the glue between all my UIViewControllers for the whole app?
I'm creating a mail client that has a navigation structure very much like sparrow (and fb etc). The first screen would be a login screen.. which would then lead to a UITableViewController that has the famous left menu button, which if clicked reveales other VC's underneath.
To make a long story short, right now it's my app delegate that's running the show.. it's the one that decides if to show the login screen if on first visit, or the default mailbox along with its subviews. If I get information from one subview, it hands off that info to the app delegate, which in turn passes it on to other view controllers.
Is this right from an MVC point of view? I know an app delegate is the first point of contact, it's what kicks off the application, but I haven't seen it used this extensively. I just want to make sure if I'm following iOS MVC best practices here.
It's not recommended, but it's perfectly legal to do that. I generally use a master view controller class and do most of the heavy lifting in that. Keep in mind that XCode will dump most of the auto generated code in the app delegate if you are using Core Data, so it can get a little difficult to navigate if you are using Core Data. It's really just a personal preference though. If it were me, I would still have the app delegate do the login screen vs. main screen logic, but put most of the app logic in a main screen controller.
I am working on an app in which there are several screens and each screen has the same layout, just different data passed in, then I want the user to be able to swipe from one screen to the next.
So far I got something working using the UIPageViewController project template using the transition style UIPageViewControllerTransitionStyleScroll. What I have done so far works ok, although its resource intensive because it instantiates a new view controller each time I swipe to a new page but I am loooking into working around that.
The thing I am concerned about is that it is not strictly a page application in the sense of ibooks so even though I am able to make it look like a scrolling app, using the transition style setting, I wonder if there is a reason why people seem to only use this template for book type apps, unless I am mistaken
Also there seems to be an alternative approach of using a UIScrollView and PageControl to do similar functionality
http://developer.apple.com/library/ios/#samplecode/PageControl/Introduction/Intro.html
I am not sure which approach is better to solve the problem I am trying to fix, so am looking for some feedback. Each page will need to be a separate instance of a view controller as there are several elements to display on each page.
Using UIScrollView is much more difficult. If you're targeting iOS 6 you should almost certainly use UIPageViewController. If you're targeting iOS 5 then UIPageViewController might not be perfect because the only page transition available is "scroll" which looks like a page flip.
If you're worried about the resource usage, you can reuse view controllers.
See the WWDC 2012 session 223:
https://developer.apple.com/videos/play/wwdc2012/223/
Just wondering if anyone have tried to replicate the transition that is used for presenting modal views in Gmail iOS? It looks darn gorgeous and refreshing from the pop up from bottom animation.
Pretty sure you're referring to the push-back transition when displaying the modal view controller? If so, then it's the one that the National Geographic Park Guides app first introduced and someone has released their replica of it over on Github. This one is only a partial screen modal, but could be modified to mimic the full view that the Gmail app does.
How about using this? Detailed animation, there is a need to develop a little more.
https://github.com/ucu072/HCPushBackAnimation
I created a UIViewController category to mimic this type of modal animation. It is called MFFadeBackModalAnimation. It wraps around the native API for presenting and dismissing view controllers so it should integrate well with your existing app.