[Top][All Lists]

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

Re: Native display of line numbers, improved

From: Stefan Monnier
Subject: Re: Native display of line numbers, improved
Date: Mon, 26 Jun 2017 12:12:34 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

>> Basically, start with a small value of display-line-number-width, and if
>> during display we find that this value is too small to fit the largest
>> displayed line-number, we increase it.
> I wanted to avoid using a buffer-local variable settable by the
> display engine.  (I cannot easily use display-line-number-width,
> because that's a user-settable option; I need another variable.)

Oh, I didn't mean to use that variable.  I was just explaining that Alex
request to "grow-only" seems to work fairly well to provide "mostly
constant width" without having to scan the whole buffer upfront.
How to provide "grow-only" (i.e. where to store the previous-width info)
is not something I've thought about, but maybe it can be kept as
a window-local information, reset whenever we set-window-buffer.


reply via email to

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