From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#33230: 26.1; Soft-wrap issue in term.el with term-suppress-hard-newline Date: Fri, 02 Nov 2018 22:15:17 -0400 Message-ID: <87bm76j496.fsf@gmail.com> References: <87h8h0if4u.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1541211255 11178 195.159.176.226 (3 Nov 2018 02:14:15 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 3 Nov 2018 02:14:15 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) Cc: 33230@debbugs.gnu.org To: Bruno CHARRON Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Nov 03 03:14:11 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIlRy-0002nY-LE for geb-bug-gnu-emacs@m.gmane.org; Sat, 03 Nov 2018 03:14:10 +0100 Original-Received: from localhost ([::1]:53972 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIlU5-0004OR-37 for geb-bug-gnu-emacs@m.gmane.org; Fri, 02 Nov 2018 22:16:21 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59366) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIlTx-0004O9-GT for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 22:16:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gIlTo-0004o3-7M for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 22:16:09 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:56258) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gIlTm-0004l4-2M for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 22:16:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gIlTl-0004Jj-QC for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 22:16:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 03 Nov 2018 02:16:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 33230 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 33230-submit@debbugs.gnu.org id=B33230.154121132916555 (code B ref 33230); Sat, 03 Nov 2018 02:16:01 +0000 Original-Received: (at 33230) by debbugs.gnu.org; 3 Nov 2018 02:15:29 +0000 Original-Received: from localhost ([127.0.0.1]:60516 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIlTE-0004Ir-NR for submit@debbugs.gnu.org; Fri, 02 Nov 2018 22:15:28 -0400 Original-Received: from mail-io1-f44.google.com ([209.85.166.44]:45541) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIlTC-0004IW-4j; Fri, 02 Nov 2018 22:15:26 -0400 Original-Received: by mail-io1-f44.google.com with SMTP id p83-v6so2680684iod.12; Fri, 02 Nov 2018 19:15:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=oVVyfnBTBqxSDEwJR/PAmnJtMALSSgM30586qE+wcXk=; b=QrzcjKU4XofwDbK7dVtr0/T1khJ/A7xAHr/3krkva3dx0kl9DauLcUMJ500FfrLCf5 UzLKwQE4OXTnrwl5fD9Tp9kG0TcrMiCqGfk+SqZlwk3n6s8VTFOYS+qC5jNECdbjjds7 tq1cKLKNSqnAUNZzF/ntftL75FsRbP+xy0p8ed6WK/Xmr9dXvDGBpCENpu5NXRuiIjfx 1NIlwRrMjcwAJuhMGoGeeZKfc6Fe0cMBfG2tT98scV0OrTGASFqJg6WJS32jJGDUQPRq tGfwr9EVmJ7K4YW2MlOly4OKbq4nZARNzYZxRV9TJ/XrLhMFGfESOSTfUx74QSRL0DZm ZQ2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=oVVyfnBTBqxSDEwJR/PAmnJtMALSSgM30586qE+wcXk=; b=fe4X3hf6DPcWGWLCbrESnos3QtbLFpfu/G6OGfnMD4xdQ2CHsYdFdQEAE+bryx+8pw Pyf0Btq08M0gMMZjp4BRnX9nSFQqCUvKmVwENzspPc2u6dWt5aefbwn5TBPT4Vue4sj6 2wdy7JjXYwo5IPLg77FVTTUq63ucot8/s7RNXgZaESozOWIYzcbQIbgnEE29DXvsZ4qS vK+XP+kgP+pBIBU2ULAsUjZ0lnSHhh67enVO/RKMUhCD9vahTvEB79LQZPBYD8bh4zCC BcTDeEhelTyfmaG5Pq0BIK5yLUoNijNpTDD/uWSrJRJBbRtA6b+febyvPQ5JuMbeyxRf 0JBg== X-Gm-Message-State: AGRZ1gIV/cTXKyaqUq7QLo+dj24YZ+Xbb1CP91kTqdwbR8Sv5rPUVHdB zO2l5eWUnqU1/o2EyeVV4pjjQZ74 X-Google-Smtp-Source: AJdET5cwQjZSwO+8LQQKN9s0cotnXBkRrtA7X8zQFVDBmFhlX49MixJUtX+SGxvsDXt/Qt4c7ENcbg== X-Received: by 2002:a6b:f40e:: with SMTP id i14-v6mr2517899iog.278.1541211320481; Fri, 02 Nov 2018 19:15:20 -0700 (PDT) Original-Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id q205-v6sm1341701itc.2.2018.11.02.19.15.18 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 02 Nov 2018 19:15:18 -0700 (PDT) In-Reply-To: (Bruno CHARRON's message of "Fri, 2 Nov 2018 09:50:57 +0900") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:151962 Archived-At: found 33230 24.4 tags 33230 + confirmed quit Bruno CHARRON writes: > Basically I am typing 'x' repeatedly in the command line until it reaches the > right screen edge. > Setting term-log-buffer as t, I can see what the shell is sending to emacs in > the Messages buffer. > When I type 'x' in the middle of the screen, the shell responds 'x' to print an > 'x' at the current cursor position. > When I type 'x' on the last column, the shell responds 'x ^M^[[K', which I could > understand with this explanation [1]. > It seems to be the standard way to ask the terminal to wrap the line under > uncertainty on its behavior. > First it asks to insert 'x' on the last column, then some terminals will wrap > then but just in case it asks to insert an additional ' ' to force wrapping then > erases the new line (carriage return '^M' then erase to end of line '^[[K', see > [2]). > If term.el processes 'x' first then ' ', it will wrap when processing the ' ' > but when term-suppress-hard-newline is t, it processes both at the same time and > doesn't wrap due to the reason explained in the original post. Ah, got it. I got mixed up a few times, because I didn't realize it only happens after the first line (otherwise there's nowhere to go back up to). I can reproduce this also with 24.4 (when term-suppress-hard-newline was introduced). It seems like this option is somewhat incompatible with shells, it's not clear what the right behaviour would be. You say the problem is that there is no wrapping, but isn't term-suppress-hard-newline exactly intended to suppress this kind of wrapping?