From: Eli Zaretskii <eliz@gnu.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: 11094@debbugs.gnu.org
Subject: bug#11094: Wrong cursor positioning with display+invisible
Date: Mon, 02 Apr 2012 05:56:34 +0300 [thread overview]
Message-ID: <83wr5yj0yl.fsf@gnu.org> (raw)
In-Reply-To: <jwvk4206bwu.fsf-monnier+emacs@gnu.org>
> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: 11094@debbugs.gnu.org
> Date: Sun, 01 Apr 2012 21:06:59 -0400
>
> > 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.
> I see that the problem is not so much that all the text is covered by
> those properties, but rather that there is are contiguous texts with
> `invisible' and `display' properties.
Yes, that doesn't help, as I mentioned.
> emacs -Q
> (put-text-property (point-min) (+ 4 (point-min)) 'display "<>")
> (goto-char (point-min))
>
> 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.
> > If you still think we should support your original code, we should
> > schedule some post-24.1 redesign and refactoring. Let me know what
> > you think.
>
> I don't think it's a very high priority problem, but it would be good to
> try and tackle it, yes (post-24.1).
OK.
Should we close this bug, then?
next prev parent reply other threads:[~2012-04-02 2:56 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-26 4:07 bug#11094: Wrong cursor positioning with display+invisible Stefan Monnier
2012-03-31 9:33 ` Eli Zaretskii
2012-04-02 1:06 ` Stefan Monnier
2012-04-02 2:56 ` Eli Zaretskii [this message]
2012-04-02 13:09 ` Stefan Monnier
2012-04-02 16:51 ` Eli Zaretskii
2012-04-02 20:15 ` Stefan Monnier
2012-04-02 21:06 ` Eli Zaretskii
2012-04-03 13:37 ` Stefan Monnier
2012-04-07 12:07 ` Eli Zaretskii
2012-04-09 2:23 ` Stefan Monnier
2012-04-09 8:02 ` Eli Zaretskii
2012-04-09 13:21 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83wr5yj0yl.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=11094@debbugs.gnu.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).