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:date:message-id:from:to:subject:references :in-reply-to; q=dns; s=default; b=clGCrNZattF7pb+zS51zYiOqNUN3Rx bbNxnrFVjJqRcPDYwAon34BE/swJxy24tUvz3ojN9V6sVOQKr0tzbaFFMxBqOVff 5wnEH1m7jj7JhBRbQJIz0QK9MKykvTtWc1uazs4nQXMkIFWsgdYYTtFhkjFSsijX zY15nAaaLEFiQ= 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:date:message-id:from:to:subject:references :in-reply-to; s=default; bh=WLs+bmg3Q/6xm7qR0nypEPWrBDg=; b=VbUj oQbQUYlmZK3D4tXIw8K88o3Wop1yVPiwM+xwMRZ4UzqaXIseDd2MbnQVvrHssoAm 0m1jzVIX9xk27q9hQ3dAyfQYNeG1kOEtewRs4/ORgoU+wIe83qXzKo6lBjUUkbN3 7psDQ835sYFUJX6LhhUjri5sfjGHPTeWjrtayqk= 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=-2.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:1645, H*F:D*nl X-HELO: lb3-smtp-cloud2.xs4all.net Date: Tue, 31 Jan 2017 16:01:55 +0100 Message-ID: <40c92f1e987a9162742766816abb4a03@smtp-cloud2.xs4all.net> From: Houder To: cygwin AT cygwin DOT com Subject: Re: [ANNOUNCEMENT] Updated: dash-0.5.8-3 References: <58893f48 DOT 0850ca0a DOT 6c5d DOT 5fde AT mx DOT google DOT com> <81b5af354b7a3925ff0a68dcc063265f AT smtp-cloud6 DOT xs4all DOT net> <20170131100402 DOT GB29504 AT calimero DOT vinschen DOT de> <20170131131616 DOT GC29504 AT calimero DOT vinschen DOT de> In-Reply-to: <20170131131616.GC29504@calimero.vinschen.de> User-Agent: mua.awk 0.99 On Tue, 31 Jan 2017 14:16:16, Corinna Vinschen wrote: [snip] > > I'm not quite sure yet but apparently the problem is in the handling of > > VERASE in the termios implementation. In cooked mode it fills a char > > buffer with what has been typed. The code doesn't know if the bytes in > > the buffer are UTF-8 chars or just random bytes. So VERASE erases > > exactly one byte, which means, in case of UTF-8 chars it only erases the > > last byte of of a mulitbyte character. > >=20 > > It seems the Linux termios implementation is different in that it > > still knows which bytes constitute a single keypress and thus knows > > how much byte it has to erase. > > Ok, here's what happens on Linux: The termios code support a flag > IUTF8. This flag determines if the termios code checks for UTF8 > characters in the input when performing an ERASE. It checks if the > IUTF8 flag is set and if so, it checks in a loop if the just erased byte > is a UTF-8 continuation character. If so, it erases another byte. (Thank you for responding -- and your effort thus far). Agreed. One byte or more, depending on the "character" ... (which is not a problem in case of UTF-8 encoding -- continuation bit). Of course, the terminal driver must receive the characters encoded in UTF-8. Therefore the question is: 'can the same situation be created under under Windows?' (does Windows provide the required support?) A second question is: 'is it worth the effort?' Given that bash can recognize UTF-8 (using readline) ... .. and the fact that dash does not support multi-byte characters. Regards, Henri ===== -- 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