Rails Paperclip Plugin - Style Options for Resizing

Jonathan Soeder picture Jonathan Soeder · Jun 16, 2010 · Viewed 13.5k times · Source

So, I want to resize images to a FIXED width, but proportional height.

I have been trying a wide range of operators:

380x242# 380x242> 380!x242 380x242<

none of them have the desired effect. Any help? I want it to fill or resize to the 380 width, then resize / shrink the height by the same factor it used to shrink or resize the image to 380 wide.

Answer

Slobodan Kovacevic picture Slobodan Kovacevic · Jun 16, 2010

Try using 380x

This should resize width to 380px and keep original aspect ratio.

For all available options for resizing images go here: http://www.imagemagick.org/script/command-line-processing.php?ImageMagick=lj6pre8q2iautc3ch6nuph1fc2#geometry