Rails Paperclip插件 - 调整大小的样式选项 [英] Rails Paperclip Plugin - Style Options for Resizing

查看:188
本文介绍了Rails Paperclip插件 - 调整大小的样式选项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以,我想将图像调整为FIXED宽度,但比例高度。

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<

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

他们都没有期望的效果。有帮助吗?我希望它填充或调整宽度为380,然后调整高度/缩小高度,使其缩小或调整图像大小为380宽。

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.

推荐答案

尝试使用380x

这应该将宽度调整为380px并保持原始宽高比。

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

有关调整图像大小的所有可用选项,请转到此处: http://www.imagemagick.org/script/command-line-processing.php?ImageMagick=lj6pre8q2iautc3ch6nuph1fc2#geometry

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

这篇关于Rails Paperclip插件 - 调整大小的样式选项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆