Re: Inserting Special Characters into a String
Re: Inserting Special Characters into a String
- Subject: Re: Inserting Special Characters into a String
- From: Ian was here <email@hidden>
- Date: Mon, 11 Jul 2005 09:56:05 -0700 (PDT)
Thanks, that works! One final question on this
subject, if I may. The Special Character Palette
doesn't seem to give decimal or hex values for any of
the characters, and my googling efforts haven't
yielded much. Do you know of any websites in
particular that may have the entire special character
map?
Thanks again.
--- James Housley <email@hidden> wrote:
> Ian was here wrote:
> > Does anyone know of a way of inserting non-ascii
> > characters into a string. I've tried several ways
> and
> > keep getting compiler warnings. An NSTextView
> handles
> > special characters nicely, but my attributed
> string
> > and character arrays don't.
> >
> >
> >
> > char checkChar = '?';
> > char bulletChar = '';
> >
> > or
> >
> > NSAttributedString *checkChar =
> [[[NSAttributedString
> > alloc]initWithString:@"?"];
> > NSAttributedString *bulletChar =
> [[[NSAttributedString
> > alloc] initWithString:@""] ;
>
> This has been covered many times in the list, but
> here is the short answer.
>
> 1. With .strings file in your bundle -- not
> practical for only a few
> special characters.
>
> 2. Using stringWithFormat: -- easy for special
> characters in a few places.
>
> [NSString stringWithFormat"@%C something starting
> with a bullet", 2022]
>
> Jim
>
> --
> /"\ ASCII Ribbon Campaign .
> \ / - NO HTML/RTF in e-mail .
> X - NO Word docs in e-mail .
> / \
>
-----------------------------------------------------------------
> email@hidden http://www.FreeBSD.org The
> Power to Serve
> email@hidden http://www.TheHousleys.net
>
---------------------------------------------------------------------
> If a million people say a foolish thing, it is still
> a foolish thing.
> -- Anatole France [Jacques Anatole Thibault]
> (1844-1924)
>
__________________________________
Yahoo! Mail
Stay connected, organized, and protected. Take the tour:
http://tour.mail.yahoo.com/mailtour.html
_______________________________________________
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