Patch to fix scrolling issues in backup log window



Hello!

I've been using deja-dup for a while and have come across a problem
with the implementation of auto scrolling in the backup log window.

I don't know if it's specific to my system (though I doubt it since the
bug has followed me around for a few years on different systems), but
the existing implementation did not actually automatically scroll the
window.

I've been maintaining this patch privately for a while now and thought
you might be interested in adding it upstream.


Here is a short summary of the changes:

Add update_autoscroll function that is bound to the size_allocate event
on the progress_text object. The existing implementation unsuccessfully
tried to scroll the progress_scroll object before progress_text had
taken it's new size after adding another line of text. This new
implementation waits for the progress_text to update it's size before
scrolling.

Add stop_autoscroll function that gets called when scrolling the
progress_scroll object. This is needed so the user has a chance to stop
the autoscrolling when lines are added too quickly for the user to
scroll in between lines. Otherwise the progress_scroll will get stuck
at the bottom.

Added "progress_scroll.expand = true" so that the progress_scroll takes
up the entire available height of the window.

Removed automatic log trimming. This is probably a personal preference
and not 100% necessary, but with the larger log window trimming the log
at 100 lines makes it not even fill the entire screen anymore when the
application is fullscreen. I've also found it annoying that I wasn't
able to actually go back in the log to look at which files had been
backed up. The comment in the source code cites memory concerns as a
reason for the trimming, but I've found memory consumption, even on
large directories, to be negligible.


I've included a patch based on version 36.3 as attachment.

Best regards,
Erik

-- 
Erik Entrich <mail erikentrich de>

Attachment: scrollfix.patch
Description: Text Data

Attachment: signature.asc
Description: This is a digitally signed message part



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