In the image. Comments has a textview that has text overflown to below 3 cells . Ideally that should not happen.
I have a tableview with custom cells as xib files and some custom cells are subviews. Please let me know how to add auto layout for this subviews or xib's.
I read many posts they suggested.below code. But it doesn't work.
Please suggest a solution. Thank you.
它将起作用,但是每次输入新字符时都需要更新高度,因此,在cellForRow
,添加textview.delegate = self
,在textViewDidChange
,执行tableView.beginUpdate()
和tableView.endUpdate()
单元格高度将正确更新
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.