Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/Theme.py
diff options
context:
space:
mode:
Diffstat (limited to 'Theme.py')
-rw-r--r--Theme.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/Theme.py b/Theme.py
index 3f7f9b9..a970c79 100644
--- a/Theme.py
+++ b/Theme.py
@@ -20,8 +20,9 @@ from sugar.activity.activity import get_bundle_path
TRANSIMG = '50x50blank-trans.png'
BGHEIGHT = gtk.gdk.screen_height() - 450 # 425
BGWIDTH = BGHEIGHT # 425
-IMGHEIGHT = 100
-IMGWIDTH = 100
+
+IMGHEIGHT = min(100, gtk.gdk.screen_height() / 8)
+IMGWIDTH = IMGHEIGHT
IMGSIZE = (IMGWIDTH, IMGHEIGHT)
BORDER_LEFT = 1
@@ -78,8 +79,7 @@ def path(file):
return os.path.join(get_bundle_path(), file)
def pixmap(file, numberr_in_set = None):
- out = gtk.gdk.pixbuf_new_from_file(path(file))
- out = out.scale_simple(IMGWIDTH, IMGHEIGHT, gtk.gdk.INTERP_BILINEAR)
+ out = gtk.gdk.pixbuf_new_from_file_at_size(path(file), IMGWIDTH, IMGHEIGHT)
return out
# customize theme