title: Action toolbar, mysterious gap android
body: <p>i have no idea what's the problem is this .. but this is disgusting and make my app look so bad .. </p>
  
  <p>here a screenshot of the problem</p>
  
  <p><a href="https://i.stack.imgur.com/BKfZr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/BKfZr.png" alt="enter image description here"></a></p>
  
  <p>i don't know where it is come from...
  i give you my tool bar XML</p>
  
  <p><strong>Toolbar.XML</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;android.support.v7.widget.Toolbar
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:local="http://schemas.android.com/apk/res-auto"
      android:id="@+id/toolbar"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:minHeight="?attr/actionBarSize"
      android:background="@color/colorPrimary"
      local:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
      local:popupTheme="@style/ThemeOverlay.AppCompat.Light"
      android:elevation="4dp"
      style="@style/Widget.AppCompat.Light.ActionButton" /&gt;
  </code></pre>
  
  <p>i show it on my <code>mainActivity</code> layout.. and this is my <code>mainActivity</code> layout</p>
  
  <p><strong>ContentMain.XML</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;android.support.v4.widget.DrawerLayout
      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:id="@+id/drawer_layout"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context="com.example.study.MainActivity"&gt;
  
  
      &lt;LinearLayout
          android:layout_width="match_parent"
          android:layout_height="match_parent"
          android:orientation="vertical"&gt;
  
          &lt;include
              android:id="@+id/toolbar"
              layout="@layout/toolbar" /&gt;
  
          &lt;FrameLayout
              android:id="@+id/container_body"
              android:layout_width="fill_parent"
              android:layout_height="0dp"
              android:layout_weight="1" /&gt;
  
      &lt;/LinearLayout&gt;
  
  
      &lt;fragment
          android:id="@+id/fragment_navigation_drawer"
          android:name="com.example.study.fragment.FragmentDrawer"
          android:layout_width="@dimen/nav_drawer_width"
          android:layout_height="match_parent"
          android:layout_gravity="start"
          app:layout="@layout/fragment_navigation_drawer"
          tools:layout="@layout/fragment_navigation_drawer"
          /&gt;
  
  &lt;/android.support.v4.widget.DrawerLayout&gt;
  </code></pre>
  
  <p>BUT this problem <code>dissapear</code> if i went to another fragment and go back to home fragment</p>
  
  <p><a href="https://i.stack.imgur.com/vN7yr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vN7yr.png" alt="enter image description here"></a></p>
  
  <p>i've tried re-install the apps .. and rebuild project .. build clean project .. it doesn't work</p>
  
  <p>that images show from fragment which implemented in <code>frameLayout</code>, and in my fragment there's a slider show images.</p>
  
  <p>FragmentHome.XML</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:custom="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:orientation="vertical"
      android:fitsSystemWindows="true"
      tools:context="com.example.study.fragment.HomeFragment"&gt;
  
              &lt;com.example.study.slider_library.SliderLayout
                  android:layout_width="match_parent"
                  android:layout_height="200dp"
                  android:id="@+id/slider"
                  custom:pager_animation="Accordion"
                  custom:auto_cycle="true"
                  custom:indicator_visibility="visible"
                  custom:pager_animation_span="1100"
                  android:background="#202020"
                  android:drawingCacheQuality="auto" /&gt;
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>and this one java code of my <code>FragmentHome</code></p>
  
  <p>HomeFragment.Java</p>
  
  <pre><code>public class HomeFragment extends android.support.v4.app.Fragment
          implements BaseSliderView.OnSliderClickListener, ViewPagerEx.OnPageChangeListener {
  
  
      private HashMap&lt;String,String&gt; url_maps;
      private SliderLayout mDemoSlider;
  
      public HomeFragment() {
          // Required empty public constructor
      }
  
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
  
      }
  
      @Override
      public View onCreateView(LayoutInflater inflater, ViewGroup container,
                               Bundle savedInstanceState) {
          View layout = inflater.inflate(R.layout.fragment_home, container, false);
  
          mDemoSlider = (SliderLayout) layout.findViewById(R.id.slider);
  
  
          HashMap&lt;String,String&gt; url_maps = new HashMap&lt;&gt;();
  
          url_maps.put("Hannibal", "http://static2.hypable.com/wp-content/uploads/2013/12/hannibal-season-2-release-date.jpg");
          url_maps.put("Big Bang Theory", "http://tvfiles.alphacoders.com/100/hdclearart-10.png");
          url_maps.put("House of Cards", "http://cdn3.nflximg.net/images/3093/2043093.jpg");
          url_maps.put("Game of Thrones", "http://images.boomsbeat.com/data/images/full/19640/game-of-thrones-season-4-jpg.jpg");
  
  
          for(String name : url_maps.keySet()){
              DefaultSliderView DefaultSliderView = new DefaultSliderView(getContext());
              // initialize a SliderLayout
              DefaultSliderView
                      .image(url_maps.get(name))
                      .setScaleType(BaseSliderView.ScaleType.Fit)
                      .setOnSliderClickListener(this);
  
              //add your extra information
              DefaultSliderView.bundle(new Bundle());
              DefaultSliderView.getBundle()
                      .putString("extra",name);
  
              mDemoSlider.addSlider(DefaultSliderView);
          }
  
          mDemoSlider.setPresetTransformer(SliderLayout.Transformer.Tablet);
          mDemoSlider.setPresetIndicator(SliderLayout.PresetIndicators.Center_Bottom);
          mDemoSlider.setDuration(400);
          mDemoSlider.addOnPageChangeListener(this);
  
  
          // Inflate the layout for this fragment
          return layout;
  
      }
  
  
      @Override
      public void onDetach() {
          super.onDetach();
      }
  
      @Override
      public void onStop() {
          // To prevent a memory leak on rotation, make sure to call stopAutoCycle() on the slider before activity or fragment is destroyed
          mDemoSlider.stopAutoCycle();
          super.onStop();
      }
  
      @Override
      public void onSliderClick(BaseSliderView slider) {
          Toast.makeText(getContext(),slider.getBundle().get("extra") + "",Toast.LENGTH_SHORT).show();
      }
  
      @Override
      public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {}
  
      @Override
      public void onPageSelected(int position) {
          Log.d("Slider Demo", "Page Changed: " + position);
      }
  
      @Override
      public void onPageScrollStateChanged(int state) {}
  }
  </code></pre>