使用自动布局的UITextView的UIScrollView中 [英] UITextView in UIScrollView using auto layout
问题描述
我有一个滚动视图,它有两个子视图:一个ImageView的和一个TextView。当在TextView的一切小文是好的,但,当TextView的内容是太大的TextView的高度,它不会扩展边界。代替此,它提供了我滚动TextView的。但我想滚动只scrollView.So我怎样才能让TextView中自动调整?
I have a scrollView, which has two subViews: an imageView and a textView. When there is a small text in the textView everything is fine,but , when the content of textView is too big for the height of textView, it doesn't expands the boundaries. Instead of this, it offers me to scroll the textView. But i want to scroll only the scrollView.So how can i make textView resize automatically?
我知道如何做到这一点没有自动布局,但我想知道如何使用自动布局做到这一点;
I know how to do it without auto layout, but i want to know how to do it with auto layout;
推荐答案
更新:我的回答是坏的。更好的办法是presented在滚动视图内滚动景观。
Update: My answer was bad. Better approach is presented in Scroll Views Inside Scroll Views.
这篇关于使用自动布局的UITextView的UIScrollView中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!