[Home] [Downloads] [Search] [Help/forum]

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  International
. . -> [Subject]  How to localize MUSHclient messages into other languages
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?
(New message)
Subject: How to localize MUSHclient messages into other languages
Name:
Your forum user name.
Register forum user name
Password:
Your forum password.
Forgotten password?
Message:
Message to be posted (in English, please)
Maximum of 6000 characters. Text only please, no HTML.
Forum codes:
Check this if your message uses 'forum codes' or templates (auto-detected for new posts).
Forum codes Templates

Save this message ...


Subject review (reverse sequence)

Pages: 1 2  3  

Posted by StuDraKi   Germany  (17 posts)  [Biography] bio
Date Sun 30 Dec 2007 04:41 AM (UTC)  quote  ]
Message
I have downloaded and tested it, and now it's working fine.

Thanks for the fast and excellent help.

StuDraKi.
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sun 30 Dec 2007 03:22 AM (UTC)  quote  ]
Message
Quote:

In a world file I have a timer, running every 30 second. when it is saved, it is second="30,00".


This was supposed to be have been fixed in version 4.18, which I did by temporarily changing the locale to "C" and back again. Evidently this didn't work. Version 4.20 fixes the problem by simply changing "," to "." when saving the world file. This will be consistent with the way world files are read, and allow for plugins to be shared between users who use different locales.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sat 29 Dec 2007 07:35 PM (UTC)  quote  ]
Message
See:

http://www.gammon.com.au/scripts/showrelnote.php?version=4.18&productid=0

This version was supposed to fix this problem.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sat 29 Dec 2007 05:55 AM (UTC)  quote  ]
Message
As for DE.DLL it won't create it automatically. I suggest you copy EN.DLL to DE.DLL then it should work OK. You can then use a resource editor to edit DE.DLL to amend the wording of the menus if you want to.

For the timer issue, I thought that had been resolved. I will look into that.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by StuDraKi   Germany  (17 posts)  [Biography] bio
Date Sat 29 Dec 2007 05:29 AM (UTC)  quote  ]
Message
I have two issues with the localisation, may be they are not related to each other. I'm using MushClient 4.19 on an German WinXP.

1) Cannot load DE.dll: I've used this article and created a de.lua, but restarting MushClient does not create a DE.DLL. Also changing the paramter in Global Preferences dows not influence anything. (Personally I'm used to the english version and I don't want to change it.)

2) In a world file I have a timer, running every 30 second. when it is saved, it is second="30,00". But during loading there is an error message Line 682: Invalid character ',' in numeric attribute named 'second' (timer not loaded)
During reading he is expecting a '.', so if I change manually it to '.' or delete the, and the 0-decimals it works.
',' and '. are exchanged in German and French compared with the English localisation of it.
[Go to top] top

Posted by Isthiriel   (111 posts)  [Biography] bio
Date Mon 18 Jun 2007 05:38 AM (UTC)  quote  ]
Message
1252 is probably the codepage. Though I'm not completely sure why that would be specified in the locale name.
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Mon 18 Jun 2007 12:36 AM (UTC)  quote  ]
Message
Version 4.12 has now been released, which fixes a few niggling problems with the earlier interim releases. See:

http://www.gammon.com.au/forum/?id=7967

The resource file en.dll has not changed at all from the earlier release, so if you have been localizing 4.11 resources, the same file can be used for 4.12.

http://www.gammon.com.au/files/mushclient/resources/mushclient_resources_4.11.zip

Some of the Lua code posted earlier in this thread is now distributed as part of the locale directory, to make it easier to do localization. There is also a locale_notes.txt file which explains the purpose of the various files.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sun 17 Jun 2007 09:04 PM (UTC)  quote  ]
Message
The PennMUSH localization files seemed to be named using the countrycode_languagecode.po convention. See:

http://download.pennmush.org/Source/translations/1.8.3p2/

These are their file names:


da_DK.po
de_DE.po
eo.po
es_ES.po
fr_FR.po
hr_HR.po
hu_HU.po
id_ID.po
nl_NL.po
no_NO.po
pl_PL.po
pt_BR.po
pt_PT.po
ro_RO.po
ru_RU.po
sv_SE.po
zh_TW.po


I suppose there could be an argument for translating French slightly differently depending on which country you are in (or English for that matter), but in the case of a MUD client, I don't think that level of detail is needed. In a spell-checker, maybe.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sun 17 Jun 2007 08:59 PM (UTC)  quote  ]

Amended on Sun 17 Jun 2007 09:08 PM (UTC) by Nick Gammon

Message
Well, that is a Microsoft game. :)

I am calling GetLocaleInfo to get the abbreviated language name (eg. EN), based on the current locale.

However bearing in mind this may not be what the user actually wants to use (what happens if they speak multiple languages?) - then there is a configuration option to override that.

In Lua scripting, if you type:


/print (os.setlocale (""))


You see:


English_Australia.1252


Now I'm not sure where 1252 comes into it (I am in Australia too), as it isn't 1033.

From that table you suggested, this is the line for Australian English:


English_Australian / 0c09 / 3081 / 0c09:00000409


Now 1033 in decimal is 0409 in hex. But that entry (0c09:00000409) is listed as "Valid Locale ID:InputLocale combinations".

Thus 1033 (0x409) is really the input locale. I was under the impression the input locale was the keyboard locale, not the locale for displaying messages. Anyway you can see how confusing it is if you start looking at Microsoft's table.

To quote from Microsoft's documentation:


Input locales, implemented in Win9x, NT4, Windows 2000, and Windows XP are pairings of an input language with an input method (which might be a particular keyboard layout, an Input Method Editor, or speech-to-text converter, for example). Specifically, an input locale describes the language being entered, and how it is being entered.

Input locales are added on a per user basis. For each account it is possible to install multiple input locales and switch between them when entering text, allowing for the composition of multilanguage documents.

...

An Arabic user using Arabic Windows 2000 wants to type an email message in a mixture of Arabic and Russian. The user already has an Arabic input locale, and installs a second input locale for the Russian language (with an Arabic keyboard layout). When entering text, the user is able to switch between the Arabic input locale and the Russian input locale.


Thus, the input locale is really to help you enter text in different languages. However in my case I am trying to solve displaying of text in the desired language.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Isthiriel   (111 posts)  [Biography] bio
Date Sun 17 Jun 2007 10:29 AM (UTC)  quote  ]
Message
I'm in Australia and all the XP localization settings are EN-AU (except the keyboard is EN-US) and Office and the localized MS Games that I have all installed a 1033.dll for their resources.

*shrug*

You are going to need a translation table from machine locale to mushclient locale anyway and there's presumably going to be an option somewhere to change it if mushclient's first guess is wrong.
[Go to top] top

Posted by Shadowfyr   USA  (1,775 posts)  [Biography] bio
Date Sun 17 Jun 2007 01:32 AM (UTC)  quote  ]

Amended on Sun 17 Jun 2007 01:37 AM (UTC) by Shadowfyr

Message
Usually things have default region codes, so if you "don't" have the correct code for 2057, it defaults to 1033, in most programs. In fact, 1033 is probably the default-default, so if you lack "any" support for other languages installed, then it would automatically drop to 1033, same way fonts go from its specific name, to its general family, to the system default, if each one in the chain is missing and can't be loaded.

Mind you, it occurs to me after posting that you might actually want to treat them as "families", so it some fool deletes 1033, you try to set it to 2057 and there is some "other" English set available, it will grab that instead, being the only "available" one to use in that family. Either way, if you wanted to allow for that granularity, instead of just jumping strait to the "default" English file, you would need to have some sort of table showing what the "closest" set of possible alternatives where, so you could load one that is available, if the one requested wasn't there.

main {
__if (Schrodinger_Cat is Alive or version >= "XP"){
____if version = "Vista" then Performance /= Number_of_Cores;
____call Functional_Code();}
__else
____call Crash_Windows();}
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sat 16 Jun 2007 08:38 PM (UTC)  quote  ]
Message
Just to elaborate on that answer. I think if someone speaks English then they will understand a message like:


"This variable name is already in the list of variables."


I don't think that message needs to be translated into:


  • English_United_States
  • English_United_Kingdom
  • English_Australian
  • English_Canadian
  • English_New_Zealand
  • English_Ireland
  • English_South_Africa
  • English_Jamaica
  • English_Caribbean
  • English_Belize
  • English_Trinidad
  • English_Zimbabwe
  • English_Philippines


Even if it was, I can't offhand think of what the different translations would be.

And, if we did start using locale codes, and the file was renamed 1033.lua (English_United_States), and someone from England started using it, the program would find the locale to be 2057 (English_United_Kingdom), and not process the file.

So, we have actually made things harder for people doing that.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sat 16 Jun 2007 10:06 AM (UTC)  quote  ]
Message
Well, I thought English was English.

I mean, if the messages comes out in 1033, I imagine someone who speaks 3081 or 4105 or 5129 will understand them.

Another example of Windows making things too complicated, I think.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Isthiriel   (111 posts)  [Biography] bio
Date Sat 16 Jun 2007 08:59 AM (UTC)  quote  ]
Message
And you aren't using the default Windows locale codes (ie EN-US = 1033)?

http://www.microsoft.com/globaldev/reference/winxp/xp-lcid.mspx
[Go to top] top

Posted by Nick Gammon   Australia  (19,180 posts)  [Biography] bio   Forum Administrator
Date Sat 16 Jun 2007 04:59 AM (UTC)  quote  ]
Message
Locale codes

I have been searching around for a definitive list of locale codes (eg EN=English, FR=French etc.).

So far I have found this one:

http://www.loc.gov/standards/iso639-2/php/code_list.php

Anyone who is planning to localize MUSHclient as described earlier will probably want to use a code from that list.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


36,751 views.

This is page 1, subject is 3 pages long: 1 2  3  [Next page]

[New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]