I want to make an application which will look like android home screen. where I want to place some icons. it will have 10 pages. I want to do scroll between these pages.
How to achieve this? Plz help.
Thanks.
I'm not sure how to archive the home-screen like switching but for the icons, you can use a GridView. To switch between the pages, a TabLayout could be used. Also I found this, which might be what you're searching for.
But there might be bettwer ways of doing this...
Related
I'm right now working on a launcher app and I have three Activities. User is on 2nd Activity by default and when user swipes left it should take him to 3rd Activity and when user swipes right it should take user to 1st Activity. Just like Swipable Tabs but the Tabs should not appear. Is it possible? Best example is of Home Screen, I want it exactly as Home Screen. I've tried a lot! But I'm not getting what ACTUALLY I want, any help would be gladly appreciated, thanks!
I hope I can get you well.
First personally I don't suggest achieving this goal by using multiple activity. A better way might be one activity containing multiple fragment.
Then if you do so, several tools can make help, ViewPager for example.
If you want to add some view page indicator, as what the homescreen looks like, then ViewPagerIndicator might be a good choice.
Hope it helps.
I need to implement iphone like tab in android. Which means, if there are more than 5 tabs are there the 5th tab text must show "more"? How can I implement this? Is it possible to do so in Android? Please help me. Thanks in advance
As far as I know, it's not possible. You can however implement a scrollbar for the tab widget, so if you have more than a number of tabs and they don't fit the screen, it won't show a 'More' tab, but you can scroll to the rest. For more info about this, check this link.
I totally agree with #yugidroid but sometimes it's hard to explain this to designer :) So you will need to implement that attitude of tabs by yourself, it is possible though.
You can check out my repository on github to have an idea where to begin. You can do it by modifying that actually...
You can add this to your activity:
tabLayout.setTabMode(TabLayout.MODE_SCROLLABLE);
After adding this you can have how many tabs you want.
I'm trying to figure out navigation in the app I'm making, and want it to look like it does on the phone to the right (link below), except I want the menu at the bottom to be directly below the tabs. I tried googling and searching for hours, but I cant seem to figure out.
I have managed to make the tabs (with Fragments and such).
I apologize if this really isn't that hard, but being new to this it is kind of hard to wrap your head around everything. Either way, thanks.
I think you are looking for a custom layout.
http://www.vogella.com/articles/AndroidActionBar/article.html
Look at section 5, should be pretty simple from there.
That being said, don't fight the OS. I always ask myself questions like: Do you really need tabs above a menu? Can you quote another application doing that?
I am looking to create an app where some categories that the user can choose from will be shown. The best UI I could find is shown in this image:
https://lh3.ggpht.com/swzmwICOMNjKmLH_HyAWh0VQ49BN7vU6PG3qEpsSnF1HWcG1CmpQi1BTBxdVczZx8pY
The screenshot is of the "Parenting Ages & Stages" android app. The best part of the above shown home page is that there is no scroll bar at the bottom and the user can use swipe gestures to see various categories.
Any idea how I can achieve the same effect?
It would be better to use ViewPager in your case
http://developer.android.com/reference/android/support/v4/view/ViewPager.html
It may Help you!
Is it possible to change the size of the tabs displayed in a TabActivity? I'm currently only putting text in my tabs and I'd really like to minimize the size as much as possible.
Also, is there a way to use icons for my activity that aren't 48x48? I'd like to do something more rectangular as opposed to square. I just want to use my screen real-estate the best I can :)
How is the YouTube app doing this? (See screenshot, and yes I know that the YouTube app isn't open source)
It seems that they're also making it possible to scroll left and right for more tabs. Any ideas on how they're doing this?
Yest you can do all that by creating your own custom view for tab widget, it is quite simple to do. this tutorial will do the trick
http://joshclemm.com/blog/?p=136