[patch] Selection stats in statusbar

Daniel xracoonx at gmx.de
Thu Aug 18 12:08:42 UTC 2022


On 18/08/2022 11:44, Jürgen Spitzmüller wrote:
> Am Donnerstag, dem 18.08.2022 um 11:31 +0200 schrieb Daniel:
>> This shouldn't be an issue. The idea is that statistics are only
>> generated after some time has passed without interruption. They are
>> not
>> shown immediately. Hence, continuous arrow key movement would not
>> trigger statistics at all. (Same for continuous typing which is an
>> advantage to the current implementation which continuously triggers
>> statistics.)
> 
> It _is_ an issue if you blindly call functions if not needed, even if
> they exit early. This is really not better than the current timer-based
> approach.

No function exits early on that approach. The function does not get 
called in the first place. I think it is really better.

Currently: statistics update continuously and, hence, can interfere with 
continuous typing.

My method: statistics update only when idle for a long enough time and 
only once, hence, cannot interfere with continuous typing and are very 
unlikely to interfere at all.

I am open to this simple method not being good enough but I haven't seen 
any evidence for that yet.

Daniel



More information about the lyx-devel mailing list