Nmap Development mailing list archives
Re: zenmap: problems with GUI language
From: David Fifield <david () bamsoftware com>
Date: Thu, 31 Dec 2009 23:12:06 -0700
On Sun, Dec 13, 2009 at 03:11:21PM -0700, David Fifield wrote:
On Mon, Dec 07, 2009 at 12:46:35PM +0100, Robert Premuž wrote:As I use Croatian regional settings in Windows, the zenmap GUI is in Croatian. Unfortunately, I haven't been able to change that by following the procedures on http://nmap.org/book/zenmap-lang.html I tried to run the following commands in the Windows command shell (cmd.exe): set LANG=en_US zenmap but zenmap started with GUI in Croatian language. Just in case I tried to set LANG using the Control Panel but the effect was the same. As a last resort I renamed "C:\Program Files\Nmap\share\zenmap\locale\hr" so that zenmap couldn't find the Croatian language file and this way I got GUI in English. So, is there something broken in zenmap for Windows regarding these issues? Am I doing something the wrong way?Zenmap gets the locale by calling the locale.getdefaultlocale function. http://docs.python.org/library/locale.html#locale.getdefaultlocale On Windows, this first tries to get the locale by calling the GetLocaleInfo function. http://msdn.microsoft.com/en-us/library/dd318101(VS.85).aspx If that fails, then it examines environment variables such as LANG. Maybe there's a Windows way to accomplish this without LANG? Is there a way to run just one application in a different locale? Does anybody have a non-English system locale, but run certain applications in English, for example?
Thanks guys. I think this is fixed in r16368. I found out that locale.getdefaultlocale doesn't look at LANG at all on Windows, so our documented menthod of setting the locale hasn't worked since we started looking at the system-wide locale setting, even for me in an English locale. I changed the code to look at LANG first and then call locale.getdefaultlocale. People who use a supported non-English locale won't have to do anything to get Zenmap in their language, and those who prefer the English can set LANG. David Fifield _______________________________________________ Sent through the nmap-dev mailing list http://cgi.insecure.org/mailman/listinfo/nmap-dev Archived at http://seclists.org/nmap-dev/
Current thread:
- zenmap: problems with CLI options and GUI language Robert Premuž (Dec 07)
- Re: zenmap: problems with CLI options David Fifield (Dec 13)
- Re: zenmap: problems with GUI language David Fifield (Dec 13)
- Re: zenmap: problems with GUI language Robert Premuž (Dec 14)
- Re: zenmap: problems with GUI language Robert Premuž (Dec 17)
- Re: zenmap: problems with GUI language Alexander Khodyrev (Dec 15)
- Re: zenmap: problems with GUI language David Fifield (Dec 31)
- Re: zenmap: problems with GUI language Robert Premuž (Dec 14)
