Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hours sum and percentage of viewed time period in Totals view #348

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

HWiese1980
Copy link

I needed to see the overall hours and the percentage of activities, categories and tags in the Totals view as hard numbers. I've added the values to the label of the corresponding bar graph in the Totals view. This might be of interest for others as well, so feel free to merge this contribution if you like.

Thanks!

for i, (label, value) in enumerate(self.values):
percent = 100.0 * hours[i] / total
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No error checking if self._total is not set (i.e. zero); in that case there will be a division by zero error here!

@omron93
Copy link

omron93 commented Feb 26, 2018

+1 Works fine for me. Thanks.

@elbenfreund
Copy link
Contributor

Thank you for your feedback, it is much appreciated.

Project hamster and its various sub-components is currently undergoing some major changes. We prepare the introduction of a rewritten codebase for most of the underlying functionality. A direct consequence of this is that it is unlikely that any open/new bugs within the current/old codebase will be fixed (unless someone steps up and offers to do so) as most resources currently available will be invested in making the rewrite prime time ready.

If you are still interested in working on the new codebase (repositories: hamster-lib/cli/gtk/dbus) we would be most thrilled. Please feel free to either open a new issue with the relevant repository and/or join the discussion on the mailinglist.
For more context please see our website.

Thanks for your interest and support! Eric.

@ederag
Copy link
Collaborator

ederag commented Dec 30, 2018

Thanks for your contribution.
I tried to merge that in august, while gathering fixes,
but the sums were not displayed, and the percentages took to much space.
This could be due to wrong merge choices on my part, or to changes in the UI.

The totals are displayed in the current master
(and already there in v2.1.1).
Having the percentages as numbers would be great as well,
but it should be an option, since space is short.

To be investigated again after the branch described in PR #302 is merged,
because it would affect the same parts.

@ederag ederag self-assigned this Dec 30, 2018
@ederag ederag added the design Design discussions and interesting use cases label Dec 30, 2018
@ederag
Copy link
Collaborator

ederag commented Mar 10, 2019

That would be a good time to add the percentages,
since I'm going going to work on other parts.
It should be an option, since space is short.

@projecthamster projecthamster deleted a comment from CLAassistant Mar 6, 2020
@matthijskooijman
Copy link
Member

There is a pending check for CLA that is not actually valid. Seems we can't remove it, so just ignore it (see also #589).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
design Design discussions and interesting use cases
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants