X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; q=dns; s=default; b=c7 lxrVBFqCyP9ghuJ1kzaqDRf6bimg2wIHv9+d4PRhFpEm7zxIk8f1jdIu56aTrrLU +s8U7eAzOKPWCmJhcS7/6hl7SdfwMhGmSoOIOzQx9dRxToojIlhQYOzmHY+4U/fo NAJx8rxM5a7wgPZd4dH72jVc53jcTDoe6EmbchZFw= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; s=default; bh=4/5Yy3Fq DhWYFAKfG/EHAj36VzU=; b=ueL8fM8JzdmqOd7VcOvyTiq0Bpc7WYduItEGfEEA GALBUwxd5C1S6Gm/s+hBGkm86ZPOczl2EDzzLX76nD32C723qptH7HGT7fTmlHxe A1+U78uCPQT/EeJQfwfQ+WGPBazqD2O6aZ4zeQ+Ua9DLvQ0AYy6J1yU/D/qex+q7 G8c= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.0 required=5.0 tests=AWL,BAYES_20,FREEMAIL_FROM,FREEMAIL_REPLY,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=no version=3.3.2 X-HELO: mail-qa0-f44.google.com MIME-Version: 1.0 X-Received: by 10.224.114.69 with SMTP id d5mr71778878qaq.96.1404921883896; Wed, 09 Jul 2014 09:04:43 -0700 (PDT) In-Reply-To: <185225348.20140708220026@yandex.ru> References: <185225348 DOT 20140708220026 AT yandex DOT ru> Date: Wed, 9 Jul 2014 18:04:43 +0200 Message-ID: Subject: Re: setting character set in mintty From: Pawel Jasinski To: cygwin Content-Type: text/plain; charset=UTF-8 On Tue, Jul 8, 2014 at 8:00 PM, Andrey Repin wrote: > Greetings, Pawel Jasinski! > >>>> The way I understand it, mintty sets the LANG variable according to >>>> user settings. >>>> Would it make sense for mintty to invoke "cmd /c chcp " >>>> (SetConsoleOutputCP)? > >>>mintty does not use the console at all. A chcp call doesn't make >>>any sense. > >> Sorry for asking stupid question. My knowledge of cygwin internals lacks. >> However, I can see that for every mintty window (and bash) I get a >> conhost process running. I assume that it is where the character >> setting is stored for non-cygwin processes started from bash. >> Again, it is my naive believe, that somewhere there maybe a convenient >> place to call SetConsoleOutputCP with argument matching content of the >> LANG environment variable. > > Even if you do that, it won't help anything at all. At the moment I am using ugly 'cmd /c chcp 65001' and it does help. BTW. this is a solution recommended by cygwin FAQ. I guess I am not the first one who encounter this inconvenience. > Typical windows program > does not expect a change in console code page at all. > If it was designed to use OEM CP, it will output in it regardless of actual > CP. To be specific, IronPython and cpython interpreters are program which respect CP settings. Any .net based console application is by default respecting CP settings. The minimalistic example of such a program: using System; namespace encoding_console { class Program { static void Main(string[] args) { Console.WriteLine("\u2192"); } } } > > P.S. > Please teach your mail agent to insert proper threading headers. A thread > scattered across multiple pieces is very hard to follow. > If you're subscribed in digest mode, reply to your own messages sent to the > list. This is the case. I didn't realized I was messing something up by editing things by hand. Sorry. > > > -- > WBR, > Andrey Repin (anrdaemon AT yandex DOT ru) 08.07.2014, <21:49> > > Sorry for my terrible english... > -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple