Length of text that can just fit into one screen without scrolling
Posted
by KailZhang
on Stack Overflow
See other posts from Stack Overflow
or by KailZhang
Published on 2010-05-05T07:25:08Z
Indexed on
2010/05/05
7:28 UTC
Read the original article
Hit count: 205
iphone
I find some iphone book apps have such feature:
One screen one page of text without scrolling. The text can just fit into the whole screen with linebreaks and indentations.
I'm curious of how to implement this. How could I decide the length of text that just fit into the screen. And also, given the whole text, I can calculate out the number of pages.
If this is not possible to be done on iPhone(runtime?), then is it possible to process the text before storing it in app? I mean I calculate how many pages I need(how to split the raw text), probably how many lines per page.
© Stack Overflow or respective owner