From: why the lucky stiff Date: 2005-07-01T06:42:05+09:00 Subject: Re: Escape sequences for unicode chars? Michael Schuerig wrote: > Thanks! Somehow I didn't expect this to work. Good that it does. I'm > using hex "\xe2\x80\xa6" instead as that's what the nice (unixoid) > unicode command line tool shows, among other things. module Kernel def u( str ) str.gsub(/U\+([0-9a-fA-F]{4,4})/u){["#$1".hex ].pack('U*')} end end >> u"U+2026" => "\342\200\246" >> "\xe2\x80\xa6" => "\342\200\246" _why