中显示下面的textview按钮,我有两个按钮在相同的位置,他们将根据可见性集执行他们的功能。现在我想将两个textviews 下面的按钮,我希望文本的意见是以下两个按钮,所以我用如何在下面的xml布局的relativeLayout
android:layout_below="@id/actConnect2_btn_connect"
,但在运行时,当连接按钮是可见的文本视图下方出现,如果双按钮是可见的它重叠
如何在两个按钮下面显示textview?
注:我知道我可以使用Android:布局:marginTop,但我想解决它,没有它
代码:
<Button
android:id="@+id/actConnect2_btn_pair"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/actConnect2_tv_label_devClass"
android:layout_centerInParent="true"
android:text="@string/str_pair"/>
<Button
android:id="@+id/actConnect2_btn_connect"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/str_connect"
android:layout_below="@+id/actConnect2_tv_label_devClass"
android:layout_alignParentStart="true" />
<TextView
android:id="@+id/actConnect2_tv_label_uuids"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/actConnect2_btn_connect"
android:text="Service's UUID: ">
</TextView>
<TextView
android:id="@+id/actConnect2_tv_uuids"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/actConnect2_tv_label_uuids">
</TextView>