如何更改的ImageView动态的大小? [英] How to Change size of ImageView Dynamically?

查看:150
本文介绍了如何更改的ImageView动态的大小?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建一个动态表,其行包含的ImageView和一个TextView。我的问题是这样的ImageView正在采取原始图像的完整大小,但我想改变imageview.I的规模已经使用setLayoutParams有没有效果。
作为一种替代我也使用的TextView代替imageview的,并设置图像作为TextView的背景和用于setWidth并自动调用setHeight但它有同样的问题。
PLZ帮助我。

I am creating a dynamic table whose rows contains a imageview and a textview. My problem is this imageview is taking full size of original image but I want to change the size of imageview.I have used setLayoutParams which has no effect. As an alternative I also used textview instead of imageview and set image as textview's background and used setWidth and setHeight but it has the same problem. Plz Help Me.

推荐答案

OK我找到了解决办法。

OK I found the Solution

<一个href=\"http://stackoverflow.com/questions/4188763/resizing-an-imageview-within-a-tablelayout-programmatically\">Resizing一个TableLayout内的ImageView的编程

这篇关于如何更改的ImageView动态的大小?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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