* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
@ 2014-03-20 9:33 Nicolas Richard
2014-03-20 13:17 ` Nicolas Richard
0 siblings, 1 reply; 7+ messages in thread
From: Nicolas Richard @ 2014-03-20 9:33 UTC (permalink / raw
To: 17047
[-- Attachment #1: Type: text/plain, Size: 566 bytes --]
Hello,
I run (with latest trunk, but the problem exists in earlier builds too) :
$ src/emacs -Q ~/tmp/testemacs.org
then do:
M-x visual-line-mode RET
TAB ;; show the content of the headline
C-x 3 ;; the second line gets wrapped (repeat if needed to achieve effect).
C-n
C-f
At this point, cursor moves erroneously to the end of the headline,
although M-: (point) RET reports 8 as it should (so, only the cursor is
misplaced).
Alternatively, "C-n C-f" can be replaced by "M-g c 8", then inserting
chars shows where point really is.
Here's the testemacs.org file
[-- Attachment #2: test case --]
[-- Type: text/plain, Size: 74 bytes --]
* foo
f[[file:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]]
[-- Attachment #3: Type: text/plain, Size: 401 bytes --]
In GNU Emacs 24.3.50.6 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
of 2014-03-07 on geodiff-mac3
Windowing system distributor `The X.Org Foundation', version 11.0.11304000
System Description: Gentoo Base System release 2.2
Configured using:
`configure --with-x-toolkit=lucid 'CFLAGS= -O0 -g3''
Important settings:
value of $LANG: fr_FR.UTF-8
locale-coding-system: utf-8-unix
--
Nico.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
2014-03-20 9:33 bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position Nicolas Richard
@ 2014-03-20 13:17 ` Nicolas Richard
2014-03-20 17:24 ` Eli Zaretskii
0 siblings, 1 reply; 7+ messages in thread
From: Nicolas Richard @ 2014-03-20 13:17 UTC (permalink / raw
To: Nicolas Richard; +Cc: 17047
[-- Attachment #1: Type: text/plain, Size: 240 bytes --]
Nicolas Richard <theonewiththeevillook@yahoo.fr> writes:
> * foo
> f[[file:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]]
Sorry, the initial 'f' on the second line should not be there. Here's
the correct file as attachment.
[-- Attachment #2: test case --]
[-- Type: text/plain, Size: 73 bytes --]
* foo
[[file:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]]
[-- Attachment #3: Type: text/plain, Size: 11 bytes --]
--
Nico.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
2014-03-20 13:17 ` Nicolas Richard
@ 2014-03-20 17:24 ` Eli Zaretskii
2014-03-20 17:34 ` Eli Zaretskii
0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2014-03-20 17:24 UTC (permalink / raw
To: Nicolas Richard; +Cc: 17047
> From: Nicolas Richard <theonewiththeevillook@yahoo.fr>
> Date: Thu, 20 Mar 2014 14:17:04 +0100
> Cc: 17047@debbugs.gnu.org
>
> Nicolas Richard <theonewiththeevillook@yahoo.fr> writes:
>
> > * foo
> > f[[file:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]]
>
> Sorry, the initial 'f' on the second line should not be there. Here's
> the correct file as attachment.
Ugh, and I already wasted an hour trying to reproduce this, and was
about to tell you I can't.
Thanks for the fixed recipe.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
2014-03-20 17:24 ` Eli Zaretskii
@ 2014-03-20 17:34 ` Eli Zaretskii
2014-03-23 16:02 ` Eli Zaretskii
0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2014-03-20 17:34 UTC (permalink / raw
To: theonewiththeevillook; +Cc: 17047
> Date: Thu, 20 Mar 2014 19:24:46 +0200
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 17047@debbugs.gnu.org
>
> > From: Nicolas Richard <theonewiththeevillook@yahoo.fr>
> > Date: Thu, 20 Mar 2014 14:17:04 +0100
> > Cc: 17047@debbugs.gnu.org
> >
> > Nicolas Richard <theonewiththeevillook@yahoo.fr> writes:
> >
> > > * foo
> > > f[[file:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]]
> >
> > Sorry, the initial 'f' on the second line should not be there. Here's
> > the correct file as attachment.
>
> Ugh, and I already wasted an hour trying to reproduce this, and was
> about to tell you I can't.
>
> Thanks for the fixed recipe.
Interim report: a very old bug, I see it in Emacs 23.1 (didn't try
earlier).
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
2014-03-20 17:34 ` Eli Zaretskii
@ 2014-03-23 16:02 ` Eli Zaretskii
2014-03-24 9:41 ` Nicolas Richard
0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2014-03-23 16:02 UTC (permalink / raw
To: theonewiththeevillook; +Cc: 17047-done
> Date: Thu, 20 Mar 2014 19:34:41 +0200
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 17047@debbugs.gnu.org
>
> > Date: Thu, 20 Mar 2014 19:24:46 +0200
> > From: Eli Zaretskii <eliz@gnu.org>
> > Cc: 17047@debbugs.gnu.org
> >
> > > From: Nicolas Richard <theonewiththeevillook@yahoo.fr>
> > > Date: Thu, 20 Mar 2014 14:17:04 +0100
> > > Cc: 17047@debbugs.gnu.org
> > >
> > > Nicolas Richard <theonewiththeevillook@yahoo.fr> writes:
> > >
> > > > * foo
> > > > f[[file:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]]
> > >
> > > Sorry, the initial 'f' on the second line should not be there. Here's
> > > the correct file as attachment.
> >
> > Ugh, and I already wasted an hour trying to reproduce this, and was
> > about to tell you I can't.
> >
> > Thanks for the fixed recipe.
>
> Interim report: a very old bug, I see it in Emacs 23.1 (didn't try
> earlier).
Fixed in revision 116843 on the emacs-24 branch.
Note that moving cursor to the "f" of "file" from the left will get
you to position 8, while moving there from the right will get you to
position 10. But this is a separate "feature".
Also note that this situation is one of the small number where
visual-order-cursor-movement works differently from the default
logical-order one, even though there's no bidirectional context
anywhere in sight. And that is also a feature.
Thanks.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
2014-03-23 16:02 ` Eli Zaretskii
@ 2014-03-24 9:41 ` Nicolas Richard
2014-03-24 17:23 ` Eli Zaretskii
0 siblings, 1 reply; 7+ messages in thread
From: Nicolas Richard @ 2014-03-24 9:41 UTC (permalink / raw
To: Eli Zaretskii; +Cc: 17047-done
Eli Zaretskii <eliz@gnu.org> writes:
> Fixed in revision 116843 on the emacs-24 branch.
Thanks !
> Note that moving cursor to the "f" of "file" from the left will get
> you to position 8, while moving there from the right will get you to
> position 10. But this is a separate "feature".
This is not unexpected I think. It would be nice to have a visual clue
about which side of the invisible text we stand, but I have no idea what
kind of clue it should be. Is that worth a wishlist bug anyway ?
> Also note that this situation is one of the small number where
> visual-order-cursor-movement works differently from the default
> logical-order one, even though there's no bidirectional context
> anywhere in sight. And that is also a feature.
Just for the record, the difference is that no matter if we come from
left or right, we get to position 10.
--
Nico.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position
2014-03-24 9:41 ` Nicolas Richard
@ 2014-03-24 17:23 ` Eli Zaretskii
0 siblings, 0 replies; 7+ messages in thread
From: Eli Zaretskii @ 2014-03-24 17:23 UTC (permalink / raw
To: Nicolas Richard; +Cc: 17047
> From: Nicolas Richard <theonewiththeevillook@yahoo.fr>
> Cc: 17047-done@debbugs.gnu.org
> Date: Mon, 24 Mar 2014 10:41:07 +0100
>
> > Note that moving cursor to the "f" of "file" from the left will get
> > you to position 8, while moving there from the right will get you to
> > position 10. But this is a separate "feature".
>
> This is not unexpected I think. It would be nice to have a visual clue
> about which side of the invisible text we stand, but I have no idea what
> kind of clue it should be. Is that worth a wishlist bug anyway ?
The clue you mention is not what bothers me. What bothers me is that
the same position of the cursor corresponds to 2 different text
positions, and you can only get to one of them, depending on the
direction of the cursor motion. From the left, you get positions 7,
8, 11, 12, ... From the right, you get 12, 11, 10, 7, ... The cursor
is positioned on the same character for both 8 and 10.
The only justification for this "feature" is that otherwise you
couldn't have inserted text before the invisible portion.
> > Also note that this situation is one of the small number where
> > visual-order-cursor-movement works differently from the default
> > logical-order one, even though there's no bidirectional context
> > anywhere in sight. And that is also a feature.
>
> Just for the record, the difference is that no matter if we come from
> left or right, we get to position 10.
Indeed, because it goes by characters that are actually displayed, and
the character at position 8 is not.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2014-03-24 17:23 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-20 9:33 bug#17047: 24.3.50; visual-line-mode + org-mode + C-f makes cursor jumps to unexpected position Nicolas Richard
2014-03-20 13:17 ` Nicolas Richard
2014-03-20 17:24 ` Eli Zaretskii
2014-03-20 17:34 ` Eli Zaretskii
2014-03-23 16:02 ` Eli Zaretskii
2014-03-24 9:41 ` Nicolas Richard
2014-03-24 17:23 ` Eli Zaretskii
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.