Android相对布局 layout_marginBottom无效
2017-08-09 17:51
585 查看
Android 相对布局使用了layout_marginBottom 无效
需要在下面添加布局,如下:
在下面添加了宽高都为0的布局了,layout_marginBottom有效,能正确显示了
需要在下面添加布局,如下:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <ImageView android:id="@+id/the_iv" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="8dp"/> <View android:layout_width="0px" android:layout_height="0px" android:layout_below="@id/the_iv"/> </RelativeLayout>
在下面添加了宽高都为0的布局了,layout_marginBottom有效,能正确显示了
相关文章推荐
- 关于Android相对布局中的四个属性:layout_alignTop,layout_alignBottom,layout_above,layout_below的分析
- 解决android:layout_marginBottom在RelativeLayout中无效的问题
- 解决android:layout_marginBottom在RelativeLayout中无效的bug
- listView 中relativeLayout 布局的 android:layout_alignParentBottom="true" 无效的解决办法
- listView 中relativeLayout 布局的 android:layout_alignParentBottom="true" 无效的解决办法
- 解决android:layout_marginBottom在RelativeLayout中无效的问题
- Android布局---相对布局(Relative Layout)
- Android布局(线性布局 Linear Layout )(相对布局 Relative Layout)
- Android RelativeLayout(相对布局)
- Android 基础 RelativeLayout相对布局
- android 动态调整RelativeLayout布局控件的相对位置 layout_toLeftOf 之类的
- android RelativeLayout(相对布局)常用属性
- Android 1.5和Android 2.1在相对布局(RelativeLayout)上的区别
- Android-相对布局(RelativeLayout)
- Android:控件布局(相对布局)RelativeLayout
- ListView的item中RelativeLayout内view的layout_marginBottom无效的问题
- Android开发重点难点1:RelativeLayout(相对布局)详解
- 第13章、布局Layouts之RelativeLayout相对布局(从零開始学Android)
- Android开发教程 --- 布局(线性布局 Linear Layout )(相对布局 Relative Layout)
- 第13章、布局Layouts之RelativeLayout相对布局(从零开始学Android)