【发布时间】:2020-04-14 14:07:12
【问题描述】:
我没有在操作栏上看到我的应用程序名称。
所以请帮我弄清楚它被隐藏的原因以及如何解决这个问题。
这是我的代码:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<com.google.android.material.appbar.AppBarLayout
android:id="@+id/appBarLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:id="@+id/my_Toolbar"
layout="@layout/my_toolbar"
<com.google.android.material.tabs.TabLayout
android:id="@+id/tabLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"/>
</com.google.android.material.appbar.AppBarLayout>
<androidx.viewpager.widget.ViewPager
android:id="@+id/viewPager"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/appBarLayout"/>
</RelativeLayout>
【问题讨论】:
标签: android android-studio android-layout menu android-actionbar