FragmentTabHost 底部上边距,设置分割线的话,出现空隙!!找不到原因在哪里
1. 我尝试设置了设置margin 和padding,没有用
android:layout_margin="0dp"
android:padding="0dp"
2: 在原先的基础上继续套了一层布局解决了问题
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
>
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
>
<View
android:layout_width="match_parent"
android:layout_height="0.4dp"
android:layout_alignParentTop="true"
android:background="@color/bg_gray_80"
/>
<ImageView
android:id="@+id/imageview"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:layout_marginBottom="@dimen/d4"
android:layout_marginTop="@dimen/d5"
android:focusable="false"
android:src="@mipmap/ic_launcher"></ImageView>
</RelativeLayout>
</RelativeLayout>