diff --git a/src/plugins/DefaultGramplets.py b/src/plugins/DefaultGramplets.py index fcccd9032..5a85564ea 100644 --- a/src/plugins/DefaultGramplets.py +++ b/src/plugins/DefaultGramplets.py @@ -370,7 +370,7 @@ class SurnameCloudGramplet(Gramplet): size = make_tag_size(count, counts) self.link(text, 'Surname', representative_handle[surname], size, "%s, %d%% (%d)" % (text, - int((float(count)/total_surnames) * 100), + int((float(count)/total_people) * 100), count)) self.append_text(" ") showing += 1 diff --git a/src/plugins/GivenNameGramplet.py b/src/plugins/GivenNameGramplet.py index 56c56155d..51bd42e81 100644 --- a/src/plugins/GivenNameGramplet.py +++ b/src/plugins/GivenNameGramplet.py @@ -120,9 +120,10 @@ class GivenNameCloudGramplet(Gramplet): text = givensubname size = make_tag_size(count, counts) self.link(text, 'Given', text, size, - "%s, %d%% (%d)" % (text, - int((float(count)/total_givensubnames) * 100), - count)) + "%s, %.2f%% (%d)" % + (text, + (float(count)/total_people) * 100, + count)) self.append_text(" ") showing += 1 self.append_text(("\n\n" + _("Total unique given names") + ": %d\n") %