其中Android的控制使用? [英] Which Android control to use?

查看:112
本文介绍了其中Android的控制使用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我要带在Android的编程我的第一个步骤。

I'm taking my first steps in Android programming.

我的应用是在数据库中创建条目。对于这个任务,我创建了一个新的活动。一切都很好 - 但我真的不喜欢它的外观

My application is to create entries in a database. For this task I have created a new Activity. All is fine - but I don't really like how it looks.

目前,模拟器显示了这个:

Currently, the emulator shows this:

我想有类似的新建联系人活动:

I'd like to have something similar to the "New Contact" Activity:

  • 按钮,在窗口的底部,而不是直接低于其他控件(我希望可以认识到这一点我自己)
  • 在一个漂亮的盒子一样显示在屏幕截图按钮(这是什么在这里举办的按钮控制?)
  • 当显示软键盘,按键要动起来。如果没有足够的空间,整个区域应该是滚动的(我会尽力弄清这一点我自己太)

样品可以在这里看到:

Sample can be seen here:

其中控制主机上面的新建联系人截图按钮?我想用相同的我的按钮。

Which control hosts the buttons in the above "New contact" screenshot? I'd like to use the same for my buttons.

推荐答案

联系人布局看起来像一个ListView坐在某种RelativeLayout的或的LinearLayout住房按钮的上方。背景上的布局本身(布局视图)

The contacts layout looks like a ListView sitting on top of some sort of RelativeLayout or LinearLayout housing the buttons. The silver background may simply have been set using android:background on the Layout itself (layouts are views).

我发现 commonsware 的书是优秀的资源入门并且对这种布局的很好的例子。

I found that the commonsware books are excellent resources for getting started and have good examples for this type of layout.

这篇关于其中Android的控制使用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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