4

Setup:

GUI version GNU Emacs 25.0.50.1 (x86_64-w64-mingw32) of 2015-07-25 on KAEL compiled from EmacsW64.

Windows 7 x64 Dutch version.

Situation:

When I'm evaluating the following snippet:

(format-time-string "%B")

It gives me "August" as result. In the Dutch language, we have "augustus" (spelled in another way, and without any case).

And my operating system is also in Dutch language. When I tried (setq system-time-locale "nl_NL") to no avail. When I check the value of current-language-environment, it gives me UTF-8 as value.

Another suggestions to get the days/months displayed in Dutch?

Update:

things are getting weird. On the Windows with the Dutch language (my work pc), I get "August". On my home pc with Windows with the English language, I get "augustus". And it's with the same Emacs configuration. So I guess it's not related to the operating system.

ReneFroger
  • 3,855
  • 22
  • 63
  • "nl_NL" might not be a locale that MS Windows knows about. Windows uses some non-standard aliases for locale names. I found this page, but I don't use Windows and wouldn't be able to figure out what in that table is the actual locale name: https://msdn.microsoft.com/en-us/library/dd318693.aspx – wvxvw Aug 27 '15 at 13:34
  • It should use language according locale settings on Unix-like systems. Not sure about Windows. – Mark Karpov Aug 27 '15 at 13:34

1 Answers1

2

Have you tried setting environment variable LANG to your language? Similarly, variables LC_TIME etc. - see the Emacs manual, node General Variables. That node also mentions MS Windows in particular: Control Panel > Regional Settings.

See also node Language Environments.

If this helps, it might help to know that I found these nodes (and more) by using i in the Emacs manual. I typed locale at the prompt. TAB then shows you index entries that start with locale.

(Since I use Icicles, I use S-TAB to see index entries that match locale also as a substring, which picks up a couple more entries, such as set-locale-environment.)

Drew
  • 75,699
  • 9
  • 109
  • 225
  • That was the answer. I noticed that I have set the environment variable `LANG` to C in Windows. I deleted that variable. After restarting the computer, I get the Dutch spelling for months. Your tip solved my question enventually, so thanks for your answer. And 50 bonud added too. Your contributions to Emacs community are really appreciated. – ReneFroger Sep 01 '15 at 07:51