The right layout for a curved set of buttons? - android

I'm working on creating a menu screen, its fairly boring set of buttons so I wanted to add a curve to their layout to make it a bit more interesting. Like this:
I've just added the curved line to give an idea of what I'm doing - it won't actually have a line when done.
My question is what is the best way to go about doing this. I have tried using a linear layout and then applying a left padding to push them increasingly away from the edge. The problem here is that this depends on the screen size. On a small screen it displays fine and on a larger screen it does not. The second problem I have it that I'd like the entire curve to be centralized in the screen. Should I use a linear layout nested inside another?
If anyone has any ideas or sample layout xml as the best way to achieve this that'd be great.

Take a look on this widget, they doing someting like this

Maybe a relative layout so you can the position of each button relative to the one that comes below it?

Related

Layout with decreasing height from one end to another in android (inclined on one side)

Here is what I need to attain
The Application logo goes inside that blue background. Can I somehow tweak Linear or Relative Layout to attain that inclined bottom? Or is that any other solution to this, other than simply using an image itself?
No, Views in Android are all rectangular, and LinearLayout and RelativeLayout only deal in rectangular measurements. You're going to have to do some special drawing or use a background image or something along those lines.

Which android layout class do I use to achieve this theme?

I'm going to have an application which will look like this:
As you can see, I'll have three buttons (including the envelop icon) aligned in a circle. This is rather easy to achieve in Photoshop, but NOT in android layout XMLs. Which layout class do you think is best in this case?
One more thing, how can I have a completely transparent button with an image in the middle. When I set
android:alpha="0"
the image also disappears which is not what I want. Any idea?
This is rather easy to achieve in Photoshop, but NOT in android layout XMLs.
Not really - you feel it's easy in Photoshop because you know how to do this in Photoshop. Once you have a fair idea of Android layout, that too will become easy for you.
Which layout class do you think is best in this case?
If I were to do this, I would have used RelativeLayout as the position of the two smaller buttons are relative to the larger one. Similarly the buttons as a whole is relative to the screen. So, may be 2 RelativeLayouts - 1 nested inside the other.
how can I have a completely transparent button with an image in the middle
Use transparency as the background.
android:background="#android:color/transparent"

Android - creating a simplified spotify-like layout

I am developing an Android app and am a bit stuck on how I go about creating the layout I'm after. I said spotify-like (website not app) as I dont want the parallax effect. It's actually closer to http://www.poormet.com/.
What I have tested so far is a RelativeLayout with an ImageView and Listview (with transparent dividers) within it. This layout shows the image in the background between rows which is a step in the right direction. The issue is I'm at a loss as to how to get the images to change smoothly depending on what listrows are on screen.
Also, if I want to replicate the text over the images like poormet example mentioned above, then it seems to me I am going to have to have alternating transparent and not transparent rows.
Am I on the right track or am I approaching this problem the wrong way?
Any guidance will be greatly appreciated!!!
(also, please let me know if what I have described doesn't make sense - more than happy to clarify)

How to create round shape image using android?

I am having four piece of image.
Here I attached one sample image.
How can I create the round shaped image using these type of images?
Which layout is best for creating the UI for android?
Thanks in advance.
are you talking about something like this..
http://www.baijs.nl/tinycircleslider/
And for designing the UI for Android is depends on our requirement.it means whether you want to design something looks like rows and columns then GridLayout and tableLayout will be better,depends on requirement and look the layout will changes once try it your self and choose the best suited for your applicaiton.All the best Mate
inside relative layout add four imageview with attrs ParentTop, ParentRight, ParentBottom and ParentLeft. every image is rectangular with transparent extra area.
i can understand it is little hard to visualize on first attempt.
now come to click area. so a runtime decision about ignore transparent area click will be right thing.
more tricky way will be manage flags for all listeners and if two listener get calls its transparent area .

Android Layout Fill_Parent Problem

I am fairly new to android and am having some problems with a layout. Below is an approximation of what I want the layout to look like. (I would like the list to be below the screen at first so that the user can scroll down to see it.) However my code as it currently stands makes all of the views on the left only take up a quarter the screen instead of half, as depicted, even though I have all widths set to fill_parent.
Also, this layout seems to mess up the coordinate system on my custom view. Normally this wouldn't be much of an issue, but in this case I am using that view to draw a picture and the picture ends up in the wrong place. Does anybody have any idea how to resolve these issues?
Could you show the XML file you are using? This would be helpful. Also, the coordinate system of a View does not change based on the layout.

Categories

Resources