直接贴出来我想要的效果吧。可能我的思路从开始就错的。
如题。问题我知道出在哪。就是布局的冲突了。但是实在想不好别的写法能替代了。
也查不到有人提出过对此的好的解决办法。
倒是可以直接在代码里写布局。这样理论上没啥写不出来的布局了。不过我还是尽量不想在代码里处理布局问题了。
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<!--用于显示图标的imageView-->
<ImageView
android:layout_width="80sp"
android:layout_height="80sp"
android:layout_marginRight="@dimen/small_circle_radius_half"
android:layout_marginTop="@dimen/small_circle_radius_half"
android:scaleType="fitXY"
android:id="@+id/linearLayoutContainer">
</ImageView>
<!--右上角的红叉-->
<ImageView
android:layout_width="@dimen/small_circle_radius"
android:layout_height="@dimen/small_circle_radius"
android:scaleType="fitXY"
android:src="@drawable/delete"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"/>
</RelativeLayout>