Skip to content
This repository was archived by the owner on Mar 3, 2023. It is now read-only.

Android_Menu

Miroslav Smukov edited this page Jul 17, 2016 · 3 revisions

Menu

I'm actually going to simplify the Navigation Drawer (or Menu) in my Android application by removing the unnecessary parts, as I want just to have a simple "Menu" as a title at the top, and nothing else.

For this, I'm going to edit the res/layout/nav_header_navigation_layout.xml:

Source Code

<?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:background="@color/colorPrimary"
    android:orientation="vertical"
    android:paddingBottom="@dimen/activity_vertical_margin"
    android:paddingLeft="@dimen/activity_horizontal_margin"
    android:paddingRight="@dimen/activity_horizontal_margin"
    android:paddingTop="@dimen/activity_vertical_margin"
    android:theme="@style/ThemeOverlay.AppCompat.Dark"
    android:gravity="bottom">

    <TextView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:paddingTop="22dp"
        android:text="Menu"
        android:textAppearance="@style/TextAppearance.AppCompat.Title" />


</LinearLayout>

Conclusion

Android Menu

Commits

Clone this wiki locally