From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: how to change language of format-date-string Date: Sat, 21 Mar 2015 18:47:30 +0200 Message-ID: <83619uthzx.fsf@gnu.org> References: <87d243xgoc.fsf@gmx.us> <874mpey41o.fsf@gmx.us> <837fuatksj.fsf@gnu.org> <87zj76uz12.fsf@gmx.us> NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1426956484 13762 80.91.229.3 (21 Mar 2015 16:48:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 21 Mar 2015 16:48:04 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Mar 21 17:47:57 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YZMZ3-0004VM-4u for geh-help-gnu-emacs@m.gmane.org; Sat, 21 Mar 2015 17:47:57 +0100 Original-Received: from localhost ([::1]:48407 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YZMZ2-0007zN-Id for geh-help-gnu-emacs@m.gmane.org; Sat, 21 Mar 2015 12:47:56 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54569) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YZMYq-0007z5-SV for help-gnu-emacs@gnu.org; Sat, 21 Mar 2015 12:47:45 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YZMYm-0001rL-R1 for help-gnu-emacs@gnu.org; Sat, 21 Mar 2015 12:47:44 -0400 Original-Received: from mtaout22.012.net.il ([80.179.55.172]:54771) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YZMYm-0001rC-Iu for help-gnu-emacs@gnu.org; Sat, 21 Mar 2015 12:47:40 -0400 Original-Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0NLK00N00M661600@a-mtaout22.012.net.il> for help-gnu-emacs@gnu.org; Sat, 21 Mar 2015 18:47:39 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NLK00MJFMNELIA0@a-mtaout22.012.net.il> for help-gnu-emacs@gnu.org; Sat, 21 Mar 2015 18:47:39 +0200 (IST) In-reply-to: <87zj76uz12.fsf@gmx.us> X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: Solaris 10 X-Received-From: 80.179.55.172 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:103246 Archived-At: > From: Rasmus > Date: Sat, 21 Mar 2015 16:54:17 +0100 > > >> > (setq system-time-locale "da_DK.UTF-8") > >> > >> Thanks that works. > > > > If you set system-time-locale alone, without also setting > > locale-coding-system to the same encoding as specified by > > system-time-locale, you will get garbled strings (unless you _know_ > > that the encoding of both locales is the same, which in practice can > > only be true if they use UTF-8). > > I conclude this is a nontrivial problem with a pretty local-specific > solution. It's a shame. It would be quite useful when composing > documents in different languages (especially in terms of %B). I don't see how it is less trivial in Emacs than it is in any other program. Changing the locale on the fly is not something you are supposed to do a lot, so it's little wonder it's complicated. And we didn't even start talking about locale's local to a thread, only about a global program-wide locale.