Android, Tabs Without Actionbar
Solution 1:
Solution of your problem is already given in http://developer.android.com/
To disableAction-bar Icon and Title, you must do two things:
setDisplayShowHomeEnabled(false); // hides action bar iconsetDisplayShowTitleEnabled(false); // hides action bar title
Follow The Steps given in Using split action bar
Write Following Code in OnCreate()
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.navigation_drawer);
getActionBar().setDisplayShowHomeEnabled(false); // hides action bar icongetActionBar().setDisplayShowTitleEnabled(false); // hides action bar title//rest of your code...
}
After Android updated Actionbar to Toolbar there are many changes in Actionbar Tabs.
Please follow below links to create swipable tabs in Andoid.
Design Structure :
Some of the very useful links are below. Please refer to them.
Download sample zip from below link
http://developer.android.com/samples/SlidingTabsBasic/index.html
Or Refer these links
http://www.android4devs.com/2015/01/how-to-make-material-design-sliding-tabs.html
http://www.truiton.com/2015/06/android-tabs-example-fragments-viewpager/
https://guides.codepath.com/android/Google-Play-Style-Tabs-using-TabLayout
This may help you...
Solution 2:
You can:
Use a
ViewPager
with aPagerTabStrip
Use a
ViewPager
with theTabPageIndicator
class from the ViewPagerIndicator libraryUse a
ViewPager
with other third-party tab indicators (e.g., in the "View Pagers" category at the Android Arsenal)Use a
ViewPager
and design your own tabbed indicatorUse a
FragmentTabHost
and skip the swiping part
Solution 3:
Along with
getActionBar().setDisplayShowHomeEnabled(false);
getActionBar().setDisplayShowTitleEnabled(false);
Use this as well
getActionBar().setNavigationMode(ActionBar.NAVIGATION_MODE_TABS);
Post a Comment for "Android, Tabs Without Actionbar"