title: Issue with recyler view
body: <p>My recycler view gets inside the tab layout</p>
  
  <p><a href="https://i.stack.imgur.com/jwKIL.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/jwKIL.png" alt="enter image description here"></a></p>
  
  <p>I have issue with Recylerview.What should I do to overcome this problem.
  I am new android developer. Unable to rectify this issue. I had three xml file one for toolbar, fragment ,main activity.</p>
  
  <p>My fragment-</p>
  
  <pre><code>    public class viewPagerAdapter extends FragmentPagerAdapter {
      ArrayList&lt;Fragment&gt; fragments=new ArrayList&lt;&gt;();
      ArrayList&lt;String&gt; tabTitlles= new ArrayList&lt;&gt;();
      public void addFragments(Fragment fragments,String titles){
          this.fragments.add(fragments);
          this.tabTitlles.add(titles);
      }
  
    public viewPagerAdapter(FragmentManager fm){
        super(fm);
    }
  
      @Override
      public Fragment getItem(int position) {
          return fragments.get(position);
      }
  
      @Override
      public int getCount() {
          return fragments.size();
      }
  
      @Override
      public CharSequence getPageTitle(int position) {
          return tabTitlles.get(position);
      }
  </code></pre>
  
  <p>My Main Activity</p>
  
  <pre><code>public class MainActivity extends AppCompatActivity {
  Toolbar toolbar;
  TabLayout tabLayout;
  ViewPager viewPager;
  viewPagerAdapter vp;
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main);
          toolbar=(Toolbar)findViewById(R.id.toolBar);
          tabLayout = (TabLayout) findViewById(R.id.tablayout);
          viewPager = (ViewPager) findViewById(R.id.viewpager);
          toolbar.setTitleTextColor(0xFFFFFFFF);
  tabLayout.setTabTextColors(getResources().getColor(R.color.inactive), getResources().getColor(R.color.active));
          setSupportActionBar(toolbar);
          getSupportActionBar().setTitle("Customer App");
  
          vp= new viewPagerAdapter(getSupportFragmentManager());
  vp.addFragments(new HomeFragment(),"homr");
          vp.addFragments(new topfreeFragment(),"top");
          vp.addFragments(new TopPaidFragment(),"paid");
          viewPager.setAdapter(vp);
          tabLayout.setupWithViewPager(viewPager);
      }
  }
  </code></pre>
  
  <p>My pageadapter</p>
  
  <pre><code>    public class viewPagerAdapter extends FragmentPagerAdapter {
          ArrayList&lt;Fragment&gt; fragments=new ArrayList&lt;&gt;();
          ArrayList&lt;String&gt; tabTitlles= new ArrayList&lt;&gt;();
          public void addFragments(Fragment fragments,String titles){
              this.fragments.add(fragments);
              this.tabTitlles.add(titles);
          }
  
        public viewPagerAdapter(FragmentManager fm){
            super(fm);
        }
  
          @Override
          public Fragment getItem(int position) {
              return fragments.get(position);
          }
  
          @Override
          public int getCount() {
              return fragments.size();
          }
  
          @Override
          public CharSequence getPageTitle(int position) {
              return tabTitlles.get(position);
          }
      }
  public class viewPagerAdapter extends FragmentPagerAdapter {
      ArrayList&lt;Fragment&gt; fragments=new ArrayList&lt;&gt;();
      ArrayList&lt;String&gt; tabTitlles= new ArrayList&lt;&gt;();
      public void addFragments(Fragment fragments,String titles){
          this.fragments.add(fragments);
          this.tabTitlles.add(titles);
      }
  
    public viewPagerAdapter(FragmentManager fm){
        super(fm);
    }
  
      @Override
      public Fragment getItem(int position) {
          return fragments.get(position);
      }
  
      @Override
      public int getCount() {
          return fragments.size();
      }
  
      @Override
      public CharSequence getPageTitle(int position) {
          return tabTitlles.get(position);
      }
  }
  </code></pre>
  
  <p>My fragment Xml</p>
  
  <pre><code>&lt;FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  tools:context="test.fmtest.HomeFragment"
  &gt;
  
  &lt;!-- TODO: Update blank fragment layout --&gt;
  
  &lt;android.support.v7.widget.RecyclerView
  
      android:id="@+id/lis"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
  
      /&gt;
  </code></pre>
  
  <p></p>
  
  <p>My Activity XML</p>
  
  <pre><code>    &lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context="test.fmtest.MainActivity"&gt;
  
   &lt;android.support.design.widget.AppBarLayout
       android:layout_height="wrap_content"
       android:layout_width="match_parent"&gt;
       &lt;include
           android:layout_height="wrap_content"
           android:layout_width="match_parent"
           layout="@layout/toolbar_layout"&gt;&lt;/include&gt;
       &lt;android.support.design.widget.TabLayout
           android:layout_width="match_parent"
           android:layout_height="wrap_content"
           android:id="@+id/tablayout"
           app:tabMode="fixed"
           app:tabGravity="fill"&gt;
  
       &lt;/android.support.design.widget.TabLayout&gt;
   &lt;/android.support.design.widget.AppBarLayout&gt;
      &lt;android.support.v4.view.ViewPager
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:id="@+id/viewpager"
          &gt;
  
      &lt;/android.support.v4.view.ViewPager&gt;
  
  
  
  &lt;/android.support.constraint.ConstraintLayout&gt;
  </code></pre>