Empty Space above bar

There is an empty space above the bar, I am sorry if I missed something. I searched some of the open and closed tickets and didn't see anything.
I have tried attaching using mBottomBar = BottomBar.attach(this, savedInstanceState); and mBottomBar = BottomBar.attach(findViewById(R.id.myCoordinator), savedInstanceState); but it still happens.
Tested on Nexus 6p running N and Nexus 7 running 6.0.1
Thanks,
Jake
Same issue here running 4.4.4 and 5.1.1, so not just an Android 6 problem.
It appears to be a bug, it happens when you add to your main activity resource file: fitsSystemWindows = true. I removed that and added manually some top padding to my custom toolbar. It fixes this issue for now.
How does your XML layout structure look like?
My main layout:
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/activity_main_coordinator"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true">
<FrameLayout
android:id="@+id/activity_main_content_frame"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<android.support.design.widget.AppBarLayout
android:id="@+id/activity_main_app_bar_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:fitsSystemWindows="true"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar">
<android.support.v7.widget.Toolbar
android:id="@+id/activity_main_toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
app:layout_scrollFlags="scroll|enterAlways|snap">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/app_name" />
</android.support.v7.widget.Toolbar>
<android.support.design.widget.TabLayout
android:id="@+id/activity_main_tab_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorPrimary"
android:minHeight="?attr/actionBarSize"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
android:visibility="gone" />
</android.support.design.widget.AppBarLayout>
</android.support.design.widget.CoordinatorLayout>
Inside the fragments that are put "into" R.id.activity_main_content_frame there are e.g. a ViewPager (with fragments again and inside these fragments RecyclerViews) or RecyclerViews.
This is my XML for my main activity:
<include
android:id="@+id/main_activity_toolbar"
layout="@layout/tool_bar" />
<FrameLayout
android:id="@+id/mainFragmentContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@+id/main_activity_toolbar">
</FrameLayout>
@cyberjaime45 Try attaching the BottomBar to your mainFragmentContainer.
Awesome library, its working well for me. Sure I had some issues but nothing I can't handle it.
try fitsSystemWindows="false" on everything including the tablayout and framelayout
I have the same problem if I set fitSystemWindows="true" I got a extra space above the bottomBar and if I set to false I got my toolbar behind the status bar
For now I defined a paddinBottom="24dp" in my Toolbar but I think that is not a good ideia
Has anyone solved this problem?
This is fixed in the newest versions.
I have also having same problem. As per my functionality I need to use drawer menu as well as bottom navigation. If I use bottom navigation with only 3 tabs than it works fine but if I extend bottom navigation with 4 or 5 tabs than it appears white space at the top of tool bar.

Hello! I have the bottom bar inside a LinearLayout with two children.
<FrameLayout
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="@color/colorAccent"
tools:fragment="us.kostenko.glagol.QuizActivity">
</FrameLayout>
<com.roughike.bottombar.BottomBar
android:id="@+id/bottomBar"
android:layout_width="match_parent"
android:layout_height="60dp"
android:background="@color/colorBottomBar"
app:bb_tabXmlResource="@xml/bottombar_tabs" />

Above the bottom bar appears a little empty space about 4dp height. The only thing helped was adding negative layout_marginTop to the bottom bar. Is this a bug? How do I fix this?
Having exactly the same issue, using 5 tabs. Any fix for this?
Edit:
Fixed this using answer found here #656. Just add app:bb_showShadow="false"
It's not very obvious since the shadow appeared on top and was white but it worked.
I have also having same problem. As per my functionality I need to use drawer menu as well as bottom navigation. If I use bottom navigation with only 3 tabs than it works fine but if I extend bottom navigation with 4 or 5 tabs than it appears white space at the top of tool bar.
![]()
Have you found out how to fix this?
I wrote in the comment above yours a fix:
Fixed this using answer found here https://github.com/roughike/BottomBar/issues/656. Just add app:bb_showShadow="false"
I am facing the same problem, the white padding isn't visible in preview but its visible while running in emulator