This article continues from the previous article. Earlier we saw how we can make iOS Apps without using the storyboard file. In this article we will explore how to implement Autolayout programmatically. We will continue from the previous article.
The code that I will be showing in the article will not be covering all the possible cases. The point of this article is to give you an idea on how to implement the different Autolayout solutions. Feel free to play around with the code to cover all the cases & situations.
Programmatic Constraints
We have 3 options when it comes to applying constraints programmatically:
StackViews
Layout Anchors
NSLayoutConstraints class
Visual Format Language (VFL)
Handling Size Classes in code
Handling Size classes in code is fairly easy. It is a simple question of overriding the correct function. We will look at this in greater detail when we cover the topic later in the article.
In the earlier article we had discussed how to share the iPhone screen on the project or how to record iPhone screen activities. In this article we are going to see how to use the built in feature of iOS 11 to do the same.
First we must add the button to do this to control centre. Open Settings > Control Centre> Customise Controls .
Tap on the ‘+’ button next to Screen Recording to add Screen Recording to the control centre. Close the Settings App.
Swipe up from the bottom of the screen to bring the control centre options.
Tap on the Screen record button. Tap the microphone audio button to record audio if you wish.
Tap the “Start Recording” button to start recording. To stop simply tap on the “Stop Recording” button.
The video is saved in the camera roll.
Third Party Applications
This feature is used to provide screen sharing capability via apps such as TeamViewer.
In this article we are going to look at how we can use the built in Application: QuickTime to record a screen or a movie. In fact, the videos that you are about to see in the article below were created using QuickTime.
A good reason to record the activity on the screen would be to create a visual step by step guide which can be distributed to employees in the organisation. For example, you can create a video to show employees how they can sign into their company’s email account and access it from their iPhone or Mac.
Recording your Mac’s screen
Follow the steps given below to record your Mac’s screen:
Open QuickTime Player
Click on File > New Screen Recording
You should see the window popping up.
From the drop down next to the Record button select the audio input & whether mouse clicks should be shown.
Click on the Record Button. You should see a dialog asking you whether you want to record a small area or a full screen.
The recording starts once the stop button in the menu bar becomes dark.
Click on the stop button to stop the recording.
Save the file that was created.
Recording your iPhone/iPad Screen
(Mirroring your iPhone Screen on the Projector)
The process of recording the iPhone/iPad screen is quite similar to recording your computer’s screen. The key thing to remember is to connect your iPhone/iPad to the Mac with the lightning cable.
Follow the steps given below to record your iPhone/iPad screen:
Open QuickTime Player
Click on File > New Movie Recording
You should see the window popping up.
From the drop down next to the Record button select the audio input & whether mouse clicks should be shown. The difference now is the fact that you get an extra option to choose the source.
Recording a Movie
Follow the steps given below to record a Movie on your Mac:
Open QuickTime Player
Click on File > New Movie Recording
You should see the window popping up.
From the drop down next to the Record button select the audio input. You can also select your camera source from here.
Click record to start recording & click on the stop button to stop recording.
Recording Audio
Follow the steps given below to record an Audio on your Mac:
Open QuickTime Player
Click on File > New Audio Recording
You should see the window popping up.
From the drop down next to the Record button select the audio input.
Click record to start recording and stop to stop recording.
Here is a quick video on how to perform the different tasks that we have seen above.