From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?UTF-8?Q?Cl=C3=A9ment?= Pit--Claudel Newsgroups: gmane.emacs.bugs Subject: bug#22761: Surprising interaction between font-lock, invisible text, and point (self-insert-command and insert behave differently) Date: Mon, 22 Feb 2016 11:03:03 -0500 Message-ID: <56CB3137.1010300@live.com> References: <56CA5405.10304@live.com> <8337skn3l8.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="IQecTuig8x1MKnL1rnSxxld4E0vl9CE71" X-Trace: ger.gmane.org 1456157259 5700 80.91.229.3 (22 Feb 2016 16:07:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 22 Feb 2016 16:07:39 +0000 (UTC) Cc: 22761@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Feb 22 17:07:28 2016 Return-path: Envelope-to: geb-bug-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 1aXt1D-0007s4-2I for geb-bug-gnu-emacs@m.gmane.org; Mon, 22 Feb 2016 17:07:27 +0100 Original-Received: from localhost ([::1]:49787 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aXt1C-0003m8-I6 for geb-bug-gnu-emacs@m.gmane.org; Mon, 22 Feb 2016 11:07:26 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42151) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aXsxy-0007Vs-Ll for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2016 11:04:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aXsxu-0002Wj-K1 for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2016 11:04:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:41119) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aXsxu-0002WR-GE for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2016 11:04:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aXsxu-0005wK-A8 for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2016 11:04:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?Cl=C3=A9ment?= Pit--Claudel Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 22 Feb 2016 16:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22761 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22761-submit@debbugs.gnu.org id=B22761.145615699522776 (code B ref 22761); Mon, 22 Feb 2016 16:04:02 +0000 Original-Received: (at 22761) by debbugs.gnu.org; 22 Feb 2016 16:03:15 +0000 Original-Received: from localhost ([127.0.0.1]:38246 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aXsx8-0005vI-Nt for submit@debbugs.gnu.org; Mon, 22 Feb 2016 11:03:14 -0500 Original-Received: from mout.kundenserver.de ([217.72.192.73]:57105) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aXsx7-0005v1-IB for 22761@debbugs.gnu.org; Mon, 22 Feb 2016 11:03:14 -0500 Original-Received: from [18.189.69.235] ([18.189.69.235]) by mrelayeu.kundenserver.de (mreue104) with ESMTPSA (Nemesis) id 0MORLZ-1ad60l0VAj-005mg6; Mon, 22 Feb 2016 17:03:06 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 In-Reply-To: <8337skn3l8.fsf@gnu.org> X-Provags-ID: V03:K0:tqEpKX+L8+c+9yzHMKgHtoMc2pE2ilFs+uGzMbQGhZjDWOGkw6C nZS1YneuJ7M+Sl05zKav0Yoj9WbEXpdE0c5rgd1uFFEQrriYDVVrDZ9c5xA3xj5HeK7aZW3 HnupKpOsIe+plQGLYjisYb8d9+Wqm3oHl/w6puD31sKoDvrhll98SApiUdOpZzdAggLztU+ 8uNptoV/kZ3HiD3nq/FcA== X-UI-Out-Filterresults: notjunk:1;V01:K0:PCKPJ//gRuc=:djmx6qO3geS9G91MkJOO1v /MKnXErsUktg+meu7qPxS4E/68vk1fGG+L3DyHoAr5var2PX+PO4KHyuWIbilfPcw1ayh2jB5 w3i4OAyG0/eWyVDIne8NYXCPmEHE5Ky5pIda+r+lMPqLOJootNW9mPev87DjyzKpXXYb/AAm7 MBSFn8EvSYNMHCF1wdA3QZiHelE5BzwixhvXTd1SoveM0U6L219RXwXco21EdqctWAPo/6u54 rL5e/IfsSO5+4vfIOVQDP5EmU2TilvsXbcLQjImnyK+Hs1JFNtmIJ/PQTq9t+BJ9OW32nSGEg ydanYtne82XzjHMiUdrhFwooEUCP+IA3WvTFhmcqOLtrxxM/xYo7paAUbPfpxqPYBeoc/0V24 n0r5vjPjXHE9TWYrpowVQO+DIdMAOVBWY3w99heRxbRDprRw11Yod/C3k/jHwgGRcbBPLy2oB Vp708ydbDGRRjDHT5Do4KvTpJN6UQBJYBluzJPH52fnLHDOuVR7ada07CYCl8nbs+6mFboqCx W5BX4FGD38pOMAtESw0QpCrb2+moj+sycd+fqk/csRAMEuFtWNGI9hewmE5Xwa/E5ThGCRq/b qP1NWiXmGo79GQ+9ZiucmsHNAE42g6EfAVw14pPg2fZdmADEWE3+4LIJSndU3v2Sr4hPiaxj6 ArZiqqqK1gaMLxQtbJGHdgp8m//CXNO4j+LSh+FsdNn8t5fT/Zrr5rmu64T2Apsy1Ws4= 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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:113456 Archived-At: This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --IQecTuig8x1MKnL1rnSxxld4E0vl9CE71 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 02/22/2016 10:53 AM, Eli Zaretskii wrote: >> From: Cl=C3=A9ment Pit--Claudel Date: Su= n, >> 21 Feb 2016 19:19:17 -0500 >>=20 >> The problem happens when editing =E2=80=98a_foo_b=E2=80=99 to replace = =E2=80=98foo=E2=80=99 by >> =E2=80=98bar=E2=80=99 (to get =E2=80=98a_bar_b=E2=80=99). Removing =E2= =80=98foo=E2=80=99 leaves =E2=80=98__=E2=80=99 in the buffer, >> which font-lock recognizes: the whole string gets displayed as >> =E2=80=98ab=E2=80=99. Even then, the point is still between the two un= derscores (it >> hasn't moved after font-lock added the invisible property to the >> underscores). Pressing =E2=80=98b=E2=80=99 to start inserting =E2=80=98= bar=E2=80=99 works fine (I >> end up with =E2=80=98a_b_c=E2=80=99), except for one thing: the point = gets moved >> after the second underscore. Thus, pressing =E2=80=98ar=E2=80=99 to co= mplete =E2=80=98bar=E2=80=99 >> ends up inserting =E2=80=98a_b_arb=E2=80=99. >=20 > Did you try binding global-disable-point-adjustment to a non-nil=20 > value? I imagine that it would work, but wouldn't it break other parts of Emacs?= The mode to which I'm adding this subscripts feature also uses hideshow,= for example, and I do want the point to be moved out of invisible sectio= ns then. Cl=C3=A9ment. --IQecTuig8x1MKnL1rnSxxld4E0vl9CE71 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAEBAgAGBQJWyzE3AAoJEPqg+cTm90wjupoP/3R356E6IQyfjUkrx5eaaZ55 MiwbuzFOnNk0sL6EP4TXTjaeDz7OxifkbuLVOfjt27IV9kPcNW5fARGcqijGUjGb kPjyZ07b+GTMtuQYASL6VLT1sS9AZ81pDwoJEbTp8Jsj2PTSxOduqqdnlwIyfMiX YKl346YDEYd635znKvzuXiRiiWBlXZq3HYD4y385paRvkm17d0fHyWSOHISoOjqe CY5Ird6cXepm4bms8hn9l/fEL10Xq6mU8IMeTBmvLsnvyTw+iLXMaKCr0jB98S5c JnIXrsV3WOV0gNx4y/FipybMt7qIw0w1FbZTPylfc1JKx1rLbpqBljhUmIEVP0uo /no4zSqjnWOMhJyNIV5aaZjz2e0Ju58qaxJ7R4fy2FolRx7waQowD4d8gQuFGTVR dIN1jgDUjBs9V1S1xbs26hK76XcaPynXKczxDMvt7YbpnGRF/EC7q7Re6wtXxEI0 iS6ulzg8cUbkjCEnd6IB760mxAvEbyCNdwK1UuQSIk++MmXOWWawO8/tcK0akXls DRx7g4zby73gxVBvx1BOXKJHJkA9jlGkMjsy+9vwzxMsB00EsWjg+8LsqXy2mJrZ g3JTO+sUMN+2xFW4Qs4fWpgIDDLtGQddiVgzJSk24qG8Fco77zoQYArwOVyC3/fc m3JMh+nW0SYURo9aMZ7N =L4Rt -----END PGP SIGNATURE----- --IQecTuig8x1MKnL1rnSxxld4E0vl9CE71--