Opened 12 years ago

Closed 12 years ago

#4281 closed Enhancement (invalid)

Visualize seed progress, like the web client does

Reported by: mag Owned by: jordan
Priority: Normal Milestone: None Set
Component: Transmission Version: 2.31
Severity: Normal Keywords:
Cc:

Description

It would be nice to see at a glance how the seeding is coming along. This is in fact a major reason that I often open the web interface rather than qtr.

Since reading numbers and taking the ratio of two numbers does not count as "at a glance" in my book, I have implemented a proposal for how to do this; As the seeding progresses, the progressbar shrinks to the right.

See the attached .diff for a working implementation.

If this is acceptable, it is probably a good idea to port the same visualization to the compact view.

Attachments (1)

seed_progress.diff (1.5 KB) - added by mag 12 years ago.

Download all attachments as: .zip

Change History (17)

Changed 12 years ago by mag

comment:1 Changed 12 years ago by mag

By the way, I am not convinced that my proposal is the way to go. I just figured that a ticket with a patch is better than the same ticket without a patch :)

My main concern is that it should be as easy to see how seeding is coming along in the qt client as in the web client.

comment:2 Changed 12 years ago by jordan

  • Component changed from Qt Client to Transmission
  • Milestone changed from None Set to 2.32
  • Status changed from new to assigned

comment:3 Changed 12 years ago by jordan

Actually, I like this idea for one simple reason: it's something that's portable to both the GTK+ and Qt clients. Both GTK+ and Qt limit what you can portably do with a progressbar. :|

comment:4 Changed 12 years ago by jordan

  • Resolution set to fixed
  • Status changed from assigned to closed

Applied to GTK+ and Qt clients in r12464

comment:5 Changed 12 years ago by rb07

  • Resolution fixed deleted
  • Status changed from closed to reopened

This change seems to have an unintended effect with compact view: http://img821.imageshack.us/img821/8179/transmissionqt231compac.png

I mean the asymetry, it looks good in regular view: http://img26.imageshack.us/img26/4106/transmissionqt231normal.png

but the Web client looks better.

comment:6 Changed 12 years ago by jordan

rb07, what happens if you set the compact progressbar's text to an empty string in torrent-delegate-min.cc around line 163 or so?

My guess is that this is being caused by the way Qt renders progressbars on Windows.

comment:7 Changed 12 years ago by rb07

Interesting. I made a change to the next line, not an empty string but:

    myProgressBarStyle->text = buf;
    //myProgressBarStyle->textVisible = true;
    myProgressBarStyle->textVisible = false;
    setProgressBarPercentDone( option, tor );
    style->drawControl( QStyle::CE_ProgressBar, myProgressBarStyle, painter );

and the result looks pretty good (larger bar now that the text is out): http://img846.imageshack.us/img846/8179/transmissionqt231compac.png

of course there could be complaints about not showing the percentage... but maybe changing the style, if there is one with the text over the bar it would be perfect.

comment:8 Changed 12 years ago by rb07

I see what you mean by "on Windows"... actually I wasn't using the default Windows style, I was using cleanlooks, but reverting my change and using style plastique: http://img828.imageshack.us/img828/8179/transmissionqt231compac.png

which almost looks good ;-) yeah, picky, picky. I would make the percentage font a bit smaller, and perhaps not bold, also change colors like the Web client has, not green on white, green on light green looks better, or even green/gray.

I'll try to see if this can be improved permanently, but you where right, the side effect is probably Windows only (Macs don't show the percentage anyway, Linux I haven't tested but I think is fine unless you use a style that puts the text outside).

Feel free to close this ticket. I just don't want to scare users away (the picture in comment 5 looks pretty ugly now, doesn't it).

Last edited 12 years ago by rb07 (previous) (diff)

comment:9 follow-up: Changed 12 years ago by jordan

rb07, I'm wondering if we should #ifdef out the text in the compact view's progressbar when on Windows. Does that sound like a good or bad idea?

comment:10 in reply to: ↑ 9 Changed 12 years ago by rb07

Replying to jordan:

rb07, I'm wondering if we should #ifdef out the text in the compact view's progressbar when on Windows. Does that sound like a good or bad idea?

I think its overkill.

The Windows case is more complex, there are at least 2 styles used as defaults by Qt on Windows, the windowsxp and the vista style.

I don't know if the vista style has the problem with the text outside the bar since I can't see it (the Qt build process doesn't include that style when cross-compiling -- one of several related bugs on Qt).

Since there are workarounds, I would wait to see if a better option comes up.

comment:11 Changed 12 years ago by rb07

How does this look? http://img823.imageshack.us/img823/3748/transmissionqt231mod.png

A one line change, added the 3rd line:

    myProgressBarStyle->text = buf;
    myProgressBarStyle->textVisible = true;
    myProgressBarStyle->textAlignment = Qt::AlignCenter;
    setProgressBarPercentDone( option, tor );

comment:12 Changed 12 years ago by jordan

  • Resolution set to fixed
  • Status changed from reopened to closed

Looks good!

Added in r12470

comment:13 Changed 12 years ago by rb07

Side note: with the above change on Windows when you select a torrent, or several, the percentage goes white and can become invisible or partially visible.

I tried the simple fix:

    myProgressBarStyle->palette.setColor( QPalette::Window, Qt::lightGray );

but it didn't work (another Windows feature? the Qt documentation says that color changes may not work if the widget is a native widget).

The colors on Windows have always been pretty bad (i.e. the selected row goes green, the same color as the progress bar); this is a Qt problem (not Transmission's even if it can be fixed/improved with more code or a style).

comment:14 Changed 12 years ago by lucke

In the Qt client, the white bar grows rightwards, while in the Gtk one, the blue bar grows leftwards. Is it intended?

comment:15 Changed 12 years ago by jordan

  • Milestone changed from 2.32 to None Set
  • Resolution fixed deleted
  • Status changed from closed to reopened

I should have tested this change out with more users. Several people have indicated confusion at the right-to-left progressbars. There's one ticket open for it (#4389) and there have also been forum and irc questions about this.

I'm going to roll back the right-to-left behavior.

comment:16 Changed 12 years ago by jordan

  • Resolution set to invalid
  • Status changed from reopened to closed

r12827 undoes the right-to-left behavior.

So the question is how to visualize seed progress. #4389 has some other suggestions on how this might be done, at least in the GTK+ client. mag, rb07, you may want to take a look at those suggestions and weigh in on them.

Closing this ticket as superceded by #4389.

Note: See TracTickets for help on using tickets.