У меня есть DrawerLayout с NavigationView (библиотекой поддержки дизайна) внутри. Мне удалось установить заголовок и добавить элементы в представление, но я хотел бы, чтобы некоторые элементы имели меньший текст, без значков и т. д. Я не могу понять, где я могу указать новые атрибуты. В моем drawer.xml, где находятся другие элементы, я не знаю, какие атрибуты могут его изменить.
Любой совет приветствуется!
У меня есть два элемента с предполагаемым внешним видом, и последний элемент, выход из системы, я хочу сделать меньше и иметь над ним разделитель.
макет/activity_main.xml
<!-- A DrawerLayout is intended to be used as the top-level content view using match_parent for both width and height to consume the full space available. -->
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
tools:context=".MainActivity">
<!-- As the main content view, the view below consumes the entire
space available using match_parent in both dimensions. -->
<LinearLayout
android:orientation="vertical"
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="match_parent" >
</LinearLayout>
<android.support.design.widget.NavigationView
android:id="@+id/navigation"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_gravity="start"
app:headerLayout="@layout/fragment_navdrawer_header"
app:menu="@menu/drawer"/>
</android.support.v4.widget.DrawerLayout>
меню/drawer.xml
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<group android:checkableBehavior="single">
<item
android:id="@+id/navigation_item_1"
android:icon="@drawable/ic_action_social_school"
android:title="Courses"/>
<item
android:id="@+id/navigation_item_2"
android:icon="@drawable/ic_action_action_grade"
android:title="Grades"/>
<item
android:id="@+id/navigation_logout"
android:title="Logout"
/>
</group>
</menu>