سلام و عرض خسته نباشید
بعد از اضافه کردن DrawerLayout به صفحه اصلی . طراحی به هم خورد ممنون میشم راهنمایی فرمایید .
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center">
<include
android:id="@+id/toolbar"
layout="@layout/myToolBarRed"
android:layout_margin="2dp" />
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<!--لاین اول-->
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/linearLayout1"
android:layout_marginBottom="25dp"
android:gravity="center">
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout2"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_addstudent"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnAddStudent"
android:background="@color/background_floating_material_light" />
<TextView
android:text="ثبت نام"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout3"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_login"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnLogin"
android:background="@color/background_floating_material_light" />
<TextView
android:text="ورود"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout4"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_news"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnNews"
android:background="@color/background_floating_material_light" />
<TextView
android:text="اخبار"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
</LinearLayout>
<!--لاین دوم-->
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/linearLayout1"
android:layout_marginBottom="25dp"
android:gravity="center">
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout2"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_Gallery"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnGallery"
android:background="@color/background_floating_material_light" />
<TextView
android:text="گالری تصاویر"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout3"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_Courses"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnCourse"
android:background="@color/background_floating_material_light" />
<TextView
android:text="دوره ها"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout4"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_Contact"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnContact"
android:background="@color/background_floating_material_light" />
<TextView
android:text="تماس با ما"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
</LinearLayout>
<!--لاین سوم-->
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/linearLayout1"
android:gravity="center">
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout2"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_About"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnAbout"
android:background="@color/background_floating_material_light" />
<TextView
android:text="درباره ما"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout3"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_Location"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnLocation"
android:background="@color/background_floating_material_light" />
<TextView
android:text="نقشه"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/linearLayout4"
android:layout_margin="5dp"
android:layout_weight="3"
android:gravity="center"
android:background="@drawable/ShapeBorderMainMenu">
<ImageButton
android:src="@drawable/ic_Website"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/btnWebsite"
android:background="@color/background_floating_material_light" />
<TextView
android:text="وب سایت"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/txtMenuNews"
android:gravity="center"
android:layout_margin="3dp"
style="@style/DialogMessageText" />
</LinearLayout>
</LinearLayout>
<!--Navigation Right Drawer -->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center">
</LinearLayout>
<!--END Navigation Right Drawer -->
</android.support.v4.widget.DrawerLayout>
</LinearLayout>
قبل از اضافه کردن DrawerLayout
بعد از اضافه کردن DrawerLayout