title: ViewPager's height in Coordinator layout is more than available
body: <p>I have a <code>CoordinatorLayout</code> with a <code>Toolbar</code> and a <code>TabLayout</code> inside the <code>AppBarLayout</code>. Additionally, I have a <code>ViewPager</code> inside the <code>CoordinatorLayout</code> but outside the <code>ViewPager</code>. </p>
  
  <p>The problem is that the <code>ViewPager's</code> height is bigger than what is actually available, resulting in some views from my <code>Fragment</code> being cut.</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:background="@color/lightGray"
      android:fitsSystemWindows="true"&gt;
  
      &lt;android.support.design.widget.AppBarLayout
          android:id="@+id/app_bar_layout"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:theme="@style/AppTheme.AppBarOverlay"&gt;
  
          &lt;android.support.v7.widget.Toolbar
              android:id="@+id/toolbar2"
              android:layout_width="match_parent"
              android:layout_height="?attr/actionBarSize"
              app:popupTheme="@style/AppTheme.PopupOverlay"
              app:layout_scrollFlags="scroll|enterAlways"/&gt;
  
          &lt;android.support.design.widget.TabLayout
              android:id="@+id/tabLayout"
              android:scrollbars="horizontal"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:fillViewport="false"/&gt;
  
      &lt;/android.support.design.widget.AppBarLayout&gt;
  
      &lt;android.support.v4.view.ViewPager
          android:id="@+id/pager"
          android:layout_width="match_parent"
          android:layout_height="match_parent"
          app:layout_behavior="@string/appbar_scrolling_view_behavior"/&gt;
  
  &lt;/android.support.design.widget.CoordinatorLayout&gt;
  </code></pre>
  
  <p>And this what I mean when I say that the <code>ViewPager</code> has the wrong height.<br>
  <a href="https://i.stack.imgur.com/hWRbNl.png" rel="noreferrer"><img src="https://i.stack.imgur.com/hWRbNl.png" alt="enter image description here"></a>  </p>