should not be the same? oldprint = print require"wx" print=oldprint local str = "" for i=0,127 do str = str .. string.char(i) end
strwx = wx.wxString(str)--:ToUTF8()--:GetData() strwx2 = tostring(strwx) for i=1,#str do io.write(tostring(str:byte(i))) end print("\n") for i=1,#strwx2 do io.write(tostring(strwx2:byte(i))) end ----- Original Message ----- From: "Victor Bombi" <son...@telefonica.net> To: <wxlua-users@lists.sourceforge.net> Sent: Sunday, March 01, 2015 11:56 AM Subject: Re: [wxlua-users] wxString::ToAscii > local _text = "" > for i=1,127 do > _text = _text .. string.char(i) .. string.format(" represents %4d\r\n",i) > end > editor:AddText(wx.wxString(_text):ToUTF8()) > > only show caracters from 1 to 127 (fails with i=0,255) > > With Notepad plus I can convert it (i=0,255) to UTF save to a file and if > I > open this file in wxlua it shows all caracters in wxStyledTextCtrl > why I can do the conversion with wx.wxString(_text):ToUTF8() > > best > victor > > ----- Original Message ----- > From: "Victor Bombi" <son...@telefonica.net> > To: <wxlua-users@lists.sourceforge.net> > Sent: Saturday, February 28, 2015 1:58 PM > Subject: [wxlua-users] wxString::ToAscii > > >> Hello, >> >> is wxString::ToAscii implemented? >> >> victor >> >> ------------------------------------------------------------------------------ >> Dive into the World of Parallel Programming The Go Parallel Website, >> sponsored >> by Intel and developed in partnership with Slashdot Media, is your hub >> for >> all >> things parallel software development, from weekly thought leadership >> blogs >> to >> news, videos, case studies, tutorials and more. Take a look and join the >> conversation now. http://goparallel.sourceforge.net/ >> _______________________________________________ >> wxlua-users mailing list >> wxlua-users@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/wxlua-users > > > ------------------------------------------------------------------------------ > Dive into the World of Parallel Programming The Go Parallel Website, > sponsored > by Intel and developed in partnership with Slashdot Media, is your hub for > all > things parallel software development, from weekly thought leadership blogs > to > news, videos, case studies, tutorials and more. Take a look and join the > conversation now. http://goparallel.sourceforge.net/ > _______________________________________________ > wxlua-users mailing list > wxlua-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wxlua-users ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ wxlua-users mailing list wxlua-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wxlua-users