制作一个按钮更容易点击 [英] Making a button easier to click

查看:165
本文介绍了制作一个按钮更容易点击的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个按钮,在某些手机太难点击,因为它的大小。

I have a button that on certain phones is too hard to click because of its size.

但它放大休息的布局。

有可能解释一个观点,即它有一个更大的单击框比它的可视面积?

It is possible to explain to a view that it has a bigger "click box" than its visible area?

推荐答案

不知道这是否可以帮助:

Not sure if this can help:

如果你使用没有背景的ImageButton的并设置填充值,你的按钮将有较大的点击区域。

If you use an ImageButton with no background and you set a Padding value, your button will have a larger clickable area.

<ImageButton android:layout_width="wrap_content" android:layout_height="wrap_content" 
    android:src="@drawable/img_close" android:id="@+id/btnClose" 
    android:padding="25dip" android:background="#0000"></ImageButton>

这篇关于制作一个按钮更容易点击的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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