Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

R3 unicode output?

 [1/7] from: aloysius::prayitno::gmail::com at: 7-Apr-2009 16:20

Hi all, I'm new to rebol, I've been using SciTE as editor, and configured that properly to show the output to the output window. That worked perfectly for rebol 2. For example the script REBOL [] probe "testme" will output the following in the output window if I hit the Go button in SciTe:
>"C:\Program Files\rebol\view\rebol.exe" "-w"
C:\Users\awi\Documents\Rebol\test2.r testme
>Exit code: 0
But with R3, it looks like rebol now outputs unicode, which is not understandable by SciTE, even though I already set the output window to use UTF (*output* Here is the output of R3 for the same code:
>"C:\Users\awi\Documents\Rebol\r3.exe" "-q"
C:\Users\awi\Documents\Rebol\test.r3 NULtNULeNULsNUL
>Exit code: 0
Is there someone also using SciTE who can help me resolve this? Or does somebody know any editor which can show the output correctly? Thanks, Awi

 [2/7] from: moliad::gmail::com at: 14-Apr-2009 13:24

I am by no means an expert on R3, but maybe you need to use quit with a return value?. in R2 you do this: quit/return 1 -MAx On Tue, Apr 7, 2009 at 10:20 AM, Awi <> wrote:

 [3/7] from: aloysius:prayitno:gma:il at: 15-Apr-2009 16:36

Hi Max, thanks for your suggestion. Unluckily that does not help, I still get those "NUL"s between each characters in the output window. Even stranger, this script REBOL [] probe "" will output NULNULNUL if I set the output to use 'default enconding' (Single byte character set), but will output NULDFNULFCNUL if set to UTF-8 encoding (65001) I think it's more to SciTe's problem handling the unicode output of rebol 3, but maybe someone knows better ? Awi On Tue, Apr 14, 2009 at 7:24 PM, Maxim Olivier-Adlhoch <>wrote:

 [4/7] from: moliad::gmail::com at: 15-Apr-2009 12:57

aahh I reread your post... I realize that my suggestion had nothing to do with your question! you are talking about the console output (stdout). I thought you meant the application return value, doh! I hope someone else with more insight is able to help you! -MAx On Wed, Apr 15, 2009 at 10:36 AM, Awi <> wrote:

 [5/7] from: santilli:gabriele::gmail at: 16-Apr-2009 10:18

On Wed, Apr 15, 2009 at 4:36 PM, Awi <> wrote:
> if set to UTF-8 encoding (65001)
Does SciTe have a UTF-16 setting? Windows uses UTF-16 in its API calls, and so is R3 for stdout. (I think UTF-16le in particular, but you should check.) HTH, Gabriele.

 [6/7] from: aloysius::prayitno::gmail::com at: 16-Apr-2009 11:54

Thanks Gabriele. This brings light, and explains the NULs before each characters. Unluckily it looks like SciTe only supports UCS-2 (both BE and LE), and that only on the editor pane, not the output pane. Awi On Thu, Apr 16, 2009 at 10:18 AM, Gabriele Santilli <> wrote:

 [7/7] from: santilli::gabriele::gmail::com at: 16-Apr-2009 18:16

On Thu, Apr 16, 2009 at 11:54 AM, Awi <> wrote:
> Unluckily it looks like SciTe only supports UCS-2 (both BE and LE), and that > only on the editor pane, not the output pane.
UCS-2 would probably work fine, it's too bad it's not supported in the output pane. Maybe the Windows version needs a command line switch to use UTF-8 for stdout? Regards, Gabriele.