文字left,按钮right,edittext在文字right,在按钮left。这样就満了。
父布局:relativelayout
父布局:relativelayout
解决方案 »
- android输入遮挡问题
- 如何在android中画一条竖线将整个屏幕分成两个部分
- android如何获取手指在TextView上面滑动的距离?
- sqlite查询问题
- android opengle es 学习资料共享
- 切换语言时重走onCreat,怎么保存CheckedTextView的选中状态?
- ViewPager和Fragment
- CSipSimple视频窗口
- ListView中嵌套ViewPager(ViewPager是item的一部分),并且存在判断位置的小白点。
- 怎么在非activity使用数据库
- android 4.4源码下载——百度云盘地址
- activity回退finish关闭后,fragment开启的线程导致空指针异常??
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"> <TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content" /> <EditText
android:layout_width="0dp"
android:layout_height="wrap_content" /
android:layout_weight="1"> <TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content" /> </LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<EditText
android:layout_width="wrap_content"
android:layout_height="wrap_content" /
android:layout_weight="1">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</LinearLayout>
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity" > <TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_marginTop="144dp"
android:text="@string/hello_world" /> <EditText
android:id="@+id/editText1"
android:layout_width="150dp"
android:layout_height="wrap_content"
android:layout_alignTop="@+id/textView1"
android:layout_toRightOf="@+id/textView1"
android:ems="10" > <requestFocus />
</EditText> <Button
android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="0dp"
android:layout_alignBottom="@+id/editText1"
android:layout_alignParentRight="true"
android:text="Button" /></RelativeLayout>