1 Replies - 2756 Views - Last Post: 30 July 2013 - 06:55 AM

#1 ry110891   User is offline

  • New D.I.C Head

Reputation: 2
  • View blog
  • Posts: 25
  • Joined: 24-May 12

Text running off page. How to end wtih ...

Posted 26 July 2013 - 02:11 PM

I was wondering if anyone knows how to go about fixing my issue. I have certain text that run off the page because the string i have in my char array is too big to fit on the screen. To solve this I want to end the string with three periods just before the end of the screen to symbolize the the text is continuous. If anybody knows how to do accomplish this advice is appreciated thanks.
Is This A Good Question/Topic? 0
  • +

Replies To: Text running off page. How to end wtih ...

#2 superkb10   User is offline

  • D.I.C Regular

Reputation: 29
  • View blog
  • Posts: 298
  • Joined: 27-November 11

Re: Text running off page. How to end wtih ...

Posted 30 July 2013 - 06:55 AM

Is there a reason you're not just putting three dots at the end of the char array where you see it would run off the screen? If it's because the text's position changes, I would recommend using Label.frame.origin.y to get the position of the top of the text, then, just find how high your text is (it's usually the font size), calculate how many lines should be shown, check in your char array through testing where the locations are for a new line, and just replace the end of that with a "...". If you're intending for the user to scroll the text, usually you wouldn't put a "..." at the end, because as long as the text ends a bit abruptly, most users will know to scroll down.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1