I want to put horizontal scroll tabs on my android app but I do not know how. I've followed many tutorials but none of them seem to work. Could anyone tell me how I could do it?
hey buddy just add a scrollview to your layout which contains items in it...
for rest u can refer to this link http://abhiandroid.com/ui/scrollview
Related
i'm developing an application for android that is already done for IOS, is not big problem.
the thing is that my boss want it to be exactly the same, but one of the menus is the problem, is like a slide menu but with zoom and a background image, anyone have any idea how can i do this, i already google it but no results :(, a library would help.
here is a picture with the menu for IOS.
I don't think if it would be an effective solution but you can use a RelativeLayout.
Put the selection part behind in a LinearLayout then put a framelayout front to contain list fragments. This way you shouldn't use an action bar to have absolutely same looking with iOs version.
When someone clicks open button apply an animation to your framelayout. scale it by %75 and move it 25% in y coordinate and move it %50 in x coordinate. When buttons in your LinearLayout apply a reverse animation to your FrameLayout. If swap button clicked change your fragment with new one. You can also aply a transaction animation to your fragments.
I hope you know how to handle this stuff. If no I can do my best to code an example.
EDIT:
Don't forget to set your flame layout unclickable when you move it to right side.
https://github.com/SpecialCyCi/AndroidResideMenu
I think I found your answer. I came across this in a list of libraries it is 3.8 on the list https://github.com/Trinea/android-open-project/tree/master/English%20Version
Cheers!
I am new to Android development, and I am wondering if there are any samples available to create a panel similar to the photo/checkin/mood/write panel at the bottom of the google+ app on android.
1) Are they 4 buttons? How do I style the buttons to look like that?
2) I want to auto hide the panel on scroll down, but show on scroll up.
Appreciate if anyone could guide me in the right direction.
Cheers
To show\hide panel - use animation.
This panel can be linearLayout with 4 buttons.
Do detect what've been scrolled look at: Synchronise ScrollView scroll positions - android
you can use linearlayout and in that take for imageview..when scrolling you can show/hide linearlayout..and for view you can use linearlayout color as black and this imageview images..
OK, so I implemented exactly what you trying to do only without the buttons.
After lot of hours spending googling around I found this one - https://gist.github.com/imminent/4576886 by Dandre' Allison, which is a specific implantation of quick return bar for a list view which is little more trickier from other view components. For more implementations of quick return bar and other scrolling tricks you can use Roman Nurik's Scrolling Tricks library here https://plus.google.com/u/0/+RomanNurik/posts/1Sb549FvpJt and here http://www.androidviews.net/2012/11/scrolling-tricks/. I just saw that there is another quick return bar for list view implenation by Lars Werkman in https://github.com/LarsWerkman/QuickReturnListView which I never tested. I used the Dandre' Allison snippet which works great.
Answering your first question.
all the buttons are either in ImageButton, or in ImageView that make it clickable. it's either you can lay it out in LinearLayout or RelativeLayout, well it's depends on how you want to make it.
Try Using split action bar this will basically do the task for you.
i have four images in a row at the top , on click of each icon i want to change the underlaying background (image) and the controls on the layout , this way it achieves tab like structure and behavior , i want to know whats the best way to achieve this ? I think i will have four layouts each layout having one image highlighted showing that tab selected and corresponding components on layout, and will change this layout when user clicks on image.
Is this a good idea to achieve this ? or i have different solution available ?
its nice if u give me some idea about necessary features or API or layout component related code
Suggestions are welcome thanks!
That is not a good idea. You should use android's tab architecture. Here is a example at developer.android
you can change layouts by switching views to invisible and visible. but it's not a good idea when you want to change 4 layouts.
It becomes hard to maintain the code if you have 4 layouts switching.
It's better to use Tabs which will help you in preserving the state of the each layout.
Customize the tabWidget to make it look like you have 4 buttons on the top, not the tabs.
HTH.
I'm designing a Gallery View in Android where I need to have two views occupying each half of the screen (2 views on a full screen). When the user scrolls it shows the next view. The Ideas behind this is to have five views and user see 2 views initially. I tried a couple options but without success,where setLayoutParams(new Gallery.LayoutParams(screenWidth/2, screenHeight/2)); didn't really solve the problem. If anybody encountered this kind if an issue send me an advice or path. Thank you for reading and please let me know if you need any further details in case if I didn't make my self clear.
two views occupying each half of the screen (2 views on a full screen)
to acheive this give both the views equal weight so that both takes equal height(half - half screen). then in the
setLayoutParams(new Gallery.LayoutParams(screenWidth/2, screenHeight/2));
instead of setting the screenwidth/2 and height/2 use fill parent there...
Hope it helps...
if found any issues with this... post your layout and code relevant to that...
What I would like to do is create a Layout with buttons, edittexts, an textviews on the left side, and have the ExpandableListView on the right. Is there any way to do this? I have googled, but I haven't really come up with anything. Does anyone have any bright ideas, or do you know the solution I am looking for?
Thanks,
Here's a link to an example with two ListViews inside one RelativeLayout. This should be the same if they're expandable or not.
How to use Two ListView in one screen?