Re: unicode
by Lee Goddard other posts by this author
May 15 2002 5:18PM messages near this date
view in the new Beta List Site
Re: unicode
|
Re: unicode
To convert, try Unicode::String - availble as a PPM.
As to testing; should be the same when ord($chr)<127, but
above that you might be able to do something by testing
the ord (ie. ASCII value) of the character against a Unicode::String::chr
(ie character) of that value The latter function name may be
wrong: check its POD.
Then you make it into a PM for us all to use ;-)
lee
At 17:28 15/05/2002 +0200, Johan Lindstrom wrote:
> At 11:20 2002-05-15 -0400, Greg Sidelinger wrote:
> >Are there any easy ways to test and see if something is Unicode and then
> >convert it to something else like standard ascii.
>
> How about that for a coincidence? :)
> http://use.perl.org/~jplindstrom/journal/4855
>
> I think you need to know it's Unicode though, otherwise the chars > 127
> could be some other char (e.g. in Latin-1 or somesuch). Don't you know
> what encoding your input has?
>
> Caveat: I'm a Unicode amateur, someone else can probably give you a way
> better answer.
>
>
> /J
>
> -------- ------ ---- --- -- -- -- - - - - -
> Johan Lindström Sourcerer @ Boss Casinos johanl@[...].se
>
> Latest bookmark: "Failure To Refactor"
> http://www.perlmonks.org/index.pl?node_id=166614
> dmoz (1 of 5): /Computers/Programming/Languages/Perl
>
>
> _______________________________________________
> Perl-Win32-Users mailing list
> Perl-Win32-Users@[...].com
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Lee Goddard
perl -e "while(1){print rand> 0.5?chr 47:chr 92}"
_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Greg Sidelinger
Johan Lindstrom
Lee Goddard
c. church
|