[patch] Selection stats in statusbar
Scott Kostyshak
skostysh at lyx.org
Sun Jul 31 09:16:17 UTC 2022
On Sun, Jul 31, 2022 at 12:35:30AM +0200, Pavel Sanda wrote:
> On Fri, Jul 15, 2022 at 12:05:25AM +0200, Pavel Sanda wrote:
> > On Thu, Jul 14, 2022 at 09:31:06AM +0200, Daniel wrote:
> > > >The drawback is that's it's difficult to understand the interaction between
> > > >the two timers now. I stared on the code for couple minutes and it was
> > > >not clear to me what is the idea behind your stop/start changes.
> > >
> > > Some comments would probably have been good. I could try to add them if
> > > there is interest.
> >
> > If I find little time I'll try the QTimer route and see whether we converge :)
>
> So I tried to find the best from solution from both worlds.
> In the attached patch we use QTimer (0.5s between updates) for updating stats.
> To avoid tricky interactions with another timer and current messages in
> status bar I simply cretaed completely new label next to the slider, so it's
> independent mechanism with no interactions.
>
> On top of that its possible to disable the visibility via context menu, but it's
> part of session not new RC variable, which seems good enough compromise.
>
> The update interval is now 0.5s, let me know if there is any slugishness
> in your testing. I didn't see any, but I can easliy increase to 1s if need be.
>
> Any objections now?
>
> Pavel
I'm on vacation and won't be able to test for a few weeks. Can you do
the test I described before? Just select a big document, and then hold
Shift + <UP> to decrease the selection towards the beginning of the
document. I just counted using a wrist stopwatch and compared
with/without the patch.
I did not look, but will this be on by default? Would you object to a
way to turn off the stats, like we have a way to turn off the zoom level
and slider in the status bar? If you would object, I suggest we take a
poll on lyx-users. I would vote against it (since I don't like numbers
changing as I change the selection) but I have a feeling most users
would be in favor of it, and I would be fine with that result.
Scott
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.lyx.org/pipermail/lyx-devel/attachments/20220731/7ff10edb/attachment.asc>
More information about the lyx-devel
mailing list