Thanks all for the insightful responses. In my case I am using a monospaced font, and everything looks pretty square. The thing I did wrong as it turned out was that I had a little padding on the top, making my CTView to slightly shift down, and therefore making the final string disappear.
My code looks like this now: CGSize frameSize = CTFramesetterSuggestFrameSizeWithConstraints(framesetter, CFRangeMake(0, 0), NULL, CGSizeMake(self.bounds.size.width, CGFLOAT_MAX), &fitRange); self.frame = CGRectMake(self.frame.origin.x, self.frame.origin.y, self.frame.size.width, frameSize.height + PADDING_TOP); <<=== correction for padding Cheers, - Koen. On Fri, May 17, 2013 at 5:42 PM, Quincey Morris < quinceymor...@rivergatesoftware.com> wrote: > On May 17, 2013, at 11:20 , Robert Vojta <rob...@tapmates.com> wrote: > > Height was wrong even if returned width <= constrained width. > > > Once I took proper account of the returned width, I got no more "wrong" > heights. > > However, IIRC, there was a separate issue that fractional line heights > didn't work correctly. Maybe you ran into that problem as well. > > _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com