亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

計算器界面布局問題,請問這是怎么回事?

計算器界面布局問題,請問這是怎么回事?

乂言 2016-07-04 13:32:56
為什么下面的布局代碼會造就這樣的界面? 請教大神問題出在哪里?<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"? ? xmlns:tools="http://schemas.android.com/tools"? ? android:id="@+id/LinearLayout1"? ? android:layout_width="match_parent"? ? android:layout_height="match_parent"? ? android:gravity="center_horizontal"? ? android:orientation="vertical"? ? tools:context="${relativePackage}.${activityClass}" >? ? <TableLayout? ? ? ? android:layout_marginTop="8dp"? ? ? ? android:layout_width="match_parent"? ? ? ? android:layout_height="wrap_content"? ? ? ? android:stretchColumns="*"? ? ? ? ?>? ? ? ? <TableRow? ? ? ? ? ? android:id="@+id/tableRow1"? ? ? ? ? ? android:layout_width="wrap_content"? ? ? ? ? ? android:layout_height="wrap_content"?? ? ? ? ? ? android:gravity="center_horizontal"?>? ? ? ? ? ? <Button? ? ? ? ? ? ? ? android:id="@+id/btnClean"? ? ? ? ? ? ? ? android:layout_width="wrap_content"? ? ? ? ? ? ? ? android:layout_height="wrap_content"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/lgray_selector"? ? ? ? ? ? ? ? android:text="C" />? ? ? ? ? ? 省略……? ? ? ? </TableRow>? ? ? ? <TableRow? ? ? ? ? ? android:id="@+id/tableRow2"? ? ? ? ? ? android:layout_width="wrap_content"? ? ? ? ? ? android:layout_height="wrap_content"? ? ? ? ? ? android:gravity="center_horizontal" >? ? ? ? ? ? <Button? ? ? ? ? ? ? ? android:id="@+id/btn7"? ? ? ? ? ? ? ? android:layout_width="wrap_content"? ? ? ? ? ? ? ? android:layout_height="wrap_content"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector"? ? ? ? ? ? ? ? android:text="7" />? ? ? ? ? ? 省略……? ? ? ? </TableRow>? ? ? ? <TableRow? ? ? ? ? ? android:id="@+id/tableRow3"? ? ? ? ? ? android:layout_width="wrap_content"? ? ? ? ? ? android:layout_height="wrap_content"? ? ? ? ? ? android:gravity="center_horizontal" >? ? ? ? ? ? <Button? ? ? ? ? ? ? ? android:id="@+id/btn4"? ? ? ? ? ? ? ? android:layout_width="wrap_content"? ? ? ? ? ? ? ? android:layout_height="wrap_content"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector"? ? ? ? ? ? ? ? android:text="4" />? ? ? ? ? ? 省略……? ? ? ? </TableRow>? ? </TableLayout>? ? ? ? <LinearLayout ? ? ? ?android:layout_width="match_parent" ? ? ? ?android:layout_height="wrap_content" ? ? ? ?android:gravity="center_horizontal" ? ? ? ?android:orientation="horizontal" > ? ?<LinearLayout ? ? ? ?android:layout_width="0dp" ? ? ? ?android:layout_height="match_parent" ? ? ? ?android:layout_weight="3" ? ? ? ?android:orientation="vertical" > ? ? ? ?<LinearLayout ? ? ? ?android:layout_width="fill_parent" ? ? ? ?android:layout_height="wrap_content" ? ? ? ?android:gravity="center_horizontal" ? ? ? ?android:layout_weight="2" > <TableLayout? ? ?android:layout_width="match_parent" ? ?android:layout_height="match_parent" ? ?android:stretchColumns="*" > ? ?<TableRow ? ? ? ?android:layout_width="match_parent" ? ? ? ?android:layout_height="match_parent" > ? ? ? ? ? ?<Button ? ? ? ? ? ? ? ?android:id="@+id/btn1"? ? ? ? ? ? ? ? android:layout_width="wrap_content" ? ? ? ? ? ? ? ?android:layout_height="wrap_content"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector" ? ? ? ? ? ? ? ?android:text="1" /> ? ? ? ? ? ?<Button ? ? ? ? ? ? ? ?android:id="@+id/btn2"? ? ? ? ? ? ? ? android:layout_width="wrap_content" ? ? ? ? ? ? ? ?android:layout_height="wrap_content"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector" ? ? ? ? ? ? ? ?android:text="2" /> ? ? ? ? ? ?<Button ? ? ? ? ? ? ? ?android:id="@+id/btn3"? ? ? ? ? ? ? ? android:layout_width="wrap_content" ? ? ? ? ? ? ? ?android:layout_height="wrap_content"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector" ? ? ? ? ? ? ? ?android:text="3" /> ? ? ? ? ? ?</TableRow> ? ? ? ? ? ?</TableLayout> ? ? ? ?</LinearLayout> <LinearLayout ? ? ? ?android:layout_width="match_parent" ? ? ? ?android:layout_height="wrap_content" ? ? ? ?android:gravity="center_horizontal" ? ? ? ?android:layout_weight="2" > ? ?<TableLayout? ? ?android:layout_width="match_parent" ? ?android:layout_height="match_parent" ? ?android:stretchColumns="*" > ? ?<TableRow ? ? ? ?android:layout_width="match_parent" ? ? ? ?android:layout_height="match_parent" > ? ? ? ? ? ?<Button ? ? ? ? ? ? ? ?android:id="@+id/btn0"? ? ? ? ? ? ? ? android:layout_width="wrap_content" ? ? ? ? ? ? ? ?android:layout_height="match_parent"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector"? ? ? ? ? ? ? ? android:layout_span="2" ? ? ? ? ? ? ? ?android:text="0" ?/> ? ? ? ? ? ?<Button ? ? ? ? ? ? ? ?android:id="@+id/btnDot"? ? ? ? ? ? ? ? android:layout_width="wrap_content" ? ? ? ? ? ? ? ?android:layout_height="match_parent"? ? ? ? ? ? ? ? android:height="70dp"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/white_selector" ? ? ? ? ? ? ? ?android:text="." /> ? ? ? ? ? ?</TableRow> ? ? ? ? ? ?</TableLayout> ? </LinearLayout> ? </LinearLayout>? ? ? ?<Button ? ? ? ? ? ?android:id="@+id/btnEqual" ? ? ? ? ? ?android:layout_width="0dp" ? ? ? ? ? ? ? ?android:layout_height="match_parent"? ? ? ? ? ? ? ? android:textSize="22sp"? ? ? ? ? ? ? ? android:layout_weight="1"? ? ? ? ? ? ? ? android:layout_margin="3dp"? ? ? ? ? ? ? ? android:background="@drawable/orange_selector" ? ? ? ? android:text="=" /> </LinearLayout></LinearLayout>
查看完整描述

2 回答

?
冷雨夜2015

TA貢獻8條經驗 獲得超1個贊

3個月了,不用回答了把,哈哈

查看完整回答
反對 回復 2016-07-04
  • 乂言
    乂言
    3個月?!我今天剛問的?。≌埥塘?!
  • 2 回答
  • 0 關注
  • 1494 瀏覽

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號