r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[!REBOL3-OLD1]

Maxim
30-Oct-2009
[19322]
ok yeah a few different diacritics between those two encodings
Pekr
30-Oct-2009
[19323]
how do you aproach the situation, if your script would contain two 
strings, in different encodings? Can it practicall happen?
Maxim
30-Oct-2009
[19324]
R3 will interpret litteral strings and decode them using utf-8 (or 
the header encoding, if its supported) so in this case no.


but if the data is stored within binaries (equivalent to R2 which 
doesn't handle encoding) then, yes, since the binary represents the 
sequence of bytes not chars.


if you use a utf-8 editor, and type characters above 127 and look 
at them in  notepad, you will then see the UTF-8 byte sequences (which 
will look like garbled text, obviously).
Pekr
30-Oct-2009
[19325]
Is there utf-8 version of notepad? :-)
Maxim
30-Oct-2009
[19326]
I don't know if R3 has a way of specifying the encoding litterally... 
like  UTF8{}  UTF16{}  or WIN1252{} ... this would be nice.
PeterWood
30-Oct-2009
[19327]
A script cpud have two different encodings if differenlty encoded 
files were included. For example, you could use a script from Rebol.org 
in one of your scripts. You probably use Windows Code Page 1250 but 
most scripts in the library use other encodings.


This doesn't give big problems as most of the code in the Library 
is "pure" ASCII
Maxim
30-Oct-2009
[19328]
I use uedit which handles unicode natively when you want to... a 
lot of preferences for it ...
PeterWood
30-Oct-2009
[19329]
Notepad can apparently handle both UTF-8 and UTF-16 http://en.wikipedia.org/wiki/Notepad_(Windows)
Maxim
30-Oct-2009
[19330]
it tries to detect UTF based on text content... broken up until vista.
http://en.wikipedia.org/wiki/Notepad_%28Windows%29
Carl
30-Oct-2009
[19331]
Ok, so... no one reads the wiki.  That's ok... we're all developers. 
We don't read things other than code.

So, here's a summary of R3 and Unicode:

http://www.rebol.net/r3blogs/0286.html
Gabriele
31-Oct-2009
[19332x5]
Max: maybe you should start using a real operating system. But, that 
aside, if you have any software that does not handle utf-8, simply 
trash it. guys, really, this is crazy, we are in 2009, let's put 
an end to this codepage crap!
sqlab: what you say would make some sense if converting files was 
in any way difficult. (apart from the fact that you should have stopped 
using latin1 almost 10 years ago...). I've been using utf-8 with 
R2 for years...
sqlab: rigth, let's make string handling MORE COMPLEX. we definitely 
need that. let's copy MySQL, shall we?
Max: a system wide default means that my script will NOT run in the 
same way on your system. that is the definition of bad language design.
Petr: notepad, as most windows stuff, uses utf-16. much easier to 
detect though, and R3 could do that (actually, didn't Carl just add 
that recently?) most "real" editors allow you to use whatever encoding 
you want, and definitely support utf-8.
Pekr
31-Oct-2009
[19337]
Aha, I just realised that I have to use Save-as, and choose UTF-8 
or Unicode, instead of default ANSI preset of notepad
Maxim
1-Nov-2009
[19338]
gab, having a system-wide option will allow people to use the same 
code for different encoded source data.  it doesn't break my code 
or yours.  its a setup not a definition.
shadwolf
1-Nov-2009
[19339x2]
i love that documentation on bitset http://rebol.com/r3/docs/datatypes/bitset.html
 -> I give it A+++ a you must read it documentation !!
CArl on french forum they are wating to now if you plan to bring 
rebol world to the modile phone 3 generation area ? (android windowsphone 
or iphone). Could be a good way to show that not only adobe flash 
can provide things  in that area i think. But they a special "set" 
of feature should be build in rebol to feet the particular need of 
those plateform. What do you thin about it Carl ?
Maxim
1-Nov-2009
[19341]
this is what the host code is for.
shadwolf
1-Nov-2009
[19342x2]
carl T___T i read your documentation and post and all when i get 
some  free time to do it..
maxim too many groups here i'm dizzy just looking at the list ...
Maxim
1-Nov-2009
[19344x2]
iphone will not allow any other dev tools on the iphone, unfortunately.
what people do is create an abstraction for their tools and spit 
out iphone sdk compileable code.
shadwolf
1-Nov-2009
[19346]
hum ... who said to develop an application that runs on a iphone 
you had to run it on an iphone ^^
Maxim
1-Nov-2009
[19347]
action code 3 (flash) is now also licensed.
shadwolf
1-Nov-2009
[19348x2]
maxim if we as steeve jobs gently he will accept  ^^
ok so android seems the best choice it's wide open ...
Maxim
1-Nov-2009
[19350x3]
the R3 host is what ultimately loads the rebol.dll and provides any 
platform-specific resources to it.
yep.
but creating abstractions in REBOL is quite easy (compared to other 
languages), as Oldes has shown with his impressive flash dialect
shadwolf
1-Nov-2009
[19353]
but then the ask is what kind of rebol feet the need of those fone 
(personnally VID would be an awsome way to do animated high sight 
GUI application on fones )
Maxim
1-Nov-2009
[19354]
part of SCREAM's mission is to allow compilation targets for all 
of its tools.  this won't happen soon, but its one of the reasons 
for its existence in the first place.


Oldes' Flash dialect is very high on my list of Scream subprojects.
shadwolf
1-Nov-2009
[19355]
ok well that's an idea that poped out on the french forum i wanted 
to share to carl.
Maxim
1-Nov-2009
[19356x5]
its easy to compile VID blocks into other languages.  the only real 
tricky part is the actions, which have to be compiled too... so the 
best approach is to use a dialect within your event code, and stick 
to it.  this dialect can then be built so it can compile into languages.
a lot of rebol can be converted line for line in just about any language... 
you just need to keep the compilable language basic and you should 
be fine.
its a recurring request since REBOL as firat released.  with R3 we 
will now be able to compile rebol on ANY platform, which allows us.
as firat.... was first
its possible even symbian can be compiled to  :-)
shadwolf
1-Nov-2009
[19361]
i'm lost ...  anyway  people will understand you probably better 
than me.
PeterWood
1-Nov-2009
[19362]
Max: "action code 3 (flash) is now also licensed." I don't bellieve 
this is the case. Adobe has gone to great lengths to develop a Flash 
SDK which builds "regular" iPhone apps.
Maxim
1-Nov-2009
[19363x2]
yes, that is it.  its a licensed development tool.
its not flash in the browser.
PeterWood
1-Nov-2009
[19365]
I don't think there is a standalone Flash player for the iPhone either.
Maxim
1-Nov-2009
[19366]
nope... Apple doesn't want you to use flash in the browser... it 
kills their app market  :-(   
for example:

  bejeweled, one of the most successfull flash games ever, is available 
  as an app... they wouldn't want you to just play in on the net.. 


This is my only real Anger generating aspect of the iphone.   but 
this is true of just about every digital device out there... the 
provider wants to make money out of their appliances, so they control 
as much of what you can do on it, so they get a few cents every time.
Gabriele
1-Nov-2009
[19367]
Max, maybe i was not clear. If your rebol scripts are latin1 by default, 
while my rebol scripts are utf-8 by default, when i send you a rebol 
script IT WILL NOT WORK in the same way in your machine. the *script*'s 
encoding *must* be a standard everyone agrees on. then, the script 
can do whatever it wants with the data, it's your fault if you make 
it so data cannot be exchanged easily among systems.
Maxim
1-Nov-2009
[19368x2]
on this we agree, I am talking about read/write operations *from* 
the script.
although having an encoding parameter in the header would allow us 
to tell the interpreter in what format the text is without breaking 
anything.
jocko
1-Nov-2009
[19370]
I may miss something, but still I have problems with accentuated 
letters: 
when I type print "terminé" in the console, the result is ok.

When I put this instruction in a file, I get a syntax error: invalid 
"string" -- {"terminé"}
Henrik
1-Nov-2009
[19371]
are you putting it in a file from a text editor?