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

[REBOL] Re: locale

From: zokie:libero:it at: 27-Aug-2002 7:59

Hello Petr On 25-Ago-02, Petr Krenzelok wrote:
>> I think to put %app-name.r & %catalog/ in the same directory, so they >> maybe installed, copied, removed together :) >> > OK, then remember the directory can contain more than one app (script) > .... just a note :-)
Ok! I'll use selective delete: delete %catalog/ ;) I use a different directory for each application, only application module, plug-in, companion may share the same dir :)
> hmm, IIRC Amiga has some organisation called ATO (Amiga Translation > Organisation). If someone develops app, he/she can contact ATO to do > translation to other languages, which can be ready till app release > time. I am not sure ppl here + RT will agree to:
Why can't we start a Rebol Free Translators Organization?
> 1) have default language pack external to script. It would mean EVERY > script would have to have two files - script itself, and catalogue. On > the other hand - if author doesn't wish to support localisation, he does > not need to create catalogue.
Yes! 1 script only for old-style Rebol Script :)
> 2) to have it downloadable. I am not sure app itself should download it > dynamically. Such capability should be provided by app itself, if author > wishes to do so.
Yes! Author may use refinement to active/deactive autodownload of missing/obsolete catalogs. It is not difficult to implement with Rebol :)
>> Their are both valid solution, but I think .cat suffix is better to make >> searches or use wildcard ;) >> > hmm, you are right here. What about .catalogue or .language suffix? Are > we really all influenced by MS Win3.1 era crap? :-)
Virtualy any suffix length is good for me, I hate too ridiculous M$'s 3 letters extention, but are out there million of human being that could have an heartbreak if they discover on their computer a not M$ standard extention :) A long file name may arise compatibility problems on different platfom, i.e. AmigaOS File System has 31 char bound for file name lenght, even if it reverve space for 108 chars! Short names should be better, so we must consider idea to replace "language" with shorter "languageID", i.e. "en", de , "it", "cz",... especialy if we add a version tuple
> Well, I always liked componentisation, but some ppl here will tell you > stories about so called "dll hell" - if you don't find a component, your > app is not operable. That's why we have Rebol in one executable file and > scripts are mostly one .r files and everything-inside-aproach is often > used :-)
I know about "dll hell", but ppl that works at M$ aren't programmers they are just chaos maker! AmigaOS use shared library too, but none has encountered any kind of problem with them. Any library has it version tag, and services may only added and not removed or renamed, so if you use a newest version your old applications will work as fine as newest one, if you require a specific new service, at opening time, you must specified the minum version number which support that service, if it is non present you will get an error and all you need to do is replace the library file with the newest avaible. Catalog files should be similar, and because Rebol is a net oriented language it is easy to do an autoupdate routine, so application doesn't work only there is a server fault :)) To do a fast version check we shoult add a version tuple even in file name, i.e. Uhm!? Not a standard suffix, heartbreaks are around the corner :)
> Think e.g. of Rebol itself. It contains many messages. They are in > English. How to translate them? Well, main rebol dir could contain
I think we were speak about Rebol Script Localization and not Rebol Environment Localizzaztion, even if a Global & Official solution is better :) At the end of this thread we should make a RFC and send it to Rebol Technologies. If they'll think it is good enough they may endorce it ;)
> something like suggested Then we need to tell Rebol to > use Czech language, right? How? Is the user.r the right place? What word > should be used? What about using system/locale object? > System/locale/preferred-language: "Czech". Then:
All I get with probe system/locale is: make object! [ months: [ "January" "February" "March" "April" "May" "June" "July" "August" "September" "October" "November" "December" ] days: [ "Monday" "Tuesday" "Wednesday" "Thursday" "Friday" "Saturday" Sunday ] ] We shoul try to add an object entry for each first opened catalog file, so it is accessable globaly and any more time we run a script catalog will be just there! Every localizzed script should start with: my-cat: open-catalog "app-name" version-tuple and end with: close-catalog "app-name" version-tuple So Rebol Garbage Collector may remove all unused catalogs when memory is not enough Regards -- "Where did you get all those facts!?!"