For iOS what I do is use sizeWithFont:minFontSize:actualFontSize:forWidth: on 
NSString. What it does is gives you a font size that will fit the entire string 
within the width you specify given some constraints such as a minimum font size.


Jason

On 26 Oct 2010, at 15:29, Alexander Cohen wrote:

> Hi,
> 
> I have a specific layout that has known font sizes for certain page 
> dimensions. I need to take that layout and resize it to fit it in multiple 
> different places in my app. I can't just apply that resize ratio to the 
> fonts, it just does not work. Is there a known way in cocoa to figure out the 
> correct ratio for a font when resizing it so it fits within the rest of my 
> layout and gives me same look but resized.
> 
> I could just create an image and resize that and display it in a ImageView 
> but this seems to me like a waste of resources especially when ported to iOS.
> 
> Any help appreciated,
> 
> thx
> AC_______________________________________________
> 
> Cocoa-dev mailing list ([email protected])
> 
> 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:
> http://lists.apple.com/mailman/options/cocoa-dev/jason%40bookshelfapps.com
> 
> This email sent to [email protected]

_______________________________________________

Cocoa-dev mailing list ([email protected])

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to