The idea of walkthroughs for apps has been around since the dawn of the App Store, but it always required extensive work and design so as to not look like a ‘fake’ app. This library makes creating these walkthroughs much easier than ever before:
The “ios controls library” is a simple library that helps you build custom walkthroughs for iOS apps.
What is BWWalkthrough, and how does it work?
BWWalkthrough (BWWT) is a class that aids in the creation of walkthroughs for iOS applications. It differs from other comparable classes in that there is no fixed template; BWWT is just a layer that sits on top of your controllers and provides you total choice over how your views are designed.
Here’s a sneak peek at the video. On ThinkAndBuild, there is a dedicated tutorial.
The class has a series of pre-built animations that are applied to the subviews of each page automatically. You may simply replace the animations in this set with your own.
BWWT is divided into two categories: The Master is BWWalkthroughViewController (or Container). It depicts the walkthrough and includes UI elements that are common to all Pages (like UIButtons and UIPageControl).
Every Page that will be presented with the walkthrough within the Master is defined by BWWalkthroughPageViewController.
What isn’t it?
BWWT is neither a copy-paste-and-it-works class or a pre-made tutorial template. BWWT is not the appropriate solution if you require a simple no-configuration tutorial.
Note: IBOutlets and Carthage have a known problem that prevents Outlets from operating properly. I’ve seen similar reports for other projects as well. My advice is to follow the manual installation instructions since it’s as simple as dragging and dropping two files into your project. I understand you won’t be able to update the library automatically if you go that approach… However, for a project like BWWalkthrough, IBOutlets are required.
CocoaPods are a great way to get started.
BWWalkthrough may be found on CocoaPods. Simply add the following line to your Podfile to install it:
Carthage is a city in Africa.
Add the following line to your Cartfile:
“ariok/BWWalkthrough” on github
To create the framework, run carthage update and drag BWWalkthrough.framework into your Xcode project.
Swift Package Manager is a program that allows you to manage your packages.
/ swift-tools-version:5.0 import PackageDescription let package = Package(name: “YourTestProject”, platforms: [.iOS(.v10),], dependencies: [.package(url: “https://github.com/ariok/BWWalkthrough/.git”, from: “4.0.1”)], targets: [.target(name: “YourTestProject”, dependencies: [“BWWalkthrough”)], targets: [.target(name: “YourT
Then import BWWalkthrough anywhere it’s required.
Using Swift Package Manager to add it to an existing iOS project
- Go to File > Swift Packages > Add Package Dependency in Xcode 11.
- Copy and paste the following URL into your browser: https://github.com/ariok/BWWalkthrough
- Select the project goal by clicking next.
Please check the following websites if you have any doubts:
How to Make Use of
Putting Together Swift Packages
After you’ve successfully downloaded the package and installed it to your project, all you have to do now is import BWWalkthrough to enjoy all of its features.
In your project, include the BWWalkthrough/BWWalkthroughViewController.swift and BWWalkthrough/BWWalkthroughPageViewController.swift files.
What is the best way to utilize it?
Create a Master Plan
In the Storyboard, create a new controller with the class BWWalkthroughViewController. This is the master controller to which all of the pages will be connected.
You may add all of the items that must be visible across all of the Pages here.
UIPageControl (pageControl), UIButton to close/skip the tour (closeButton), and UIButtons to go to the next and previous page are four prebuilt IBOutlets that you may connect to your components to get some common behavior (nextButton, prevButton). Simply create your UI components and attach them to the Master controller’s outlets to take benefit of these IBOutlets.
Organize the Pages
In the Storyboard, create a new controller and name it BWWalkthroughPageViewController. Define your points of view as you see fit.
Connect the Master to the Pages
An example of how to construct a tour receiving data from a dedicated Storyboard is shown below:
Let stb = UIStoryboard = get view controllers and create the walkthrough (name: “Walkthrough”, bundle: nil) let stb = walkthrough as BWWalkthrough, instantiateViewControllerWithIdentifier(“Master”) Let page one = stb in ViewController. page two = stb, instantiateViewControllerWithIdentifier(“page1”) as UIViewController page three = stb, instantiateViewControllerWithIdentifier(“page2”) as UIViewController as UIViewController, instantiateViewControllerWithIdentifier(“page3”) / Join the pages to the main walkthrough. self-walkthrough = delegate walkthrough(viewController:page one) walkthrough(viewController:page two) add(viewController:page three)
Animations that have already been created
Without writing a single line of code, you can add animations to your website. You just create a new Page with its subviews and use the runtime parameter Key: animationType, type: String to specify an animation style using IB. The BWWalkthrough animates your views based on the animation style you choose.
Linear, Curve, Zoom, and InOut are the available values for animationsType at the moment (WIP!). The runtime parameter key: speed type:CGPoint must be used to change the animation speed on the X and Y axes, while the runtime argument key: speedVariance type: CGPoint adds a speed variation to the page’s subviews based on the hierarchy position.
Example Assume we’ve specified the following runtime parameters for one of the Pages:
- “Linear” animation type
- 0 and 1 are the speeds.
- Variance of speed: 0,2
Depending on speedVariance, the Page’s subviews will conduct a linear animation that adds speed to the frontend parts. So, if we have three subviews, each view’s pace will be:
- view 0 0 1 + 2
The notorious parallax effect was created.
Views should be excluded from automated animations.
For certain subviews, you may need to avoid animations. You may give a list of views’ tags that you don’t want to animate to block them from being included in the automated BWWalkthrough animations. The staticTags Inspectable property (available from version 0.6) takes a String containing a list of these tags separated by commas (“1,3,9”). The automated animations no longer include the views specified by those tags.
Animations that are unique to you
Using the protocol BWWalkthroughPage, each page of the walkthrough gets information about its normalized offset position, allowing you to expand the prebuilt animations by adding your own super-custom-shiny-woahTM animations based on this value (here is a simple example)
walkthroughDidScroll is a function that allows you to see how far you’ve progressed through the (position: CGFloat, offset: CGFloat) titleLabel?.layer.transform = CATransform3DRotate(tr, CGFloat(M PI)*2 * (1.0 – offset), 1, 1, 1) var tr = CATransform3DIdentity tr.m34 = -1/500.0
The BWWalkthroughViewControllerDelegate protocol specifies a number of helpful ways for gaining additional control over the Walkthrough flow.
protocol @objc BWWalkthroughViewControllerDelegate @objc optional func walkthroughCloseButtonPressed() @objc optional func walkthroughNextButtonPressed() @objc optional func walkthroughAllButtonPressed() @objc optional func walkthroughAllButtonPressed() @objc optional func walkthroughAllButtonPressed() @objc optional func walkthroughAllButtonPressed() @ @objc optional func walkthroughPageDidChange(pageNumber:Int) PrevButtonPressed()
The “swift alert library” is a simple library that helps you build custom walkthroughs for iOS App. It provides three methods: one for displaying an alert, one to dismiss the alert and one to show a progress indicator.
- coach marks ios swift
- ios network library
- onboarding swift github
- awesome ios
- ios camera github