[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

xosd and encoding

B.

1/29/2006 6:03:00 PM

Hello everybody,

I started playing with xosd but I encountered some problems with some
characters :

----

require "xosd"

$KCODE="UTF8"

osd = Xosd.new(2)
osd.font = "-*-*-*-*-*-*-30-*-*-*-*-*-*-*"
osd.color = "blue"
osd.align = "right"
osd.valign = "bottom"
osd.timeout = 3

osd.puts "Début" # "begin" in French

-----

If I run this script through irb (1.8), everything works properly.
If I run this script through ruby (1.8), the OSD displays every character
until it meets the first odd character then stops.

I am a very beginner in ruby, so does anyone have any idea ?

(I found the "$KCODE="UTF8"" on the Internet but without it, the results are
the same...)

Thank you

--
B.