1

when I click the debug view hierarchy in Xcode, it shows nothing and the console alert:

Assertion failure in -[UITextView _firstBaselineOffsetFromTop], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit/UIKit-3512.60.12/UITextView.m:1683

what confused me is that all my project just this viewController occur it.

It's my first time meeting this, could anyone give me some advice.

currarpickt
  • 2,290
  • 4
  • 24
  • 39
无夜之星辰
  • 5,426
  • 4
  • 25
  • 48

1 Answers1

2

From Assertion failure in UITextView _firstBaselineOffsetFromTop

Write below in your project.

For obj-C

@interface UITextView(MYTextView)

@end

@implementation UITextView (MYTextView)
- (void)_firstBaselineOffsetFromTop {

}

- (void)_baselineOffsetFromBottom {

}
@end

For swift

extension UITextView {
    func _firstBaselineOffsetFromTop() {
    }
    func _baselineOffsetFromBottom() {
    }
}
Community
  • 1
  • 1
yume
  • 36
  • 1