ddgtk icon indicating copy to clipboard operation
ddgtk copied to clipboard

[FEATURE REQUEST] Display a progress bar

Open 9898287 opened this issue 7 years ago • 3 comments

Well, it's nice to inform the users how much data have been written to the disk.

Currently all it does is show a spinner

I suggest that you parse stdout of the dd command at the interval of 1 second and update the progressbar. dd already says how many bytes have been written.

I would make a PR but I do not know python well enough.

9898287 avatar Nov 07 '18 03:11 9898287

I have been meaning to get around to this.

Can probably use this https://lazka.github.io/pgi-docs/Gio-2.0/classes/Subprocess.html#Gio.Subprocess.get_stderr_pipe parse the stderr and use some regex magic.

gort818 avatar Nov 07 '18 03:11 gort818

Just create a temporary file and keep parsing it like I did. https://gitlab.com/9898287/nixwriter/blob/master/source/backend.d

9898287 avatar Nov 20 '18 09:11 9898287

Nice, I like yours better than mine, I had no idea there were gtk bindings for D. I have been thinking of redoing ddgtk in Rust.

gort818 avatar Nov 29 '18 01:11 gort818