futabooo blog

色々手をつけすぎてすぐに忘れるので備忘録

初めてのAndroidプログラミング備忘録(3)

前回書いてたやつを全部完成させた。
でもうまくいってない。

画像の赤丸の部分に隙間ができてしまうんですよね。

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:orientation="vertical" >

	<TextView
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:layout_marginTop="5dp"
		android:layout_marginBottom="5dp"
		android:text="お申し込みフォーム"
		android:textAppearance="?android:attr/textAppearanceLarge"  />

	<LinearLayout
	    xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:orientation="horizontal">
			<TextView
			    android:layout_width="70sp"
			    android:layout_height="wrap_content"
			    android:text="お名前:"/>
			<EditText
			    android:id="@+id/namae"
			    android:layout_width="200sp"
			    android:layout_height="wrap_content"/>
	</LinearLayout>

	<LinearLayout
		xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:orientation="horizontal">
			<TextView
			    android:layout_width="70sp"
			    android:layout_height="wrap_content"
			    android:text="住所:"/>
			<EditText
			    android:id="@+id/jyuusho"
			    android:layout_width="200sp"
			    android:layout_height="wrap_content"/>
	</LinearLayout>

	<LinearLayout
	    xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:orientation="horizontal">
			<TextView
			    android:layout_width="70sp"
			    android:layout_height="wrap_content"
			    android:text="生年月日:"/>
			<Spinner
			    android:id="@+id/seinengappi_tuki"
			    android:layout_width="wrap_content"
			    android:layout_height="wrap_content"
			    android:entries="@array/tuki" />
			<TextView
			    android:layout_width="wrap_content"
			    android:layout_height="wrap_content"
			    android:text="月"/>
			<Spinner
			    android:id="@+id/seinengappi_nichi"
			    android:layout_width="wrap_content"
			    android:layout_height="wrap_content"
			    android:entries="@array/nichi" />
			<TextView
			    android:layout_width="wrap_content"
			    android:layout_height="wrap_content"
			    android:text="日"/>
	</LinearLayout>

	<LinearLayout
	    xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:orientation="horizontal">
			<TextView
			    android:layout_width="70sp"
			    android:layout_height="wrap_content"
			    android:layout_marginTop="10dp"
			    android:text="性別:"/>
			<RadioGroup
				android:layout_width="match_parent"
				android:layout_height="wrap_content"
				android:orientation="horizontal">
					<RadioButton
					    android:id="@+id/male"
					    android:layout_width="wrap_content"
					    android:layout_height="wrap_content"
					    android:text="男" />
					<RadioButton
					    android:id="@+id/female"
					    android:layout_width="wrap_content"
					    android:layout_height="wrap_content"
					    android:text="女" />
			</RadioGroup>
	</LinearLayout>

	<LinearLayout
		xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:layout_marginLeft="50sp"
		android:layout_marginRight="50sp"
		android:background="#003399"
		android:orientation="horizontal" >
		<TextView
		    android:layout_width="wrap_content"
			android:layout_height="wrap_content"
			android:paddingRight="100sp"
			android:text="希望商品"/>
		<TextView
			android:layout_width="wrap_content"
			android:layout_height="wrap_content"
			android:text="注文数量"/>
	</LinearLayout>

	<LinearLayout
		xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:layout_marginLeft="50sp"
		android:layout_marginRight="50sp"
		android:orientation="horizontal" >
		<CheckBox
		    android:id="@+id/ringo"
		    android:layout_width="100dp"
		    android:layout_height="wrap_content"
		    android:layout_marginRight="70sp"
		    android:text="りんご" />
		<EditText
		    android:id="@+id/ringokazu"
		    android:layout_width="40dp"
		    android:layout_height="wrap_content" />
	</LinearLayout>>

	<LinearLayout
		xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:layout_marginLeft="50sp"
		android:layout_marginRight="50sp"
		android:orientation="horizontal" >
		<CheckBox
		    android:id="@+id/mikan"
		    android:layout_width="100dp"
		    android:layout_height="wrap_content"
		    android:layout_marginRight="70sp"
		    android:text="みかん" />
		<EditText
		    android:id="@+id/mikankazu"
		    android:layout_width="40dp"
		    android:layout_height="wrap_content" />
	</LinearLayout>>

	<LinearLayout
		xmlns:android="http://schemas.android.com/apk/res/android"
		android:layout_width="match_parent"
		android:layout_height="wrap_content"
		android:layout_marginLeft="50sp"
		android:layout_marginRight="50sp"
		android:orientation="horizontal" >
		<CheckBox
		    android:id="@+id/momo"
		    android:layout_width="100dp"
		    android:layout_height="wrap_content"
		    android:layout_marginRight="70sp"
		    android:text="もも" />
		<EditText
		    android:id="@+id/momokazu"
		    android:layout_width="40dp"
		    android:layout_height="wrap_content" />
	</LinearLayout>>

	<Button
	    android:id="@+id/soushin"
	    android:layout_gravity="center_horizontal"
	    android:layout_width="150dp"
	    android:layout_height="wrap_content"
	    android:text="送信" />
</LinearLayout>

f:id:futabooo:20120124121653p:image