views:

29

answers:

1

Hi,

I have one line of text that is too long to be displayed in one single line in a UILabel, so I switched to a UITextView. I wanted to display that text still in one line, and be able to scroll horizontally, but instead, the UITextView will wrap the text into multiple lines, and allow me to scroll vertically. So, for the text "This is a very very long line", instead of displaying it like "This is a ", and then if scrolled horizontally, it would display the rest of it, it actually displays it like "This is a \n very very long \n line". How can I get the behavior I want?

Thanks, Mihai

+2  A: 

If you want that behavior you should place the label inside a scrollview. That's the only way you'll be able to scroll a label in any direction.

Merrimack
Thanks for the response!
Mihai Fonoage