• 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: NSTextField width detection
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTextField width detection


  • Subject: Re: NSTextField width detection
  • From: Terrence Asselin <email@hidden>
  • Date: Mon, 21 Oct 2002 10:21:56 -0500

On Sunday, October 6, 2002, at 01:14 PM, Jeremy Jurksztowicz wrote:

Hello,

After searching the archives and the internet I am still having trouble with this.
I would like to know how to find out how much of a string an NSTextField of
fixed size can hold.

I'm working on the same problem right now. There are apparently three ways of doing this, one of which is deprecated. Check this link for a previous post that has examples:

<http://cocoa.mamasam.com/MACOSXDEV/2002/06/1/36762.php>


Like Piers Walter, I'm seeing that the widths reported don't seem to match reality. I'm using calls to NSString Addition's 'sizeWithAttributes:', but the actual width seems to be wider than is reported.

Has anyone else been seeing this? It may be time for Radar.

--Terrence.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: How to control cell tabbing in an NSTableView ?
  • Next by Date: Re: Rename files containing a slash
  • Previous by thread: NSTextField width detection
  • Next by thread: [Q] Using fonts in NSTextView
  • Index(es):
    • Date
    • Thread