[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Add a function that returns pixel distance between points?
From: |
Yuan Fu |
Subject: |
Re: Add a function that returns pixel distance between points? |
Date: |
Wed, 3 Feb 2021 11:48:27 -0500 |
> On Feb 3, 2021, at 10:04 AM, Eli Zaretskii <eliz@gnu.org> wrote:
>
>> Date: Tue, 02 Feb 2021 18:29:15 +0200
>> From: Eli Zaretskii <eliz@gnu.org>
>> Cc: emacs-devel@gnu.org
>>
>>> From: Yuan Fu <casouri@gmail.com>
>>> Date: Mon, 1 Feb 2021 18:00:18 -0500
>>> Cc: emacs-devel <emacs-devel@gnu.org>
>>>
>>> This code inserts a mini table
>>>
>>> | looooong |
>>> | world |
>>>
>>> And tries to aligns it to
>>>
>>> | looooong |
>>> | world |
>>>
>>> You will notice there are extra white space on the right of the cells, and
>>> the table actually looks like this:
>>>
>>> | loooooong |
>>> | world |
>>>
>>> That’s because window-text-pixel-size returned a width that’s larger than
>>> the true with of the cells. If you enlarge the line-prefix, the extra space
>>> grows.
>>
>> Hmm... this sounds like some bug in window-text-pixel-size. Let me
>> take a closer look.
>
> It turned out the function wasn't designed to handle text that spans
> less than a single screen line.
>
> Does the patch below fix your problems?
Yes, it worked well. Thanks!
Yuan
- Re: Add a function that returns pixel distance between points?, Yuan Fu, 2021/02/01
- Re: Add a function that returns pixel distance between points?, Eli Zaretskii, 2021/02/01
- Re: Add a function that returns pixel distance between points?, Yuan Fu, 2021/02/01
- Re: Add a function that returns pixel distance between points?, Eli Zaretskii, 2021/02/02
- Re: Add a function that returns pixel distance between points?, Eli Zaretskii, 2021/02/03
- Re: Add a function that returns pixel distance between points?,
Yuan Fu <=
- Re: Add a function that returns pixel distance between points?, Eli Zaretskii, 2021/02/04
- Re: Add a function that returns pixel distance between points?, martin rudalics, 2021/02/05
- Re: Add a function that returns pixel distance between points?, Eli Zaretskii, 2021/02/05
- Re: Add a function that returns pixel distance between points?, martin rudalics, 2021/02/05