[hamster-applet] the tag background size was relative to the text width although it should have been relative to text
- From: Toms Baugis <tbaugis src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [hamster-applet] the tag background size was relative to the text width although it should have been relative to text
- Date: Fri, 13 Aug 2010 19:08:36 +0000 (UTC)
commit 00c720507c4d1da0adc0096f25b539c85eb10d8d
Author: Toms Bauģis <toms baugis gmail com>
Date: Fri Aug 13 20:08:28 2010 +0100
the tag background size was relative to the text width although it should have been relative to text height
src/hamster/widgets/tags.py | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/hamster/widgets/tags.py b/src/hamster/widgets/tags.py
index 904b26c..67b743a 100644
--- a/src/hamster/widgets/tags.py
+++ b/src/hamster/widgets/tags.py
@@ -319,9 +319,9 @@ class Tag(graphics.Sprite):
label = graphics.Label(text, size = font_size, color = (30, 30, 30), y = 2)
- w, h = int((label.width + 8) * 1.3), label.height + 3
- corner = h / 3
- label.x = corner + 8
+ corner = (label.height + 3) / 3
+ label.x = corner + 6
+ w, h = int(label.x + label.width + label.height * 0.3), label.height + 3
self.color = color
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]