On Wed, 18 Feb 2009, Dan Bron wrote:
>          charType myData         NB.  result could be ASCII, utf8, utf16, 
> utf32,
> whatever
>       utf8
>          
>          datatype chars myData   NB.  datat...@chars is always 'unicode'
>       unicode
>       
>          input -: (charType myData) charConvert chars myData  NB.  Tautology
>       1

You can auto-detect encoding with your charType but it does not always work.
My email assume encodings of income emails to be 
  BIG5:gb2312:iso-2022-jp:euc-jp:shift_jis:utf-8
so it can not detect russian.

However conversion between unicode and other encoding is straight
forward and reliable once you know the correct encoding. eg. the m2u
posted by kim for window or using libiconv.

-- 
regards,
====================================================
GPG key 1024D/4434BAB3 2008-08-24
gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
唐詩212 李商隱  無題二首之一
    來是空言去絕蹤  月斜樓上五更鐘  夢為遠別啼難喚  書被催成墨未濃
    蠟照半籠金翡翠  麝熏微度繡芙蓉  劉郎已恨蓬山遠  更隔蓬山一萬重
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to