Created
August 2, 2017 12:45
-
-
Save michaelevensen/00376398d8e5dc4712595840ce18e69b to your computer and use it in GitHub Desktop.
UITextView IBDesignable for removing inner padding
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@IBDesignable class UITextViewFixed: UITextView { | |
override func layoutSubviews() { | |
super.layoutSubviews() | |
setup() | |
} | |
func setup() { | |
textContainerInset = UIEdgeInsets.zero | |
textContainer.lineFragmentPadding = 0 | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment