WTReTextField icon indicating copy to clipboard operation
WTReTextField copied to clipboard

How to set text to WTReTextField?

Open ApesTalk opened this issue 8 years ago • 1 comments

Hello, I am using WTReTextField in my project. I want to call setText: method and let it show a formatted string when WTReTextField is appear, so i overrided the WTReTextField's setText: method like this:

-(void)setText:(NSString *)text

{

[super setText:text];

[self formatInput:self];

}

However, when i running on iOS7 device, it crashed with information:

Auto Layout still required after executing -layoutSubviews. WTReTextField's implementation of -layoutSubviews needs to call super.

(null)

How can i fix it? Thanks in advance. ps: I use Masonry layout.

ApesTalk avatar Dec 26 '16 06:12 ApesTalk

I found when i add some subView on WTReTextField and use the Masonry layout, it will crash immediately on iOS7 device. After i remove all WTReTextField's subView, it works well.

ApesTalk avatar Dec 26 '16 09:12 ApesTalk