summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWolfgang Rohdewald <wolfgang@rohdewald.de>2016-08-13 10:30:24 (GMT)
committerWolfgang Rohdewald <wolfgang@rohdewald.de>2016-08-24 11:47:04 (GMT)
commit78e8340661e6f7d5b4ea397dafaa2d2f9e25c744 (patch)
tree34f9a379f49365a1546755e133574f7f6654ea37
parent274cd2b84767abfd0a90d6e60c24e25afe3223d0 (diff)
Debug / explain: show limit without decimals .0
-rw-r--r--src/rule.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/rule.py b/src/rule.py
index 9da4c3f..95eee25 100644
--- a/src/rule.py
+++ b/src/rule.py
@@ -100,7 +100,10 @@ class Score(object):
if self.doubles:
parts.append(m18nc('Kajongg', '%1 doubles', self.doubles))
if self.limits:
- parts.append(m18nc('Kajongg', '%1 limits', self.limits))
+ limits = str(self.limits)
+ if limits.endswith('.0'):
+ limits = limits[-2:]
+ parts.append(m18nc('Kajongg', '%1 limits', limits))
return u' '.join(parts)
def __eq__(self, other):