textView.bounds.size.height = textView.contentSize.height
会导致原有对textView的上下约束被突破,并且是两头延伸,如何能让textView只向上变大,不向下变大呢,另外有什么方法能让toolBar和textView一起变大和缩小呢?
PHP中文网2017-04-17 17:38:05
You need to modify the frame's
origin.y=the coordinates of the bottom you want - the height of the text
and
size.height=the height of the text..
Not just size..the meaning of layout frame. .