• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Smooth resizing of a text field
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Smooth resizing of a text field


  • Subject: Re: Smooth resizing of a text field
  • From: Fritz Anderson <email@hidden>
  • Date: Wed, 20 Jul 2011 15:12:02 -0500

On 20 Jul 2011, at 2:30 PM, Gabriel Roth wrote:

> My next thought was to convert the text field into an image (at some large
> font size) and then scale the image up and down as the slider moves. But I
> can't figure out how to create an image from a text field (or otherwise
> generate an image of a string of text in a given font).

That's the sort of thing that's profitable to look for in the OmniGroup frameworks (open source, free distribution with OmniGroup's disclaimer of liability, but see their license for the authoritative details).

A couple of minutes' search turned up drawCenteredShrinkingToFitInRect: in NSAttributedString-OAExtensions. I don't think it's on-point for what you're looking for, but you may be able to derive a technique.

	— F

_______________________________________________

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

  • Follow-Ups:
    • Re: Smooth resizing of a text field
      • From: Gabriel Roth <email@hidden>
References: 
 >Smooth resizing of a text field (From: Gabriel Roth <email@hidden>)

  • Prev by Date: Number Strings to NSDecimalNumber
  • Next by Date: [Q] Directory & File enumeration order?
  • Previous by thread: Smooth resizing of a text field
  • Next by thread: Re: Smooth resizing of a text field
  • Index(es):
    • Date
    • Thread