Re: how to print attributed strings to output (using NSLog? or otherwise)
Re: how to print attributed strings to output (using NSLog? or otherwise)
- Subject: Re: how to print attributed strings to output (using NSLog? or otherwise)
- From: "Chase" <email@hidden>
- Date: Fri, 20 Jul 2007 20:25:30 +0000
That keeps the app from throwing an error and it does print the text,
but it strips off the attributes. I'm trying to figure out how to
print it **with** the attributes.
In other words, I want to see the text printed in red in the xcode
output window. I know it's possible, because I've seen red output
before.... I just can't remember what I called or did that caused red
text to be printed there. Although, whatever it was, it may have been
just using ncurses, which doesn't help me. I need to ensure that the
attributes are getting set properly on these various attributed strings
**before** building the UI that will eventually display them.
if there's no way to do it, i'll just print them into a dummy text
field for testing. no biggie. just thought it would be nice to print
them to the output window for now -- before i start building the ui.
Any ideas?
- chase
On July 20, 2007, John Stiles wrote:
NSLog( @"%@", [myAttrString string] );
On Jul 20, 2007, at 11:26 AM, Chase wrote:
if I create an attributed string and set its color to red, how can
i print this into the output pane in xcode?
i tried using NSLog(), but i get the following error at runtime:
2007-07-20 13:11:10.527 TestApp[418] *** -
[NSConcreteAttributedString
_encodingCantBeStoredInEightBitCFString]: selector not recognized
[self = 0x3a4940]
2007-07-20 13:11:10.527 TestApp[418] Exception raised during
posting of notification. Ignored. exception: *** -
[NSConcreteAttributedString
_encodingCantBeStoredInEightBitCFString]: selector not recognized
[self = 0x3a4940]
isn't there some way to do this?
thanks.
- chase
_______________________________________________
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:
40blizzard.com
This email sent to 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