title: Toolbar and TabLayout is not visible on Android 4.4 devices
body: <p>I was trying to implement Toolbar and TabLayout using google design library by referring to [<a href="http://blog.grafixartist.com/material-design-tabs-with-android-design-support-library/]" rel="nofollow noreferrer">http://blog.grafixartist.com/material-design-tabs-with-android-design-support-library/]</a> [blog]. </p>
  
  <p>Output works as expected on Lollipop devices but it doesnot show ToolBar and TabLayout on Kitkat devices. But i can still swipe through 3 fragment as expected on kitkat device as well. How come same code written using google support libraries works differently on different devices!</p>
  
  <p>I tried referring to [<a href="https://stackoverflow.com/questions/29864524/toolbar-is-not-visible-on-android-4-x-devices-solved]">Toolbar is not visible on Android 4.X devices [solved]</a> question but it didn't solve the problem. I tried running the code in emulator with API 19 but facing same issue on that as well. </p>
  
  <p>I have added <code>'com.android.support:appcompat-v7:22.2.0'</code>, <code>'com.android.support:support-v4:22.2.0'</code> and <code>'com.android.support:design:22.2.0'</code> dependencies in the project.</p>
  
  <p><strong>activity_main.xml</strong></p>
  
  <pre><code>&lt;android.support.design.widget.CoordinatorLayout
  xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  xmlns:app="http://schemas.android.com/tools"&gt;
  
  &lt;android.support.design.widget.AppBarLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"&gt;
  
      &lt;android.support.v7.widget.Toolbar
          android:id="@+id/toolbar"
          android:layout_width="match_parent"
          android:layout_height="?attr/actionBarSize"
          android:background="?attr/colorPrimary"
          app:layout_scrollFlags="scroll|enterAlways"
          app:popupTheme="@style/Base.ThemeOverlay.AppCompat.Dark" /&gt;
  
      &lt;android.support.design.widget.TabLayout
          android:id="@+id/tablayout"
          android:layout_width="match_parent"
          android:layout_height="match_parent" /&gt;
  
  &lt;/android.support.design.widget.AppBarLayout&gt;
  
  &lt;android.support.v4.view.ViewPager
      android:id="@+id/viewpager"
      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><strong>MainActivity.java</strong></p>
  
  <pre><code>public class MainActivity extends AppCompatActivity {
  
      public ViewPager viewPager;
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main);
  
          Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
          setSupportActionBar(toolbar);
  
          viewPager = (ViewPager) findViewById(R.id.viewpager);
          setupViewPager(viewPager);
  
          TabLayout tabLayout = (TabLayout) findViewById(R.id.tablayout);
          tabLayout.setupWithViewPager(viewPager);
  
          tabLayout.setOnTabSelectedListener(new TabLayout.OnTabSelectedListener() {
              @Override
              public void onTabSelected(TabLayout.Tab tab) {
                  viewPager.setCurrentItem(tab.getPosition());
              }
              @Override
              public void onTabUnselected(TabLayout.Tab tab) {
              }
              @Override
              public void onTabReselected(TabLayout.Tab tab) {
              }
          });
  
      }
  
      private void setupViewPager(ViewPager viewPager) {
          ViewPagerAdapter adapter = new ViewPagerAdapter(getSupportFragmentManager());
          adapter.addFrag(new QueuedFragment(), "Queued");
          adapter.addFrag(new IntransitFragment(), "InTransit");
          adapter.addFrag(new DeliveredFragment(), "Delivered");
          viewPager.setAdapter(adapter);
      }
  }
  </code></pre>
  
  <p><strong>style.xml</strong></p>
  
  <pre><code>&lt;resources&gt;
  
  &lt;style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"&gt;
          &lt;item name="windowActionBar"&gt;false&lt;/item&gt;
          &lt;item name="windowNoTitle"&gt;true&lt;/item&gt;
  &lt;/style&gt;
  </code></pre>
  
  <p></p>