[Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-24 Thread godiard
From: Gonzalo Odiard generates a preview image with a fixed size and proportions. if the original image is bigger scale down and center the image, if is smaller center the image the supported format files are checked with pixbuf_get_formats --- downloadmanager.py | 45

Re: [Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-24 Thread Gonzalo Odiard
ignore this patch. I am doing anything wrong with git Gonzalo On Fri, Sep 24, 2010 at 10:44 AM, wrote: > From: Gonzalo Odiard > > generates a preview image with a fixed size and proportions. > if the original image is bigger scale down and center the image, if is > smaller center the image > t

[Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-24 Thread godiard
From: Gonzalo Odiard generates a preview image with a fixed size and proportions. if the original image is bigger scale down and center the image, if is smaller center the image the supported format files are checked with pixbuf_get_formats this patch adressed comments from silbe about segregat

Re: [Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-23 Thread Gonzalo Odiard
> > +if (width > preview_width) or (height > preview_height): > > +scale_x = float(width) / preview_width > > +scale_y = float(height) / preview_height > > +scale = max(scale_x, scale_y) > > + > > +pixbuf = pixbuf.scale_simple(float(width) / s

Re: [Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-23 Thread Sascha Silbe
Excerpts from godiard's message of Thu Sep 23 15:42:15 +0200 2010: > this patch adressed comments from silbe about segregate the check of a image > mime type and use of sugar.style constant colors > now opens the image in the original size because we don't want scale up small > images > also i d

Re: [Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-23 Thread Tomeu Vizoso
On Wed, Sep 22, 2010 at 17:44, wrote: > From: Gonzalo Odiard > > this patch adressed comments from silbe about segregate the check of a image > mime type and use of sugar.style constant colors > now opens the image in the original size because we don't want scale up small > images Just two sm

[Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-23 Thread godiard
From: Gonzalo Odiard this patch adressed comments from silbe about segregate the check of a image mime type and use of sugar.style constant colors now opens the image in the original size because we don't want scale up small images also i did changes sugested by simon --- downloadmanager.py |

Re: [Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-23 Thread Simon Schampijer
On 09/22/2010 05:44 PM, godi...@sugarlabs.org wrote: > From: Gonzalo Odiard > > this patch adressed comments from silbe about segregate the check of a image > mime type and use of sugar.style constant colors > now opens the image in the original size because we don't want scale up small > images

[Sugar-devel] [PATCH] implements http://bugs.sugarlabs.org/ticket/1106 - Browse: No preview in Journal for downloaded image

2010-09-22 Thread godiard
From: Gonzalo Odiard this patch adressed comments from silbe about segregate the check of a image mime type and use of sugar.style constant colors now opens the image in the original size because we don't want scale up small images --- downloadmanager.py | 46