This is an demonstration of updating CAShapeLayer
as gesture changes in Objective-C.
Note, I also used IB_DESIGNABLE
view so that you can render (and customize the appearance) in Interface Builder storyboard. You don't have to do this, but it makes designing of user interfaces a little easier.
See https://stackoverflow.com/a/48407910/1271826.
This was developed in Objective-C on Xcode 9.2 for iOS 11.2. But, the basic ideas are equally applicable for different versions of Objective-C and iOS versions.
Copyright © 2018 Robert Ryan. All rights reserved.
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
--
6 February 2018