如何显示图片? [英] How to show a picture?

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

问题描述

我在调用图片查看一个问题。在我的应用程序后,他们单击我想带他们到一个新的页面,它会显示一个画面,并在它的一些文本的按钮。对于这个例子说,我想有一个峰,如果狗是在页面的顶部然后在它说,我想是这样的品种和养殖的成本。谁能帮我?

I'm having a problem calling a picture to view. In my app after they click the button i want to take them to a new page where it will display a picture and under it some text. For this example say i want a pic if dog to be at the top of the page then under it say i want something like the breed and the cost of breed. Can anyone help me?

推荐答案

使用这个XML为您的网页究竟会显示图像:

Use this XML for your page what will display the image:

<ImageView
    android:id="@+id/image"
    android:src="src"
/>
<TextView
    android:text="image text"
    android:layout_below ="@id/image"
 />

当然,添加更多选项的意见

Of course, add more options to the views

一些很好的参考:
http://developer.android.com/reference/android/widget/ImageView.html

http://developer.android.com/reference/android/widget/ TextView.html

http://developer.android.com/reference/android/widget/RelativeLayout.LayoutParams.html

这篇关于如何显示图片?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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