首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >如何更改ImageView的镜像?

如何更改ImageView的镜像?
EN

Stack Overflow用户
提问于 2011-02-23 17:56:12
回答 4查看 471.4K关注 0票数 152

我刚刚开始学习android。我不知道怎样才能改变ImageView的图像?即它有一些图像,这是在布局中设置的,但我想通过编码改变图像,我应该怎么做?

这是xml文件

代码语言:javascript
复制
<LinearLayout
  xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="fill_parent"
  android:layout_height="fill_parent"
  android:background="#cc8181"
 >

<ImageView
  android:id="@+id/image"
  android:layout_width="50dip"
  android:layout_height="fill_parent" 
  android:src="@drawable/icon"
  android:layout_marginLeft="3dip"
  android:scaleType="center"/>

感谢您的回复。

EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/5089300

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档