• 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
Debugging NSTextField categories
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Debugging NSTextField categories


  • Subject: Debugging NSTextField categories
  • From: Mark Dawson <email@hidden>
  • Date: Fri, 13 May 2005 17:01:30 -0700

I've added a category to NSTextField; it has worked fine for months. However, one text field that I added returns the previous value when that field's action is called. I'm not sure how to debug this. I DID double (triple) check that the correct outlet is attached to that text field. I DO have a formatter (mine) attached to the text field, but as far as I can tell, it is returning the correct string. I'm not sure how to debug "bad" NSTextField return values. Any suggestions would be appreciated

Here is the category code--when I step into "[self stringValue]", I see the previous value (i.e., the value before that was in the text field BEFORE I started typing and pressed the enter key)

x = [myNewTextOutletField readFieldAsDimension];

- (unsigned long)readFieldAsDimension
{
DimensionFormatter *aFormatter = [self formatter];
if (aFormatter && [aFormatter isMemberOfClass:[DimensionFormatter class]])
{
return [aFormatter readFormatValueAsDimension: [self stringValue]];
}
return 0; // error
}
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Debugging NSTextField categories
      • From: Mark Dawson <email@hidden>
  • Prev by Date: Re: Data model object sizes...
  • Next by Date: SQLite3 symbols undefined?
  • Previous by thread: iSync and Core Data
  • Next by thread: Re: Debugging NSTextField categories
  • Index(es):
    • Date
    • Thread