Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IPhone: Change line spacing in UITextView?

I've been looking all over the 'net for information/examples...

I'm trying to change the line spacing of text inside a UITextView object to double spaced. I thought you could do it via Core Text, but haven't found a solution!

Any example code or information would be greatly appreciated! Thanks!

like image 400
Matt Gomes Avatar asked Sep 29 '10 17:09

Matt Gomes


1 Answers

You don't have to look all over the net. A look at the documentation for UITextView is sufficient to determine that changing the line spacing is not supported by that control.

With Core Text you have complete control over the layout of the text you draw, of course. But it would be a lot of work to rewrite a UITextView-like control from scratch.

like image 90
Ole Begemann Avatar answered Sep 20 '22 12:09

Ole Begemann