emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Variable-width font indentation


From: Clément Pit-Claudel
Subject: Re: Variable-width font indentation
Date: Tue, 6 Mar 2018 10:34:41 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0

On 2018-03-06 10:15, Dmitry Gutov wrote:
> On 3/5/18 9:49 PM, Paul Eggert wrote:
>> On 03/05/2018 11:32 AM, address@hidden wrote:
>>> 1: void foo(int a,
>>> 2:          int b)
>>> 3: {
>>> 4:  ...
>>>
>>> How is any generic indentation system supposed to know that the "i" on
>>> line 2 is supposed to line up with the "i" on line 1?
>>
>> It assumes the input is fixed-width, and that leading white space is 
>> intended to indent with respect to previous lines. Although it'd be some 
>> work to get Emacs to do this, I don't offhand see any algorithmic problem 
>> here.
> 
> If the way whitespace at bol is rendered depends on indentation code, will 
> the mean that while scrolling a buffer the display engine will have to call 
> indentation code?

In Paul's suggestion (the one I implemented), the width of whitespace at bol 
does not depend on indentation code.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]