I want to use Chinese characters in wxRuby,like this:
Wx::Button.new(@panel,-1,‘Chinese characters wanted to be placed’)
also in Chinese is:
Wx::Button.new(@panel,-1,‘汉嗒)
but I get an empty button…
how can I do?
thanks
I want to use Chinese characters in wxRuby,like this:
Wx::Button.new(@panel,-1,‘Chinese characters wanted to be placed’)
also in Chinese is:
Wx::Button.new(@panel,-1,‘汉嗒)
but I get an empty button…
how can I do?
thanks
On 3/31/07, yang cao [email protected] wrote:
This works for me.
I cut this out of an old program I was trying.
Button.new(panel, -1, “Öйú”, Point.new(10,125), Size.new(100,25))
Harry
–
http://www.kakueki.com/ruby/list.html
Japanese Ruby List Subjects in English
yang cao wrote:
I want to use Chinese characters in wxRuby,like this:
Wx::Button.new(@panel,-1,‘Chinese characters wanted to be placed’)
also in Chinese is:
Wx::Button.new(@panel,-1,‘汉嗒)
Assuming you’re using wxruby2, which you should be, ensure that your
script is in UTF8 encoding, and that you have $KCODE = ‘u’ at the top of
it.
Have a look at the demo samples/text/unicode.rb which demonstrates the
use of controls with labels and content in numerous different scripts
including Chinese.
The wxruby-users mailing list is a good place for any questions about
the toolkit:
http://rubyforge.org/mail/?group_id=35
alex
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs