状況
androidでレイアウトを作成しているときに、画面の領域がナビゲーションバーに
重なってしまいます。これの解消法を教えていただけないでしょうか
よろしくお願いいたします。
コード
xml
1<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" 2 xmlns:app="http://schemas.android.com/apk/res-auto" 3 android:layout_width="match_parent" 4 android:layout_height="match_parent"> 5 6 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 7 xmlns:app="http://schemas.android.com/apk/res-auto" 8 android:layout_width="match_parent" 9 android:layout_height="match_parent" 10 android:orientation="vertical"> 11 12 <android.support.v7.widget.Toolbar 13 android:id="@+id/toolbar" 14 android:layout_width="match_parent" 15 android:layout_height="?actionBarSize" 16 android:layout_gravity="right|top" 17 android:layout_marginTop="@dimen/status_bar_margin_top" 18 android:background="?attr/colorPrimary" 19 android:elevation="5dp" 20 app:popupTheme="@style/ThemeOverlay.AppCompat.Light" 21 app:theme="@style/ToolbarTheme" /> 22 23 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 24 xmlns:app="http://schemas.android.com/apk/res-auto" 25 android:layout_width="match_parent" 26 android:layout_height="match_parent" 27 android:orientation="vertical" 28 android:padding="16dp"> 29 30 <EditText 31 android:id="@+id/editTitle" 32 android:layout_width="match_parent" 33 android:layout_height="wrap_content" 34 android:background="#00000000" 35 android:textColor="#333333" 36 android:textSize="20dp" 37 android:layout_marginBottom="10dp" 38 android:inputType="text" 39 android:hint="title"/> 40 41 <EditText 42 android:id="@+id/editDescription" 43 android:layout_width="match_parent" 44 android:layout_height="wrap_content" 45 android:background="#00000000" 46 android:ems="10" 47 android:inputType="textMultiLine" 48 android:textColor="#666666" 49 android:hint="description"/> 50 </LinearLayout> 51 </LinearLayout> 52 <android.support.design.widget.FloatingActionButton 53 android:id="@+id/fab" 54 android:layout_width="wrap_content" 55 android:layout_height="wrap_content" 56 android:layout_gravity="bottom|end" 57 android:layout_margin="@dimen/fab_margin" 58 android:src="@android:drawable/ic_dialog_email" /> 59</FrameLayout> 60