Dissappearing textField string value
Dissappearing textField string value
- Subject: Dissappearing textField string value
- From: Charlie Dickman <email@hidden>
- Date: Sun, 13 May 2012 22:36:54 -0400
Good people,
This one really has me stumped. Perhaps someone can help me out.
In my program is the code...
NSAttributedString *theAttributedString = [[NSAttributedString alloc ]
initWithString: possibleString
attributes: theAttributes];
PRINT_APPEND(@"\n%d (%d)...\n%@",
[theAttributedString retainCount],
[theAttributedString length],
theAttributedString);
[theSudokuTextField setAttributedStringValue: theAttributedString];
NSString *s = [theSudokuTextField stringValue];
assert([s length] != 0);
PRINT_APPEND looks like this
#define PRINT_APPEND(format, ...) [self printAppend: [NSString stringWithFormat: format, ##__VA_ARGS__]]
printAppend looks like this
- (void) printAppend: (NSString *) theNSString {
printf("%s", [theNSString UTF8String]);
}
This is what appears on the debug console
1 (29)...
2
5
7 8 {
NSFont = "\"BaskOldFace 9.00 pt. P [] (0x3687e20) fobj=0x511bf0, spc=2.25\"";
}Assertion failed: ([s length] != 0), function -[Controller updatePossibilitiesDisplay:], file /Users/Charlie/SudokuX III/Controller.m, line 1143.
What could possibly make the stringValue disappear like this?
Charlie Dickman
email@hidden
_______________________________________________
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