Home   Archive   Permalink


Hi all!
I would like to know if there is access to the strings that appear in some dialogs and widgets. For example, request will offer a dialog with three buttons: Yes, No and Cancel. How con one change, say “Yes” for “Si” or “Da”?
Request-date will offer the names of the month in English. It wouldn't be difficult to write a function that translates the returned string to another language or even format. But how can you change the text so that the user finds the names of the month in the dialog already in the language she uses?
I was hoping that the dialogs accept extra string parameters to customize the text in buttons or that maybe you can alter them in memory with a setup routine. I've been searching on-line about this but all references are old and they all point to the consensus that something must be done about it. Was something done?
Thanks in advance for your help!

posted by:   Damian       28-Jul-2013/3:44:22-7:00

Try this:
request ["French" "Oui" "Non"]
Most values in Rebol are stored in the system object. Try this:
system/locale/months: ["Janvier" "Février" "Mars" "Avril" "Mai" "Juin" "Juillet" "Août" "Septembre" "Octobre" "Novembre" "Décembre"]
Take a look at http://business-programming.com/business_programming.html#section-13.1 to see a bit more about the system object.
You can create word synonyms like this:
imprimer: :print
imprimer "Bonjour tout le monde"
You can get the code for any built in function using "mold":
editor mold :request-list
Make changes like this:
request-list: do replace mold :request-list "btn-cancel" {btn "résilier"}
request-list "Pick:" ["one" "two"]
You can put changes like this in %rebol.r and %user.r, so that they run every time the interpreter starts.

posted by:   Nick       4-Aug-2013/7:16:10-7:00