Top "Sizewithfont" questions

Replacement for deprecated -sizeWithFont:constrainedToSize:lineBreakMode: in iOS 7?

In iOS 7, the method: - (CGSize)sizeWithFont:(UIFont *)font constrainedToSize:(CGSize)size lineBreakMode:(NSLineBreakMode)lineBreakMode and the method: - (CGSize)…

ios iphone ios7 nsstring sizewithfont
Convert CGSize to CGFloat and use that to size a RoundRectButton

I'm trying to find the physical pixel size of a string of text. I then want to use this size …

iphone objective-c strlen string-length sizewithfont
IOS 7 sizeWithFont Deprecated

I cannot seem to replace the deprecated sizeWithFont with boundingRecWithSize correctly. I scoured through all the answers and stayed up …

ios7 deprecated sizewithfont
Get the NSString height

I have an NSString, and I want to know its height to create an appropriate UILabel. Doing this NSString *string = @"…

ios iphone nsstring uilabel sizewithfont
iOS 7 - UITextView size font to fit all text into view (no scroll)

I am trying to find a non-deprecated method to size the font of a textview down so that all text …

ios7 resize uitextview sizewithfont
Check if there is an emoji contained in a string

I am getting the text size of a string with this textSize = [[tempDict valueForKeyPath:@"caption.text"] sizeWithFont:[UIFont systemFontOfSize:12] constrainedToSize:…

ios objective-c emoji emoticons sizewithfont
UILineBreakMode Vs NSLineBreakMode

I see some UIStringDrawing methods have been updated to use NSLineBreakMode instead of UILineBreakMode in iOS 6.0: E.g. - (CGSize)…

iphone ios nsstring ios6 sizewithfont
Resize CATextLayer to fit text on iOS

All my research so far seems to indicate it is not possible to do this accurately. The only two options …

ios4 sizewithfont catextlayer
sizewithattributes not returning correct size

I am tring to calculate the height of text labels in uitableview cells. After seeing that sizewithfont was deprecated with …

ios objective-c cocoa-touch uilabel sizewithfont
NSString font size specific to frame width

I am using drawRect for a text display, calling NSString. I am trying to implement using sizeWithFont to auto resizing …

objective-c nsstring drawrect sizewithfont