xhzengAIB / MessageDisplayKit

An IM App like WeChat App has to send text, pictures, audio, video, location messaging, managing local address book, share a circle of friends, drifting friends, shake a fun and more interesting features.
MIT License
4.26k stars 1.19k forks source link

TextView输入框弹跳 #207

Open codewpf opened 9 years ago

codewpf commented 9 years ago

在iOS7.0之后UITextView输入的时候会有弹跳,这个需要在didchange代理里面做判断

xhzengAIB commented 9 years ago

@ioswpf 你好!我错过了这个issue,请问有什么好的办法解决吗?

Hitooo commented 9 years ago

我遇到了这个问题,UITextView获得焦点之后,弹出键盘,然后NavigationBar被顶上去了,有什么办法解决

xhzengAIB commented 9 years ago

@ioswpf 你好! 这个问题好像是存在的,有办法解决吗?

codewpf commented 9 years ago

我这有两种方法 1、控制TextView的高度,根据文字的行高进行高度的变换。这个办法也有问题,达不到微信的的那种效果。

2、https://github.com/jaredsinclair/JTSTextView 这个库是根据scrollview实现的。我用着基本没什么问题,但是在选择文字的时候开头的光标的圆点会不消失,是个麻烦。

xhzengAIB commented 9 years ago

我发现了问题,就是当文本很长的时候会出现弹跳,你现在解决了这个问题了吗?

codewpf commented 9 years ago

还是没有解决这个问题,上面我提供了两个方法的呀!

xhzengAIB commented 9 years ago

你已经解决了吗?

codewpf commented 9 years ago

上面提到的1方法不能不跳动,但是会有一些后续的小问题。建议使用这个 2方法因为是别人写的所以问题我解决不了,就是全选的时候会出现bug

zyprosoft commented 9 years ago

跳动原因其实是这个://http://stackoverflow.com/questions/18826199/uitextview-contentsize-changes-and-nslayoutmanager-in-ios7/19113421#19113421

xhzengAIB commented 9 years ago

@zyprosoft 请问能否发送一个PR来解决这个问题呢?

MrReN commented 9 years ago

这个问题可以解决的

xhzengAIB commented 9 years ago

@MrReN 请问如何解决?

jinlongyu919 commented 7 years ago

你好 这个项目是怎么运行的啊 我这边打开都运行不了