nano-devel
[Top][All Lists]
Advanced

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

Re: [Nano-devel] aggressive C color highlighting


From: David Lawrence Ramsey
Subject: Re: [Nano-devel] aggressive C color highlighting
Date: Thu, 03 Aug 2006 23:37:01 -0400
User-agent: Thunderbird 1.5.0.5 (X11/20060719)

Alexey Toptygin wrote:

<snip>

> 2 should be faster than 1 even when editing, but slower than no
> coloring. If you can search the list quickly by line number, you only
> need to re-apply regexes to the text starting at the end of the last
> matched area that was entirely before the edited area, and ending at
> the end of the first matched area that is both a) entirely after the
> edited area and b) identical before and after the edit.
>
> For most edits, this means only 1-2 matched areas need to be updated
> in the list. The same quick list search can be used to get the matched
> areas that need to be highlighted on the screen about to be drawn.
> Finally, you can choose not to populate the list for areas after the
> one under edit.
>
> The only thing that is still slow is starting to edit at the end of a
> long file - you need to scan linearly from the start or you're not
> guaranteed to get the proper matches.

Okay then.  Thanks for the info.

> If this ever gets really terrible, we can give it a timeout, and then
> ask the user whether to continue or abort, like less does when
> counting line numbers.

Sounds good to me.





reply via email to

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