From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 88801 invoked by alias); 12 Oct 2016 10:32:47 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 88786 invoked by uid 89); 12 Oct 2016 10:32:46 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=ham version=3.3.2 spammy=bass, Bass, Shcheglov, shcheglov X-HELO: mail-it0-f51.google.com Received: from mail-it0-f51.google.com (HELO mail-it0-f51.google.com) (209.85.214.51) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 12 Oct 2016 10:32:36 +0000 Received: by mail-it0-f51.google.com with SMTP id z65so51604412itc.0 for ; Wed, 12 Oct 2016 03:32:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=IksEI4PppTOHS5CPZVt6KRGYKa4iHSWjig1vIAhKdAA=; b=R7Nv25oNvGbcrxrRpfkjBM5oOeZ/AUMXDY3PjW7qUk8gGnAD26ygJvduUKJaVBgbPx PhdzfqQfwSzkNN9T5MC0YKOce74Ju9W7n0DkaVKlrcPMzwFQ9m9DDJwlpxXDLEC/Yq2B 9SYXcGPMjrQjAtz5myOtLSyQdCJx3yPKR83JYwHJ86rCw+Kw+i2TsBKKXhe+8HEGBgXa tcNxShGEi9l74eeJ0SqBqmwRbc74ldfwSu9qhN1DCWuFVIuXrz0av5Sk4AY2gV6wj2C5 X/VGqhNU90ML1K/vH06aNwTrUDjMo0RChflD6GLegnoADbp7prcCB3x0JmiKAhpGf03H TXEw== X-Gm-Message-State: AA6/9RnxYo2ZWWeQD0F4RetHyrDxSoZ6vDyz0VAcQo39MZiKfFW6T6mxbp7UDubzZTNZPg== X-Received: by 10.36.33.18 with SMTP id e18mr1914539ita.113.1476268354885; Wed, 12 Oct 2016 03:32:34 -0700 (PDT) Received: from [172.20.9.87] ([12.165.187.67]) by smtp.googlemail.com with ESMTPSA id n69sm10644358ita.0.2016.10.12.03.32.33 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 12 Oct 2016 03:32:34 -0700 (PDT) Subject: Re: Escape sequences unprocessed under the "cygwin" terminal To: cygwin@cygwin.com References: <57FDF60B.4000206@gmail.com> From: Marco Atzeri Message-ID: <14aba7e2-a859-5476-f460-5721e3b9e61d@gmail.com> Date: Wed, 12 Oct 2016 10:59:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <57FDF60B.4000206@gmail.com> Content-Type: text/plain; charset=koi8-r; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2016-10/txt/msg00164.txt.bz2 On 12/10/2016 10:36, Andrey ``Bass'' Shcheglov wrote: > > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Hi All, > > I have a Java application which uses ANSI escape sequences to display > colours, position the cursor, etc. > > It works fine under regular Unices, and also under |xterm| and |mintty| > (in Cygwin//), but I'm having trouble running it under the "|cygwin"| > terminal (i. e. |bash| launched from |cmd.exe|). cmd is not a Cygwin terminal, it is a limited Windows one. What is the problem to use mintty ? > As you can see from the screen shot > (https://i.stack.imgur.com/Ohg41.png), escape sequences are output "as > is", without processing. On the other hand, I can easily run smth like > |echo -e '\033[1;31mTest'| -- and colour text will be just there. > > At the same time, if I launch exactly the same application from a > Midnight Commander// subshell, > escape sequences produced by the application will be interpreted > correctly: https://i.stack.imgur.com/jV7UW.png > > Also, if I log in to my Windows box using SSH (i. e. replace the local > connection with the remote one, but retain the same |"cygwin|" > terminal), again, escape sequences are processed just fine. from Unix ? The terminal on that side is able to properly manage escape sequence > It looks like when a subshell of some kind is created (|mc| or |ssh|), > the terminal is put into some other mode. But playing with |stty| wasn't > helpful, nor was export'ing |TERM=ansi|. > > Could anyone please suggest any solution? use mintty. It is the recommended one for cygwin > I'm running > >> CYGWIN_NT-6.3 UNIT-725 2.5.1(0.297/5/3) 2016-04-21 22:14 x86_64 Cygwin > and Windows 8.1. > > Thank you in advance. > > Regards, > Andrey. Regards Marco -- 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