HighlightTextView
需求
Swift 3.0 iOS 8.0+
安装
Carthage
HighlightTextView 通过 Carthage 提供。要安装它,只需将以下行添加到您的 Cartfile 中
github "yusayusa/HighlightTextView"
CocoaPods
待办事项
使用说明
let textView: UITextView
// set maximum character limit and background color, minimum character limit and background color
textView.setHighlight(
range: Range(uncheckedBounds: (lower: 20, upper: 50)),
minHighlightColor: UIColor.gray,
maxHighlightColor: UIColor.red
)
许可证
HighlightTextView遵循MIT许可协议。请阅读LICENSE文件获取更多信息。