新手自学安卓按照书本中的要求 代码如下
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical" >
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="24dp"
android:text="@string/question_text" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal" >
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/true_button" />
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/false_button" />
</LinearLayout>
Android sdk有没有添加~不行就贴完整代码
xmlns:android,你这个写错了。要么你下面android:...这些都改成adroid:....
xmlns:xxx是用来申明下面的属性值用什么名称去获取
先学会Android的正确拼写
你把最上面的xmlns:后面的adroid改成android