Re: iOS: String Drawing
Re: iOS: String Drawing
- Subject: Re: iOS: String Drawing
- From: David Duncan <email@hidden>
- Date: Tue, 12 Jul 2011 08:37:49 -0700
On Jul 11, 2011, at 11:49 PM, Development wrote:
> CGSize newSize = rect.size;
> CGSize imgSize = [self.text sizeWithFont:self.font];
> imgSize.width +=6; //this does nothing
> //everything below adjusts for the shadow which is a flipping train wreck of its own.
> CGPoint p;
> CGFloat x=0.0,y=spread;
Just for the record, the likely reason why this does nothing is because the rect you specify to draw the text into is still going to be clipped by the width of the UILabel – so if the label is X points wide, it really doesn't help to ask to draw into a rectangle X+6 points wide – you need the label to be X+6 points wide.
--
David Duncan
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden