I have a table cell containing a UITextView. The table is using automaticDimension for the cell height and the cell itself is formatted in a way that the UITextView can be a variable height.
The intention is that the textview and the cell should reisize as the user types and the text flows into additional lines. If I do nothing else, this doesn't happen.
If I add a UITextViewDelegate and call sizeToFit() on the textview whenever the text changes, and then reload the table cell, it does resize, but it does so in an extremely sloppy and unusable way. Specifically, the textview loses focus, the cursor disappears, and the text starts to render in odd ways with overlapping characters or graphics from surrounding elements.
What is the correct way to accomplish this?
Thanks, Frank