From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#11094: Wrong cursor positioning with display+invisible Date: Mon, 02 Apr 2012 09:09:34 -0400 Message-ID: References: <83vclljesi.fsf@gnu.org> <83wr5yj0yl.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1333372206 12763 80.91.229.3 (2 Apr 2012 13:10:06 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 2 Apr 2012 13:10:06 +0000 (UTC) Cc: 11094@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Apr 02 15:10:05 2012 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 1SEh1H-0004dH-3o for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Apr 2012 15:10:03 +0200 Original-Received: from localhost ([::1]:58064 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SEh1G-0002eH-DM for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Apr 2012 09:10:02 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:59390) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SEh17-0002d8-Qr for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2012 09:09:59 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SEh11-0003WW-BA for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2012 09:09:53 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:39042) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SEh11-0003VT-6e for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2012 09:09:47 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1SEh1G-0008Jf-Kx for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2012 09:10:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 02 Apr 2012 13:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 11094 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 11094-submit@debbugs.gnu.org id=B11094.133337219531949 (code B ref 11094); Mon, 02 Apr 2012 13:10:02 +0000 Original-Received: (at 11094) by debbugs.gnu.org; 2 Apr 2012 13:09:55 +0000 Original-Received: from localhost ([127.0.0.1]:35580 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SEh19-0008JG-9l for submit@debbugs.gnu.org; Mon, 02 Apr 2012 09:09:55 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.183]:14137) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SEh16-0008J8-8D for 11094@debbugs.gnu.org; Mon, 02 Apr 2012 09:09:53 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AicFAKU/KE9soXt6/2dsb2JhbACBX5x7eYhwnhmGGQSbGYQJ X-IronPort-AV: E=Sophos;i="4.73,1,1325480400"; d="scan'208";a="171273365" Original-Received: from 108-161-123-122.dsl.teksavvy.com (HELO pastel.home) ([108.161.123.122]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 02 Apr 2012 09:09:35 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id D95D1590C9; Mon, 2 Apr 2012 09:09:34 -0400 (EDT) In-Reply-To: <83wr5yj0yl.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 02 Apr 2012 05:56:34 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.94 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.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:58463 Archived-At: >> > For some value of "correctly". E.g., position the cursor over the >> > ".", which is the first file name in the archive, and type "C-x =". >> > You will see "63", which is a lie: the actual value of point is 111. >> I don't think it's a lie because that text is preceded by invisible >> text, so while "." is at 111, point is indeed at 63 (and that's just >> because of adjust_point_for_property, so we can get point to stay at >> 111 by being more careful with text property's stickiness). > Having point report X when it is position on a character whose > position is Y, or jump when you move it from one character of a file > name to the next violates the principle of least astonishment, IMO. That's an inevitable consequence of using `invisible'. So yes, I agree that `invisible' should be used with great care, but there is no bug in this particular part (the underlying problem is that the block cursor is drawn *on* characters whereas point is *between* characters). >> the cursor is drawn at the right place. I think this is the core of the >> problem that's handled differently from Emacs-23. >> [ IIUC you've gotten to the same conclusion. ] > While there could be more than one way to cut this cake, I still think > we should encourage Lips programmers to use the `cursor' property in > these situations. Hmm... I haven't actually tried to use the `cursor' property, but I'm not sure it would help when point is actually outside of the text area covered by any of the display strings. > Should we close this bug, then? We might as well keep it open until the problem is actually solved. Stefan