[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: move_it_vertically_backward question
From: |
Po Lu |
Subject: |
Re: move_it_vertically_backward question |
Date: |
Wed, 15 Dec 2021 10:13:39 +0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.60 (gnu/linux) |
Eli Zaretskii <eliz@gnu.org> writes:
> No, I meant to ask window-text-pixel-size to do that, by passing it a
> specially-formatted value of FROM (and possibly also TO).
>
> So let's teach window-text-pixel-size to be able to accept the FROM
> argument which says "N pixels above position POS".
I still don't believe that would be better than a separate primitive
(since it doesn't make sense to supply the width information to the
pixel scrolling code), and unfortunately I don't quite understand how
`window_text_pixel_size' works either: for instance, it seems to disable
the bidirectional reordering of text? I also don't see why `it' is
saved into `it2' only to be restored before anything interesting is done
with `it'.
Correctly pixel-scrolling over bidirectional text will probably be a
very important feature for people working with RTL languages, but I'm
not sure how many of them are likely to use such a feature.
> That's not very efficient if PIX can be a large value.
Yes. Maybe calling `move_it_vertically_backward' itself until a
suitable position is reached will be better, as I really don't want to
reinvent "move_it_vertically_backwards but slightly different".
Something like this:
move_it_vertically_backward (&it, pix);
while (-it.current_y < pix)
{
last_y = it.current_y;
move_it_vertically_backward (&it, pix + it.current_y);
if (it.current_y == last_y)
break;
}
Thanks.
- Re: move_it_vertically_backward question, (continued)
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/13
- Re: move_it_vertically_backward question, Po Lu, 2021/12/13
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/14
- Re: move_it_vertically_backward question, Po Lu, 2021/12/14
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/14
- Re: move_it_vertically_backward question, Po Lu, 2021/12/14
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/14
- Re: move_it_vertically_backward question, Po Lu, 2021/12/14
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/15
- Re: move_it_vertically_backward question, Po Lu, 2021/12/15
- Re: move_it_vertically_backward question,
Po Lu <=
- Re: move_it_vertically_backward question, Po Lu, 2021/12/15
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/15
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/15
- Re: move_it_vertically_backward question, Po Lu, 2021/12/15
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/15
- Re: move_it_vertically_backward question, Po Lu, 2021/12/15
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/16
- Re: move_it_vertically_backward question, Po Lu, 2021/12/16
- Re: move_it_vertically_backward question, Eli Zaretskii, 2021/12/16
- Re: move_it_vertically_backward question, Po Lu, 2021/12/16