Only the first nested linear layout is showing up, any idea why? The first textView inside the 2nd linear layout shows up, and the layout is the proper height, but none if it’s contents can be viewed.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:weightSum="100">
<LinearLayout
android:id="@+id/linearLayout3"
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
<TextView
android:layout_width="fill_parent"
android:layout_height="42dp"
android:background="#FAFA25"
android:height="200dp"
android:text="@string/hello"
android:textColor="#222222"
android:textSize="20dp" />
<LinearLayout
android:id="@+id/linearLayout1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp" >
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/width" />
<EditText
android:id="@+id/editText1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:inputType="number" >
<requestFocus />
</EditText>
</LinearLayout>
<TextView
android:id="@+id/textView4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:text="@string/totalWidth"
android:layout_marginRight="10dp" />
<LinearLayout
android:id="@+id/linearLayout2"
android:layout_height="wrap_content"
android:background="#999999"
android:layout_width="fill_parent"
android:layout_margin="10dp"
android:padding="4dp"
android:weightSum="100" >
<TextView
android:id="@+id/textView5"
android:layout_width="fill_parent"
android:layout_height="50dp"
android:text="@string/numOne"
android:layout_weight="62"
android:background="#ffffff"
android:gravity="center"
android:textColor="#222222"
android:layout_marginRight="1dp" />
<TextView
android:id="@+id/textView6"
android:layout_width="fill_parent"
android:layout_height="50dp"
android:text="@string/numTwo"
android:background="#ffffff"
android:layout_weight="38"
android:gravity="center"
android:textColor="#222222"
/>
</LinearLayout>
<Button
android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:text="Calculate" />
</LinearLayout>
</LinearLayout>
linearLayout3 , orientation is horizontal, in case you are wondering why, default orientation is horizontal. and since textView has layout_width=”fill_parent”, the next child will not show up.
change the orientation to vertical.