Re: boundingRectWithSize gives wrong size
Re: boundingRectWithSize gives wrong size
- Subject: Re: boundingRectWithSize gives wrong size
- From: Richard Charles via Cocoa-dev <email@hidden>
- Date: Wed, 28 Aug 2019 14:55:48 -0600
> On Aug 28, 2019, at 1:33 PM, Gabriel Zachmann via Cocoa-dev
> <email@hidden> wrote:
>
> I am trying to determine the size of a piece of text using
> boundingRectWithSize.
>
> The problem is that this method does not return the correct width. (The
> height seems to be about right.) Sometimes, the width is only a little bit
> too wide, sometimes it is much too wide.
I have had good results with CTLineGetTypographicBounds().
--Richard Charles
_______________________________________________
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