解决方案 »
- 超炫的3D桌面,多种特效,TSF桌面演示版,现在分享给各位
- 求大牛指教:android调用webservice时出现问题
- 关于调用微信接口的问题
- android手机控制家电和灯
- 关于android手机显示显示多字段表格数据的问题
- 我做了个android intent的简单例子老是出错
- JAVA的byte[]转到 native中的 unsigned char的问题
- fragment之间通信
- 全屏手写输入法遮挡按钮该如何处理?
- android4.3, 如何修改让所有应用都竖屏显示
- 跪求ANDROID hello工程出错
- 【新人求助】我编写的Android Notification推送 只有声音 但在通知栏中没有推送的contentview 求大神解惑
确实是RelativeLayout的布局,很奇怪的问题。。
确实是RelativeLayout的布局,很奇怪的问题。。我这边这样写是没问题的,能否贴出你完整的布局代码?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="200dip"
> <ImageView
android:id="@+id/imageView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:layout_alignParentEnd="true"
android:padding="10dip"
android:src="@drawable/photo1"
android:scaleType="center"
/> <TextView
android:id="@+id/textView3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="36dp"
android:layout_marginLeft="36dp"
android:layout_marginStart="36dp"
android:layout_alignBottom="@+id/imageView1"
android:layout_alignLeft="@+id/imageView1"
android:layout_alignStart="@+id/imageView1"
android:background="#7f000000"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:textAppearance="?android:attr/textAppearanceSmallInverse"
/> <TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/textView3"
android:layout_alignLeft="@+id/textView3"
android:layout_alignStart="@+id/textView3"
android:layout_marginBottom="4dp"
android:background="#7f000000"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:textAppearance="?android:attr/textAppearanceMediumInverse"
/> <TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/textView2"
android:layout_alignLeft="@+id/textView2"
android:layout_alignStart="@+id/textView2"
android:layout_marginBottom="4dp"
android:background="#7f000000"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:textAppearance="?android:attr/textAppearanceLargeInverse"
/></RelativeLayout>
我也挺奇怪的,恩,可能是我这边eclipse问题。clean也无效的,就这样吧,结贴了,自己再研究研究.谢谢兄弟啦
前者应该是17以后才加上去的。
就向marginStart跟marginLeft,marginEnd跟marginRight。