GNU bug report logs -
#79241
31.0.50; `vertical-motion' not respecting goal column when there is an overlay that spans multiple virtual lines
Previous Next
Full log
Message #46 received at 79241 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> From: Sergio Pastor Pérez <sergio.pastorperez <at> gmail.com>
>> Cc: 79241 <at> debbugs.gnu.org
>> Date: Sun, 24 Aug 2025 19:58:47 +0200
>>
>> Eli Zaretskii <eliz <at> gnu.org> writes:
>>
>> >> + if (it.method == GET_FROM_STRING)
>> >> + reseat_at_previous_visible_line_start(&it);
>> >> +
>> >> move_it_in_display_line (&it, ZV, first_x + to_x, MOVE_TO_X);
>> >> /* If we find ourselves in the middle of an overlay string
>> >> which includes a newline after current string position,
>> >
>> > Is this needed only for overlays? What about 'display' text
>> > properties? (There are also other cases when it.method could be
>> > GET_FROM_STRING.) If this is only for overlay strings, we need to use
>> >
>> > if (it.method == GET_FROM_STRING && !NILP (it.from_overlay))
>> >
>> > instead. Please test this at least with 'display' property strings
>> > instead of overlay strings, and see if the same problem happens in
>> > that case. Then we will be able to decide how to write the condition
>> > in this case.
>>
>> So I've tested this behavior with this display property:
>> --8<---------------cut here---------------start------------->8---
>> (let* ((start (point))
>> (end (1+ (point)))
>> (ov (make-overlay start end)))
>> (overlay-put ov 'display "--->HELLO\nAnother message\nDONE<---"))
>> --8<---------------cut here---------------end--------------->8---
>
> No, this is not what I meant. I meant to test 'display' text
> property, not overlay property.
Oh, understood. I've sent version 3 so it only affects overlays, for
display text properties we have the same convoluted behavior I described
in the previous mail. With v2 of the patch, at least the target column
is corrected but has the line skip issue, what I said in the previous
mail still holds.
This bug report was last modified 4 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.