-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
如何设置图片的高度 #37
Comments
v1版本的时候是支持传入图片宽度和高度参数,v2版本没有高度参数了,请问指定图片的高度? |
v1 版本也是无法设置的。图片的高度会根据原图比例进行自适应计算,可避免图片发生形变。请问是什么样的需求呢? |
是这样的场景 ,我需要合成一张海报,上面是一张主图,下面会配置相应的文字, |
这个场景下,你应该提前加载获取下图片的尺寸,然后根据宽度等比计算下放入海报后的高度,就能准确知道文字应该在的位置了。如果固定宽高,可能会导致图片发生形变。 |
好的,谢谢 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
如何设置图片的高度?
The text was updated successfully, but these errors were encountered: