Statistics slider show only one option labelled "game" when the game has just been started

Bug #887730 reported by Hans Joachim Desserud on 2011-11-08
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Medium
Unassigned

Bug Description

(Split out from bug 536543)
When I open the general statistics window just after started a new game, there is a single button labeled "game". Now, I do notice this is probably because additional steps are added dynamically, which in and of itself is a food idea but it looks rather weird to have a slider with only one element. (And I've always liked to be able to compare the different time scales.) Then again I don't know, but I would like a default showing more than one position.

Joachim (nomeata) suggested to always show the 15 min option as well even when the "game" option also means 15min. This seem like a fine solution to me as it would ensure that the slider always have at least two options. Showing at least two options makes it much clearer that it is a slider, and especially combined with bug 887728 this would work very well.

Widelands r6090.

Related branches

Joachim Breitner (nomeata) wrote :

Just an idea: How about leaving one option, but greying it all out to indicate “this widget is cannot be used at the moment”?`

SirVer (sirver) wrote :

AFAIK in other GUI widgets when there is only one slider option it is the leftmost one, but the slider can't be moved. The slider always has its full width which i deem important for the optics.

however in this case I feel having always the game option and at least 15mins is a fine solution as well. Joachim, are you tackling this one?

Changed in widelands:
status: New → Confirmed
milestone: none → build17-rc1
Joachim Breitner (nomeata) wrote :

The problem with full width is that this does not work well for sliders where the positions are labeled, if we want the labels to be below the corresponding position of the cursor. This is why, if we have n possible positions, the slider is padded by width/(2*n) on both sides.

If you prefer having two options, even if they do the same thing, I can provide a simple patch.

SirVer (sirver) wrote :

Thanks joachim. Pushed in r6093. Btw, I remember dimly that you prefer the merge-request approach to contributing, but just to make sure: Do you'd rather have push to trunk rights? I am fine with both.

Changed in widelands:
status: Confirmed → Fix Committed
Joachim Breitner (nomeata) wrote :

Given that I’m only a sporadic contributor, I indeed prefer the merge-request approach. But thanks for the offer.

SirVer (sirver) wrote :

Released in build17-rc1.

Changed in widelands:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers