Add "whole game" to the time axis in statistics

Bug #536543 reported by astuur
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Fix Released
Wishlist
Joachim Breitner

Bug Description

Currently all statistics have several time scales (15 min 30min 1h etc).
For games that are played longer that 16h there is no viewing mode.
I am suggesting a button "game" to the user interface that would show the entire period the game has been up and running.

Tags: statistics

Related branches

Changed in widelands:
importance: Undecided → Wishlist
status: New → Confirmed
tags: added: statistics
Revision history for this message
Joachim Breitner (nomeata) wrote :

This is no implemented and ready to be merged.

Changed in widelands:
status: Confirmed → In Progress
assignee: nobody → Joachim Breitner (nomeata)
Changed in widelands:
milestone: none → build17-rc1
Revision history for this message
SirVer (sirver) wrote :

Merged in r6064.

Changed in widelands:
status: In Progress → Fix Committed
Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Hi Joachim, I'm really happy to see the new slider in the statitistics window. :)

However, in r6066 (after this was added?) all I get is a button with the label game. If I click on this button, the game crash with the following message "Program received signal SIGFPE, Arithmetic exception.". Should I attach a backtrace from gdb?

Revision history for this message
Joachim Breitner (nomeata) wrote :

Hi Hans Joachim,

I noticed that as well, and fixed it by now. It will come with my next round of changes.

Revision history for this message
Joachim Breitner (nomeata) wrote :

I pushed my fix to https://code.launchpad.net/~nomeata/widelands/plot-improvements, if you could test it that would be great!

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Comparison of the old and current statistics window.

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Yes, I tested and it doesn't crash now. However, I still have some comments (please let me know if you want me to split them out into multiple bug reports. Normally I would, but they are all connected to this one)

(based on r6080)
*There is still a single button labeled "game" when I open it at the beginning. 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.
*Which leads me to the next point: the general statistics window now has a lot of white space. Both the slider (which granted once it is populated takes up a lot of space) but also the rows with players and categories. I especially liked how the players' width adjusted based on how many players were involved, so that no matter they would fill up the entire row. Now when you play a game with only a few players, a lot of the space on the right side is left blank.
*I usually open the general statistics as one of the first things when I start a new game, and then leave it open in a corner. If I do this, the slider intervals are not updated before I close it and open it again.
*Also, when middle-clicking/ctrl+left-clicking on the window title to hide it, it will crash the game.

Don't get me wrong, I think the slider is an enormous improvement. However, I would like to keep the player and category buttons as they were.

Also, sorry if this is posted twice, but my browser failed to submit it the first time, so I had to rewrite it (this is also why the image is posted before this comment)

Revision history for this message
Joachim Breitner (nomeata) wrote :

Thank for the test.

* The one-position slider. I considered to remove the slider if it only has one position, but then the window will look different at different points in time, which contradicts the principle of least surprise. Another option would be to always show the 15m option even when the "game" option also means 15min. That would be fine for me.

* That is (partly) intentional. I prefer the left-aligned buttons, which goes well with the wares statistic window (which is also filled from left to right), and is faster to use if you switch players off and on, due to less distance between them. Again, varying sizes of buttons contradict the principle of least surprised.

* That the slider does not update is known, but somewhat hard to fix with the current code. At least the "game" position will dynamically adjust. But I guess this point should be a bug report of its own.

* Hmm, at one point I tried that myself, and it worked. Maybe before the UI::Box refactoring. I’ll have a look once I’m done with what I’m doing right now, but maybe this should also be a bug report different from this one, which discusses the appearance of the window.

Revision history for this message
Joachim Breitner (nomeata) wrote :

Ok, fixed the crash from the last point, merge request linked with this bug.

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Hi, I've now split out the remaining bugs as:
* 887728
* 887730
* 887737

As this bug covers the slider in itself and that is implemented this is probably what I should have done in the first place. Thanks again for adding the slider. :)

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Sorry,
* bug 887728
* bug 887730
* bug 887737
should even include links.

Revision history for this message
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  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.