as the title says i am trying to add padding-like behavior to a UITextView. The textview is generated when the view is pushed inside my navigation controller and the following c
Simply create an extension of UITextView using Container Edge Inset as following:
extension
UITextView
extension UITextView { func leftSpace() { self.textContainerInset = UIEdgeInsets(top: 4, left: 6, bottom: 4, right: 4) } }
and use it like:
let textView = UITextView() textView. leftSpace()