diff options
author | Aleksey Lim <alsroot@member.fsf.org> | 2009-01-19 23:09:56 (GMT) |
---|---|---|
committer | Aleksey Lim <alsroot@member.fsf.org> | 2009-01-21 11:51:11 (GMT) |
commit | 2f6cfeaa40169abc01069a2ee98134d474ca632b (patch) | |
tree | d48b37fd1037d1930e15e7917e4fe867952c8cef /Theme.py | |
parent | 5a6b5821d3403bfd0ee41781bf3fe6e645d7a027 (diff) |
...
Diffstat (limited to 'Theme.py')
-rw-r--r-- | Theme.py | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -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 |