UITextView Paging Enabled Text Disabled

I use UITextView and turn on paging (both in IB and programmatically switching it on and off). There is a lot of text and when scrolling with a paging connection, sometimes the first and / or last line of the currently viewed text ends halfway in the field of view and half of them are visible at the bottom or top of the frame, so you can only see the top or top of the bottom half of this line of text. (I hope I explain correctly)

Does anyone know a way to make sure it prints correctly, so that there are no lines of text partially cut off?

A few notes 1. The font size is user-adjustable. 2. I tried setContentOffset, setContentInset, setContentSize and did not help (unless I use them incorrectly) 3. I use a txt file to populate a UITextView

Thanks in advance!

+5
source share
1 answer

UITextViewis a subclass UIScrollView. Therefore, I do not believe that it UITextViewactually supports paging, as it is a function UIScrollView. Could you take a step back and explain the ultimate goal, as this sounds like rendering NSStringin in UIScrollViewmay actually be what you want, instead UITextView.

0
source

All Articles