Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

JohnGaby

macrumors newbie
Original poster
Nov 16, 2009
5
0
I am new to iPhone development (and to mac development in general). I am trying to figure out how to draw text in a custom view. I can use the function CGContextShowTextAtPoint to draw the text, but how do I get information about the text extent so I can center or right justify the string?

Thanks
 

JohnGaby

macrumors newbie
Original poster
Nov 16, 2009
5
0
Thanks for the reply. I am aware of UILabel, but I would rather not have to create a label for each piece of text that I wish to display. I was hoping that there would be a mechanism where I could output the text directly to the device context.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.