Logo Search packages:      
Sourcecode: zope-photo version File versions

def zope-photo-1.2.3::Photo::Photo::_getAspectRatioSize (   self,
  width,
  height 
) [private]

Return proportional dimensions within desired size.

Definition at line 408 of file Photo.py.

00408                                                 :
        """Return proportional dimensions within desired size."""
        img_width, img_height = (self.width(), self.height())
        if height > img_height * width / img_width:
            height = img_height * width / img_width
        else:
            width =  img_width * height / img_height
        return (width, height)

    def _validImage(self):


Generated by  Doxygen 1.6.0   Back to index