大佬教程收集整理的这篇文章主要介绍了Android:如何使它在水平线性布局中的2个按钮之间没有空格,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://scheR_577_11845@as.android.com/apk/res/android" android:layout_width="fill_parent" android:orientation="horizontal" android:padding="0dp" android:layout_height="wrap_content" android:gravity="fill_horizontal" android:layout_margin="0dp"> <Button android:id="@+id/LOCATIOntitleButton" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginRight="0dp" android:layout_gravity="center_vertical" android:layout_weight="1" android:ellipsize="end" android:gravity="center_vertical" android:scrollHorizontally="true" android:singleLine="true" android:text="Add LOCATIOn" android:textStyle="bold" /> <Button android:textColor="#FF000000" android:layout_weight="0" android:id="@+id/AddLOCATIOnButton" android:text="Search" android:gravity="center_vertical" android:layout_gravity="center_vertical" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="0dp" /> </LinearLayout>
老回答:
只需将第@L_673_6@按钮的android:layout_marginRight设置为“-8dip”甚至更多.两个按钮之间的距离会变小.
以上是大佬教程为你收集整理的Android:如何使它在水平线性布局中的2个按钮之间没有空格全部内容,希望文章能够帮你解决Android:如何使它在水平线性布局中的2个按钮之间没有空格所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。